# 미분적분학실습2-Week-1

## 1143 days ago by jhlee2chn

구의 그래프  $x^2 + y^2 + z^2=1$

implicit_plot3d(x^2+y^2+z^2==4, (x, -3, 3), (y, -3,3), (z, -3,3))
 Sleeping...
var('x,y,z') implicit_plot3d(x^2==3*y^2+2*z^2, (x, -3, 3), (y, -3, 3), (z, -3, 3), opacity=0.5)
 Sleeping...
sqrt(2) in RR
 True True
i^3
 -I -I
3 + 2*i in CC
 True True
[1, 1.1..10]
 [1.00000000000000, 1.10000000000000, 1.20000000000000, 1.30000000000000, 1.40000000000000, 1.50000000000000, 1.60000000000000, 1.70000000000000, 1.80000000000000, 1.90000000000000, 2.00000000000000, 2.10000000000000, 2.20000000000000, 2.30000000000000, 2.40000000000000, 2.50000000000000, 2.60000000000000, 2.70000000000000, 2.80000000000000, 2.90000000000000, 3.00000000000000, 3.10000000000000, 3.20000000000000, 3.30000000000000, 3.40000000000000, 3.50000000000000, 3.60000000000000, 3.70000000000000, 3.80000000000000, 3.90000000000000, 4.00000000000000, 4.10000000000000, 4.20000000000000, 4.30000000000000, 4.40000000000000, 4.50000000000000, 4.60000000000000, 4.70000000000000, 4.80000000000000, 4.90000000000000, 5.00000000000000, 5.10000000000000, 5.20000000000000, 5.30000000000000, 5.40000000000000, 5.50000000000000, 5.60000000000000, 5.70000000000000, 5.80000000000000, 5.90000000000000, 6.00000000000000, 6.10000000000000, 6.20000000000000, 6.30000000000000, 6.40000000000000, 6.49999999999999, 6.59999999999999, 6.69999999999999, 6.79999999999999, 6.89999999999999, 6.99999999999999, 7.09999999999999, 7.19999999999999, 7.29999999999999, 7.39999999999999, 7.49999999999999, 7.59999999999999, 7.69999999999999, 7.79999999999999, 7.89999999999999, 7.99999999999999, 8.09999999999999, 8.19999999999999, 8.29999999999999, 8.39999999999999, 8.49999999999999, 8.59999999999999, 8.69999999999999, 8.79999999999999, 8.89999999999999, 8.99999999999999, 9.09999999999999, 9.19999999999999, 9.29999999999998, 9.39999999999998, 9.49999999999998, 9.59999999999998, 9.69999999999998, 9.79999999999998, 9.89999999999998, 10.0000000000000] [1.00000000000000, 1.10000000000000, 1.20000000000000, 1.30000000000000, 1.40000000000000, 1.50000000000000, 1.60000000000000, 1.70000000000000, 1.80000000000000, 1.90000000000000, 2.00000000000000, 2.10000000000000, 2.20000000000000, 2.30000000000000, 2.40000000000000, 2.50000000000000, 2.60000000000000, 2.70000000000000, 2.80000000000000, 2.90000000000000, 3.00000000000000, 3.10000000000000, 3.20000000000000, 3.30000000000000, 3.40000000000000, 3.50000000000000, 3.60000000000000, 3.70000000000000, 3.80000000000000, 3.90000000000000, 4.00000000000000, 4.10000000000000, 4.20000000000000, 4.30000000000000, 4.40000000000000, 4.50000000000000, 4.60000000000000, 4.70000000000000, 4.80000000000000, 4.90000000000000, 5.00000000000000, 5.10000000000000, 5.20000000000000, 5.30000000000000, 5.40000000000000, 5.50000000000000, 5.60000000000000, 5.70000000000000, 5.80000000000000, 5.90000000000000, 6.00000000000000, 6.10000000000000, 6.20000000000000, 6.30000000000000, 6.40000000000000, 6.49999999999999, 6.59999999999999, 6.69999999999999, 6.79999999999999, 6.89999999999999, 6.99999999999999, 7.09999999999999, 7.19999999999999, 7.29999999999999, 7.39999999999999, 7.49999999999999, 7.59999999999999, 7.69999999999999, 7.79999999999999, 7.89999999999999, 7.99999999999999, 8.09999999999999, 8.19999999999999, 8.29999999999999, 8.39999999999999, 8.49999999999999, 8.59999999999999, 8.69999999999999, 8.79999999999999, 8.89999999999999, 8.99999999999999, 9.09999999999999, 9.19999999999999, 9.29999999999998, 9.39999999999998, 9.49999999999998, 9.59999999999998, 9.69999999999998, 9.79999999999998, 9.89999999999998, 10.0000000000000]
[sin(i) for i in range(0, 10)]
 [0, sin(1), sin(2), sin(3), sin(4), sin(5), sin(6), sin(7), sin(8), sin(9)] [0, sin(1), sin(2), sin(3), sin(4), sin(5), sin(6), sin(7), sin(8), sin(9)]
A = Set([2,3,3,3,2,1,8,6,3]) print A print A.cardinality()
 {8, 1, 2, 3, 6} 5 {8, 1, 2, 3, 6} 5
10 in A
 False False
B = Set([8,6,17,-4,20, -2 ]) B
 {17, 20, 6, 8, -4, -2} {17, 20, 6, 8, -4, -2}
A.union(B)
 {1, 2, 3, 6, 8, 17, 20, -4, -2} {1, 2, 3, 6, 8, 17, 20, -4, -2}
s = 34 s
 34 34
t = 7 t = t + 1 t
 8 8
f(x) = x^2 + x + 1 f(3)
 13 13
plot(2*x^3+3*x^2-5*x-6, (x, -3, 3), ymax=20, ymin=-20)
f(x) = 2^x g(x) = 2^x + 2 h(x) = 2^(x+1) - 2 plot(f(x), (x, -3, 3)) + plot(g(x), (x, -3, 3), color='red') + plot(h(x), (x, -3, 3), color='black')
f(x) = (x^3 + x^2 + x)/(x^2 - x -2) plot(f(x), (x, -5, 5), ymin=-20, ymax=20, detect_poles='show')
f(x)=log(x, 2) g(x)=log(x-2, 2) h(x)=log(x, 2)+3 t(x)=log(x-2, 2)+3 p1=plot(f(x), (x, 0, 5)) p2=plot(g(x), (x, 2, 5), color='red') p3=plot(h(x), (x, 0, 5),color='black') p4=plot(t(x), (x, 2, 5), color='green') p1+p2+p3+p4
p1=plot(sin(pi*x-pi), (x, -1, 1), color='red', thickness=3) p2=plot(cos(pi*x-pi), (x, -1, 1), thickness=3) p1+p2
solve(x^2 - 3*x - 2 == 0, x)
 [x == -1/2*sqrt(17) + 3/2, x == 1/2*sqrt(17) + 3/2] [x == -1/2*sqrt(17) + 3/2, x == 1/2*sqrt(17) + 3/2]
solve(x^2 - 3*x + 2 <= 0, x)
 [[x >= 1, x <= 2]] [[x >= 1, x <= 2]]
var('x, y') solve(3*x - y == 2, y)
 [y == 3*x - 2] [y == 3*x - 2]
solve([2*x + y == -1, -4*x - 2*y == 2], x, y)
 [[x == -1/2*r1 - 1/2, y == r1]] [[x == -1/2*r1 - 1/2, y == r1]]
solve([2*x - y == -1, 2*x - y == 2], x, y)
 [] []
var('x, y, z') solve([2*x + 3*y + 5*z == 1, 4*x + 6*y + 10*z == 2, 6*x + 9*y + 15*z == 0], x, y, z)
 [] []
var('t') solve(abs(t-7)>=3, t)
 #0: solve_rat_ineq(ineq=abs(_SAGE_VAR_t-7) >= 3) [[t == 10], [t == 4], [t < 4], [10 < t]] #0: solve_rat_ineq(ineq=abs(_SAGE_VAR_t-7) >= 3) [[t == 10], [t == 4], [t < 4], [10 < t]]
var('x') f(x) = 2/(x^4 + 1) + 3/x show(diff(f(x), x))
 \newcommand{\Bold}[1]{\mathbf{#1}}-\frac{8 \, x^{3}}{{\left(x^{4} + 1\right)}^{2}} - \frac{3}{x^{2}}
var('x, y') f(x, y)=y^3-x*y^2+cos(x*y)-2 implicit_plot(f(x, y), (x, -10, 10), (y, -10, 10))
integral(x^2/sqrt(9-x^2), x, 1, 2)
 -sqrt(5) + sqrt(2) + 9/2*arcsin(2/3) - 9/2*arcsin(1/3) -sqrt(5) + sqrt(2) + 9/2*arcsin(2/3) - 9/2*arcsin(1/3)