Loading VectorCalculus  

 

Posisjonsvektor: 

`:=`(r, `<,>`(cos(t), sin(t), VectorCalculus:-`*`(t, `/`(1, 
3)))) 

Vector[column](%id = 44270472) (1)
 

Hastighet: 

`:=`(v, diff(r, t)) 

Vector[column](%id = 40281792) (2)
 

Akselerasjon: 

`:=`(aks, diff(v, t)) 

Vector[column](%id = 45180800) (3)
 

Enhetstangent: 

`:=`(T, VectorCalculus:-`*`(v, `/`(1, `*`(Norm(v))))) 

Vector[column](%id = 45209712) (4)
 

Deriverer T: 

`:=`(Tt, diff(T, t)) 

Vector[column](%id = 16755752) (5)
 

Enhetsnormal: 

`:=`(N, VectorCalculus:-`*`(Tt, `/`(1, `*`(Norm(Tt))))) 

Vector[column](%id = 41028328) (6)
 

 

Binormal: 

`:=`(B, simplify(CrossProduct(T, N))) 

Vector[column](%id = 34372280) (7)
 

Krumning: 

`:=`(kappa, VectorCalculus:-`*`(Norm(Tt), `/`(1, `*`(Norm(v))))) 

`/`(9, 10) (8)
 

Torsjon: 

`:=`(tau, simplify(VectorCalculus:-`-`(VectorCalculus:-`*`(`/`(1, 
`*`(Norm(v))), DotProduct(diff(B, t), N))))) 

`/`(3, 10) (9)
 

Plotter kurven over et intervall [a, b], der 

`:=`(a, 0) = 0`:=`(b, 6.28) = 6.28SpaceCurve(r, t = a .. b, color = blue, thickness = 3, axes = 
boxed) 

Plot
 

 

Definerer funksjoner av u, som plotter kurven over et intervall samt posisjonsvektoren og TNB i t = u; -1 

`:=`(A, proc (u) options operator, arrow; SpaceCurve(r, t = a .. 
u, color = blue, thickness = 3, scaling = constrained, axes = boxed) end
 proc) 

proc (u) 
options operator, arrow; VectorCalculus:-SpaceCurve(r, t = a .. u, color
 = blue, thickness = 3, scaling = constrained, axes = boxed) end proc (10)
 

`:=`(B1, proc (u) options operator, arrow; PlotVector(eval(r, t = 
u), color = black) end proc) 

proc (u) 
options operator, arrow; 
VectorCalculus:-PlotVector(VectorCalculus:-eval(r, t = u), color = 
black) end proc (11)
 

`:=`(B2, proc (u) options operator, arrow; 
PlotVector(RootedVector(root = eval(r, t = u), eval(T, t = u)), color = 
red) end proc) 

proc (u) 
options operator, arrow; 
VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(T, t = u)), color =
 red) end proc
proc (u) options operator, 
arrow; VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(T, t = u)), color =
 red) end proc
(12)
 

 

`:=`(B3, proc (u) options operator, arrow; 
PlotVector(RootedVector(root = eval(r, t = u), eval(N, t = u)), color = 
green) end proc) 

proc (u) 
options operator, arrow; 
VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(N, t = u)), color =
 green) end proc
proc (u) options operator, 
arrow; VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(N, t = u)), color =
 green) end proc
(13)
 

`:=`(B4, proc (u) options operator, arrow; 
PlotVector(RootedVector(root = eval(r, t = u), eval(B, t = u)), color = 
yellow) end proc) 

proc (u) 
options operator, arrow; 
VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(B, t = u)), color =
 yellow) end proc
proc (u) options operator, 
arrow; VectorCalculus:-PlotVector(VectorCalculus:-RootedVector(root = 
VectorCalculus:-eval(r, t = u), VectorCalculus:-eval(B, t = u)), color =
 yellow) end proc
(14)
 

 

Neste plot er av en sylinder (den spesielle kurven vi ser på her, ligger på en sylinder, så vi tar med denne for å få et bedre bilde av situasjonen). 

`:=`(C, plots[implicitplot3d](VectorCalculus:-`+`(`*`(`^`(x, 2)), 
`*`(`^`(y, 2))) = 1, x = VectorCalculus:-`-`(1) .. 1, y = 
VectorCalculus:-`-`(1) .. 1, z = 0 .. VectorCalculus:-`*`(b, `/`(1, 3)),
 col...
`:=`(C, 
plots[implicitplot3d](VectorCalculus:-`+`(`*`(`^`(x, 2)), `*`(`^`(y, 
2))) = 1, x = VectorCalculus:-`-`(1) .. 1, y = VectorCalculus:-`-`(1) ..
 1, z = 0 .. VectorCalculus:-`*`(b, `/`(1, 3)), col...
 

PLOT3D(ISOSURFACE(Array(1..10, 1..10, 1..10, 1..4, {(1, 1, 1, 1) = 
-1.0, (1, 1, 1, 2) = -1.0, (1, 1, 1, 3) = -1.0, (1, 1, 1, 4) = -1.0, (1,
 1, 2, 1) = -1.0, (1, 1, 2, 2) = -1.0, (1, 1, 2, 3) = -1.0, (... (15)
 

Antall bilder i animasjonen: 

`:=`(M, 40); 1 

40 (16)
 

Lager en følge med alle bildene, 

`:=`(S, seq(plots[display]([A(VectorCalculus:-`+`(a, 
VectorCalculus:-`*`(VectorCalculus:-`*`(VectorCalculus:-`+`(b, 
VectorCalculus:-`-`(a)), i), `/`(1, `*`(M))))), 
B1(VectorCalculus:-`+`(a, VectorCalc...
`:=`(S, seq(plots[display]([A(VectorCalculus:-`+`(a, 
VectorCalculus:-`*`(VectorCalculus:-`*`(VectorCalculus:-`+`(b, 
VectorCalculus:-`-`(a)), i), `/`(1, `*`(M))))), 
B1(VectorCalculus:-`+`(a, VectorCalc...
 

og viser denne: 

plots[display](S, insequence = true) 

Plot
 

Enklere plot, med kun posisjonsvektor og enhetstangent: 

`:=`(S2, seq(plots[display]([A(VectorCalculus:-`+`(a, 
VectorCalculus:-`*`(VectorCalculus:-`*`(VectorCalculus:-`+`(b, 
VectorCalculus:-`-`(a)), i), `/`(1, `*`(M))))), 
B1(VectorCalculus:-`+`(a, VectorCal... 

plots[display](S2, insequence = true) 

Plot