APM2616 Assignment 03
APM2616 Assignment 03
Question 1
Q1.1
• orthpoly::chebyshev1(2,x)
2
poly(2 x - 1, [x])
• orthpoly::chebyshev1(3,x)
3
poly(4 x - 3 x, [x])
• orthpoly::chebyshev1(4,x)
4 2
poly(8 x - 8 x + 1, [x])
• orthpoly::chebyshev1(5,x)
5 3
poly(16 x - 20 x + 5 x, [x])
Q1.2
• orthpoly::chebyshev1(2,1)
• orthpoly::chebyshev1(3,1)
• orthpoly::chebyshev1(3,1)
• orthpoly::chebyshev1(4,1)
• orthpoly::chebyshev1(5,1)
1
Student number: 57256799 APM2616 Assignment 03
Question 2
• p := polylib::Poly([a,b,c],IntMod(3))
Question 3
• assume (a > 0): limit(x^a, x = infinity)
infinity
0
Student number: 57256799 APM2616 Assignment 03
Question 4
• f := x -> sin(x)/x;
x -> sin(x)/x
• f(1.2)
0.7766992383
• D(f)
cos sin
--- - ---
id 2
id
Student number: 57256799 APM2616 Assignment 03
Question 5
• h := (x^3)*sin(x)/(1-cos(x))^2
3
x sin(x)
-------------
2
(1 - cos(x))
• simplify(h)
3
x sin(x)
-------------
2
(cos(x) - 1)
• expand(h)
3
x sin(x)
-------------
2
(1 - cos(x))
• limit(((x^3)*sin(x))/(1-cos(x))^2, x = infinity)
/ 3 \
| x sin(x) |
limit| -------------, x = infinity |
| 2 |
\ (1 - cos(x)) /
• limit(diff((x^3)*sin(x),x)/diff((1-cos(x))^2,x), x = infinity)
/ 3 2 \
| x cos(x) + 3 x sin(x) |
limit| -----------------------, x = infinity |
\ 2 sin(x) (1 - cos(x)) /
Student number: 57256799 APM2616 Assignment 03
Question 6
Q6.1
• ivp := ode({y'(PI)=1, y'(x) - y(x)*x*cos(x) = 0},y(x))
• solve(ivp)
Q6.2
• ivp := ode({y'(1)=PI, 2*y'(x) + y(x)/x = 0},y(x))
/ { y(x) } \
ode| { D(y)(1) = PI, 2 diff(y(x), x) + ---- }, y(x) |
\ { x } /
• solve(ivp)
{ 2 PI }
{ - ---- }
{ 1/2 }
{ x }
Student number: 57256799 APM2616 Assignment 03
Question 7
Q7.1
• int((x)/sqrt((2*a*x - x^2)^3),x)
2
x (x - 2 a x)
- --------------------
2 3 1/2
a ((2 a x - x ) )
Q7.2
• int((x)/(x*sqrt(1 + x^2)),x)
arcsinh(x)
Q7.3
• numeric::quadrature(sin(x)*sqrt(1 + sin(x)), x =-PI/2..PI/2)
0.9428090416
Student number: 57256799 APM2616 Assignment 03
Question 8