{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

solution18 - Solutions Solutions to Assignment#18 syms x...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Solutions % Solutions to Assignment #18 syms x % Prob. 1 (a) expand((x-3)*(x+3)*(x^2expand((x expand((x-3)*(x+3)*(x^2-1)) ans = x^4-10*x^2+9 (b) factor(x^3+5*x^2-2*xfactor(x^3+5*x^2 factor(x^3+5*x^2-2*x-24) ans = (x-2)*(x+4)*(x+3) (c) simplify(x^2*((x-3)*x+5)simplify(x^2*((x simplify(x^2*((x-3)*x+5)-3*(x+7)) ans = x^4-3*x^3+5*x^2-3*x-21 (d) collect(x^2*((x-3)*x+5)collect(x^2*((x collect(x^2*((x-3)*x+5)-3*(x+7)) ans = x^4-3*x^3+5*x^2-3*x-21 (e) pretty(x^3+5*x^2-2*xpretty(x^3+5*x^2 pretty(x^3+5*x^2-2*x-24) 3 2 x + 5 x - 2 x - 24 % Prob2 Prob2 syms x y z a b c d (a) solve(x^3+5*x^2-2*x-24) solve(x^3+5*x^2 solve(x^3+5*x^2-2*x-24) ans = 2 -3 -4 (b) solve(x^2-3*b*c*xsolve(x^2 solve(x^2-3*b*c*x-d,c) ans = 1/3*(x^2-d)/b/x (c) [x,y,z]=solve('3*x+2*y=0','x-y+2*z=3','2*x+2*y[x,y,z]=solve('3*x+2*y=0','x [x,y,z]=solve('3*x+2*y=0','x-y+2*z=3','2*x+2*y-4*z=5') x= 11/4 y= -33/8 z= -31/16 % Prob Prob syms x 3 yz (a) z=x*y^(1/2)z=x*y^(1/2) z=x*y^(1/2)-2/y; Dzy=diff(z,y) Dzy=diff(z,y) Dzy = 1/2*x/y^(1/2)+2/y^2 (b) clear clear all syms x y z z=x*y^(1/2)z=x*y^(1/2)-2/y; Dzx=diff(z,x) Dzx = y^(1/2) (c) clear clear all syms x y t y=x^2+tan(x) Dy=diff(y) y= x^2+tan(x) Dy = 2*x+1+tan(x)^2 (d) f=int(3*xf=int(3*x f=int(3*x-2/x) f= 3/2*x^2-2*log(x) (e) F=int(t^3+sin(t),t,1,3) F=int(t^3+sin(t),t,1,3) clear all F= 20+cos(1)-cos(3) Prob 4 syms syms x y (a) y=dsolve('Dy+3*x=2','x') y=dsolve('Dy+3*x=2','x') y= -3/2*x^2+2*x+C1 (b) y=dsolve('Dy+3*x=2','y(3)=2','x') y=dsolve('Dy+3*x=2','y(3)=2','x') y= -3/2*x^2+2*x+19/2 (c) y=dsolve('D2y+3Dy+2*y=0','y(0)=2','Dy(0)=0','x') y=dsolve('D2y+3Dy+2*y=0','y(0)=2','Dy(0)=0','x') y= -3/2+7/2*cos(2^(1/2)*x) Prob 5 ezplot('x^0.5',[0,3]) ezplot('x^0.5',[0,3]) xlabel('x'),ylabel('y') ...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online