Final, MAT329
Fall, 2015
Andy Long
This is a sampling of old final problems to consider....

#1

ContourPlot[Sin[x^2+y^2]/(x^2+y^2),{x,-2,2},{y,-2,2}]
Limit[Sin[r^2]/r^2,r->0]

#2

g[x_,y_]:=x y^2 - E^y
D[g[x,y],x]
D[g[x,y],y]
D[g[x,y],x,y]
D[g[x,y],y,x]
Dot[{1,1},{D[g[x,y],x],
D[g[x,y],y]}]

#3

Integrate[Sin[r^2]r, {r,0,3},{phi,0,2Pi}]

#4: xbar and ybar have to be zero. Zbar is the interesting one:

Integrate[2Pi rho^3Sin[phi]Cos[phi], {rho,0,1},{phi,Pi/2,Pi}]

#5:

Integrate[1, {x,0,1},{y,x,2-x}]

#6

Clear[x,y,z,w,f,g,h,l1,l2,l3,l4]
f[x_,y_,z_]:=8x - 4z
g[x_,y_,z_]:=x^2+10y^2+z^2-5
h[x_,y_,z_,w_]:=f[x,y,z]-w  g[x,y,z]
l1[x_,y_,z_,w_]=D[h[x,y,z,w],x]
l2[x_,y_,z_,w_]=D[h[x,y,z,w],y]
l3[x_,y_,z_,w_]=D[h[x,y,z,w],z]
l4[x_,y_,z_,w_]=D[h[x,y,z,w],w]
Solve[l1[x,y,z,w]==0&&l2[x,y,z,w]==0&&l3[x,y,z,w]==0&&l4[x,y,z,w]==0,{x,y,z,w}]

#7

Clear[x,y]
f[x_,y_]:= x y (1-x-y)
D[f[x,y],x]
D[f[x,y],y]
Solve[-x y+(1-x-y) y==0&&x (1-x-y)-x y==0,{x,y}]
Plot3D[f[x,y],{x,-3,3},{y,-3,3}]

#8

Integrate[rho^2Sin[phi],{rho,0,2},{phi,0,Pi/6},{theta,0,Pi}]

#9

Clear[F,x,y,z,w,f,g,h,l1,l2,l3,l4]
F[x_,y_,z_]:={y Log[z]-z,x Log[z]+1,x y/z-x}
fx[x_,y_,z_]:=F[x,y,z][[1]]
fy[x_,y_,z_]:=F[x,y,z][[2]]
fz[x_,y_,z_]:=F[x,y,z][[3]]
Integrate[fx[x,y,z],x]
Integrate[fy[x,y,z],y]
Integrate[fz[x,y,z],z]
Curl[F]:=Module[
{fx=F[x,y,z][[1]],
fy=F[x,y,z][[2]],
fz=F[x,y,z][[3]]},
{D[fz,y]-D[fy,z],
D[fx,z]-D[fz,x],
D[fy,x]-D[fx,y]}
]
Div[F]:=Module[
{fx=F[x,y,z][[1]],
fy=F[x,y,z][[2]],
fz=F[x,y,z][[3]]},
D[fz,z]+D[fx,x]+D[fy,y]
]
Curl[F]
Div[F]

#10

Integrate[-3r^3,{r,0,2},{theta,Pi,2Pi}]

#11

g[x_,y_]:=x E^(-(x^2+y^2)/2)
Plot3D[g[x,y],{x,-2,2},{y,-2,2},AxesLabel->{x,y}]
ContourPlot[g[x,y],{x,-2,2},{y,-2,2},AxesLabel->{x,y}]
gx[x_,y_]=D[g[x,y],x]
gy[x_,y_]=D[g[x,y],y]
Solve[gx[x,y]==0&&gy[x,y]==0,{x,y}]

#11b and c

grad={gx[1,1],gy[1,1]}
Dot[grad,grad]/Norm[grad]

h[x_,y_]=Simplify[gx[x,y]^2+gy[x,y]^2]
Plot3D[h[x,y],{x,-2,2},{y,-2,2},AxesLabel->{x,y},PlotRange->All]

#12: F is a gradient field, with f[x_,y_]:=x^3+y^2

Clear[f]
f[x_,y_]:=x^3+y^2
f[1,1]-f[0,0]
Integrate[Dot[{3x^2,2x^2},{1,2x}],{x,0,1}]