```python
from sympy import *
```


```python
# square root

sqrt(32)
```




$\displaystyle 4 \sqrt{2}$




```python
# fraction reduction

frac = Rational(5,25)
frac
```




$\displaystyle \frac{1}{5}$




```python
# algebra

x, y = symbols("x y")

# expression

expr = x**2+y**2
expr
```




$\displaystyle x^{2} + y^{2}$




```python
# expression manipulation

expr + x
```




$\displaystyle x^{2} + x + y^{2}$




```python
# expansion

expand = expand((x+1)*(x-1))
expand
```




$\displaystyle x^{2} - 1$




```python
# factorization

factor(expand)
```




$\displaystyle \left(x - 1\right) \left(x + 1\right)$




```python
# simplification

expr = (2*x**2-2)/(x+1)
expr
```




$\displaystyle \frac{2 x^{2} - 2}{x + 1}$




```python
simplify(expr)
```




$\displaystyle 2 x - 2$




```python
# function solving

expand
```




$\displaystyle x^{2} - 1$




```python
solve(expand, x)
```




    [-1, 1]




```python
# function evaluation

expand.subs(x, 3)
```




$\displaystyle 8$




```python
# trigonometry

trigsimp(cos(x)**2-sin(x)**2)
```




$\displaystyle \cos{\left(2 x \right)}$




```python
# differentiation

diff(expand)
```




$\displaystyle 2 x$




```python
# integration

integrate(expand)
```




$\displaystyle \frac{x^{3}}{3} - x$




```python
# limit at infinity

limit(
    1/x,
    x,
    oo,
)
```




$\displaystyle 0$




```python
# rewriting in terms of another function

cos(x).rewrite(sin)
```




$\displaystyle \sin{\left(x + \frac{\pi}{2} \right)}$




```python

```

2f061fee872c63c3d25fb8ecd1e6fcc5754ea299
ipynb
Jupyter Notebook
SymPy Demonstration.ipynb
socathie/small-projects
55f5f5a378bd01b0ce5bf6db5da1872fd91baa6c
CC0-1.0
SymPy Demonstration.ipynb
socathie/small-projects
55f5f5a378bd01b0ce5bf6db5da1872fd91baa6c
CC0-1.0
SymPy Demonstration.ipynb
socathie/small-projects
55f5f5a378bd01b0ce5bf6db5da1872fd91baa6c
CC0-1.0
Qwen/Qwen-72B
1. YES
2. YES