<a href="https://colab.research.google.com/github/SantanaNicole/EjerciciosProgramacion1/blob/main/Feb11Calc.ipynb" target="_parent"></a>


```python
import sympy as sp
```


```python
sp.symbols('x')
```




$\displaystyle x$




```python
x= sp.symbols('x')
```


```python
y=sp.symbols('y')
```


```python
x+x
```




$\displaystyle 2 x$




```python
#2x+1=0
sp.solve(2*x+1)
```




    [-1/2]




```python
#3x+8=2x-3
ecuación = sp.Eq(3*x+8,2*x-3)
```


```python
sp.solve(ecuación)
```




    [-11]




```python
#x^2-1=0
soluciones = sp.solve(x**2-1)
```


```python
soluciones
```




    [-1, 1]




```python
soluciones[0]
```




$\displaystyle -1$




```python
soluciones[1]
```




$\displaystyle 1$




```python
sp.solve(x**2+1)
```




    [-I, I]




```python
sp.solve(x**2-3*x+1)
```




    [3/2 - sqrt(5)/2, sqrt(5)/2 + 3/2]




```python
sp.init_printing()
```


```python
sp.solve(x**2-3*x+1)
```


```python
#x^3-5*x^2=-6*x
```


```python
ecuacion = sp.Eq(x**3-5*x**2,-6*x)  #se usa coma "," no igual
```


```python
ecuacion
```


```python
sp.solve(ecuacion)
```


```python
sp.plot(x**2)
```


```python
sp.plot(x**2,x+1)
```


```python
sp.plot(x**2,ylim=(0,9),xlim=(0,3), line_color='m')
```


```python
f = 1/(x**2-4)
```


```python
sp.solve(x**2-4)
```


```python
#f(-1)=
f.subs(x,-1)
```


```python
f.subs(x,x+y)
```


```python
g = x**2-3*x*y
g
```


```python
g.subs(x,1)
```


```python
g.subs(y,2)
```


```python
g.subs(x,1).subs(y,2)
```


```python
g.subs([[x,1],[y,2]])
```


```python
f.subs(y,1)
```


```python
f.subs(x,g)
```


```python
sp.factor(x**2-2*x+1)
```


```python
sp.expand(x*(x-2)*(3*x-2)**2)   #expand trata de simplificar siempre
```


```python

```

687c6bfc3975851b4964e795a59df8537c11f080
ipynb
Jupyter Notebook
Feb11Calc.ipynb
SantanaNicole/EjerciciosProgramacion1
a1af78885a6c65c9e428789572a2daee3621192c
MIT
Feb11Calc.ipynb
SantanaNicole/EjerciciosProgramacion1
a1af78885a6c65c9e428789572a2daee3621192c
MIT
Feb11Calc.ipynb
SantanaNicole/EjerciciosProgramacion1
a1af78885a6c65c9e428789572a2daee3621192c
MIT
Qwen/Qwen-72B
1. YES
2. YES