sm311o, Board Problems 10

sm311o_b10.mws,wdj,4-13-98

>

> with(linalg):
with(plots):

Warning, new definition for norm

Warning, new definition for trace

Problem 1: Compute the flux of F(x,y,z)=<1,-2,3> through the surface S bounding the tetrahedron with vertices

(0,0,0),(3,0,0),(0,4,0),(0,0,1/2).

> Q1:=plot3d([x,y,0],y=0..(4*(1-x/3)),x=0..3,color=blue):
Q2:=plot3d([x,y,(1-x/3-y/4)/2],y=0..(4*(1-x/3)),x=0..3,color=green):
display3d([Q1,Q2],axes=FRAMED,style=wireframe);

[Maple Plot]

> P1:=plot3d([0,y,z],z=0..((1-y/4)/2),y=0..4,color=green):
P2:=plot3d([x,y,0],y=0..(4*(1-x/3)),x=0..3,color=red):
P3:=plot3d([x,0,z],z=0..((1-x/3)/2),x=0..3,color=blue):
display3d([P1,P2,P3],color=grey,axes=FRAMED,style=wireframe);

[Maple Plot]

>

> F:=(x,y,z)->[1,-2,3];

[Maple Math]

> P4:=fieldplot3d(F(x,y,z),x=0..3,y=0..4,z=0..(1/2),color=black):
display3d([P1,P2,P3,P4],axes=FRAMED,style=wireframe);

[Maple Plot]

S_1

> r1:=(u,v)->[u,v,(1-u/3-v/4)/2];

[Maple Math]

> r1_u:=(u0,v0)->subs({u=u0,v=v0},diff(r1(u,v),u)):
r1_u(u,v);
r1_v:=(u0,v0)->subs({u=u0,v=v0},diff(r1(u,v),v)):
r1_v(u,v);
n1:=(u,v)->crossprod(r1_u(u,v),r1_v(u,v)):
n1(u,v);

[Maple Math]

[Maple Math]

[Maple Math]

> flux1:=Int(Int(dotprod(F(op(r1(u,v))),n1(u,v)),v=0..(4*(1-u/3))),u=0..3);
int(int(dotprod(F(op(r1(u,v))),n1(u,v)),v=0..(4*(1-u/3))),u=0..3);

[Maple Math]

[Maple Math]

>

S_2

> r2:=(u,v)->[u,0,v];

[Maple Math]

> r2_u:=(u0,v0)->subs({u=u0,v=v0},diff(r2(u,v),u)):
r2_u(u,v);
r2_v:=(u0,v0)->subs({u=u0,v=v0},diff(r2(u,v),v)):
r2_v(u,v);
n2:=(u,v)->crossprod(r2_u(u,v),r2_v(u,v)):
n2(u,v);

[Maple Math]

[Maple Math]

[Maple Math]

> flux2:=Int(Int(dotprod(F(op(r2(u,v))),n2(u,v)),v=0..((1-u/3)/2)),u=0..3);
int(int(dotprod(F(op(r2(u,v))),n2(u,v)),v=0..((1-u/3)/2)),u=0..3);

[Maple Math]

[Maple Math]

>

S_3

> r3:=(u,v)->[v,u,0];

[Maple Math]

>

> r3_u:=(u0,v0)->subs({u=u0,v=v0},diff(r3(u,v),u)):
r3_u(u,v);
r3_v:=(u0,v0)->subs({u=u0,v=v0},diff(r3(u,v),v)):
r3_v(u,v);
n3:=(u,v)->crossprod(r3_u(u,v),r3_v(u,v)):
n3(u,v);

[Maple Math]

[Maple Math]

[Maple Math]

> flux3:=Int(Int(dotprod(F(op(r3(u,v))),n3(u,v)),u=0..(4*(1-v/3))),v=0..3);
int(int(dotprod(F(op(r3(u,v))),n3(u,v)),u=0..(4*(1-v/3))),v=0..3);

[Maple Math]

[Maple Math]

>

S_4

> r4:=(u,v)->[0,v,u];

[Maple Math]

>

> r4_u:=(u0,v0)->subs({u=u0,v=v0},diff(r4(u,v),u)):
r4_u(u,v);
r4_v:=(u0,v0)->subs({u=u0,v=v0},diff(r4(u,v),v)):
r4_v(u,v);
n4:=(u,v)->crossprod(r4_u(u,v),r4_v(u,v)):
n4(u,v);

[Maple Math]

[Maple Math]

[Maple Math]

> flux4:=Int(Int(dotprod(F(op(r4(u,v))),n4(u,v)),v=0..((1-u/4)/2)),u=0..4);
int(int(dotprod(F(op(r4(u,v))),n4(u,v)),v=0..((1-u/4)/2)),u=0..4);

[Maple Math]

[Maple Math]

> evalf(flux1+flux2+flux3+flux4);

[Maple Math]

>

Problem 2: Compute the flux of F(x,y,z)=<0,0,-2> through the cone surface S = {(x,y,z) | x^2+y^2=z^2, 0<z<1}.

> r:=(u,v)->[v*cos(u)*sin(Pi/4),v*sin(u)*sin(Pi/4),v*cos(Pi/4)];
plot3d(r(u,v),u=0..(2*Pi),v=0..(1/cos(Pi/4)),axes=FRAMED,title=`surface S parameterized by r(u,v)`,scaling=constrained);

[Maple Math]

[Maple Plot]

> F:=(x,y,z)->[0,0,-2];

[Maple Math]

> r_u:=(u0,v0)->subs({u=u0,v=v0},diff(r(u,v),u)):
r_u(u,v);
r_v:=(u0,v0)->subs({u=u0,v=v0},diff(r(u,v),v)):
r_v(u,v);
n:=(u,v)->crossprod(r_u(u,v),r_v(u,v)):
n(u,v);
evalf(n(0,1));

[Maple Math]

[Maple Math]

[Maple Math]

[Maple Math]

> flux:=Int(Int(dotprod(F(op(r(u,v))),n(u,v),orthogonal),u=0..(2*Pi)),v=0..(1/cos(Pi/4)));
int(int(dotprod(F(op(r(u,v))),n(u,v),orthogonal),u=0..(2*Pi)),v=0..(1/cos(Pi/4)));

[Maple Math]

[Maple Math]

>

Problem 3: Compute the line integral around the boundary of the cone S in Problem 2, of the vector field
F(x,y,z)=<y,-x,z>. Is the result consistent with Stokes' theorem?

> r:=t->[cos(t),sin(t),1];

[Maple Math]

> F:=(x,y,z)->[y,-x,z];
curl(F(x,y,z),[x,y,z]);

[Maple Math]

[Maple Math]

> Int(dotprod(F(op(r(t))),r(t),orthogonal),t=0..(2*Pi));
int(dotprod(F(op(r(t))),r(t),orthogonal),t=0..(2*Pi));

[Maple Math]

[Maple Math]

This is the result predicted by Stokes' theorem (which is the equality of the flux in Problem 2 with the line integral in Problem 3).