P.Fradin a écrit:
Je pense qu'il vaudrait mieux prendre V = [0,7] pour que le cylindre soit droit !
La perspective, ça trompe énormément !
P.Fradin a écrit:
Je pense qu'il vaudrait mieux prendre V = [0,7] pour que le cylindre soit droit !
[//command
view(-4,6,-2,8), Marges(0,0,0,0), size(8),
viewDir(10,70), //angles de vues theta et phi
V := [1+2*i,7],
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(for z in polyreg(0,3,12) do [z,0] od,V),
Width:=6, HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
]
[//command
view(-4,6,-2,8), Marges(0,0,0,0), size(8),
viewDir(10,70), //angles de vues theta et phi
V := [1+2*i,7], A := 3.45*vecJ+V, B := pxy(A),
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(for z in polyreg(0,3,12) do [z,0] od,V),
Width:=6, HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
draw("line", Proj3D([A,B]),
[legend:="$h$",labeldir:="O", marker:=[0,CDdistance',1,CDdistance']])
]
[//command
view(-4,10,-2,8), Marges(0,0,0,0), size(8),
viewDir(15,80), //angles de vues theta et phi
V := [1+6*i,7], A := 3.45*vecJ+V, B := pxy(A),
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(for z in polyreg(0,3,12) do [z,0] od,V),
Width:=6, HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
draw("line", Proj3D([A,B]),
[legend:="$h$",labeldir:="O", marker:=[0,CDdistance',1,CDdistance']])
]
[//command
view(-6,6,-7,5), Marges(0,0,0,0), size(8),
viewDir(10,70), //angles de vues theta et phi
V := [8*i,-3],
A := 2.45*vecK-V/2, B := proj3d(A,[A+V,vecJ]),
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(for z in polyreg(0,3,12) do [Im(z)-4*i,Re(z)] od,V),
Width:=6,
draw("line", Proj3D([A,[-4*i,0]]) ),
HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
draw("line", Proj3D([A,B]),
[legend:="$h$",labelpos:=0.5,labeldir:="S",Arrows:=2]),
draw("line", Proj3D([B,[-4*i,0]+V]) ),
draw("line", Proj3D([A,[-4*i,0]]), [LineStyle:=userdash] ),
]
[//command
view(-6,6,-5,5.5), Marges(0,0,0,0), size(8),
viewDir(30,70), //angles de vues theta et phi
V := 8*vecJ, // vecteur orthogonal au plan xOz
// base = liste de points du plan xOy dans le sens direct
base := 0.75*[2+2.4*i, -2.9+3.6*i, -4.3+0.3*i, -2-i, 0.2-3.4*i, 3.1-1.2*i],
// base 3d : on transforme base en liste de points du plan y=-4
base3d := for z in base do [Im(z)-4*i,Re(z)] od,
A := base3d[11,2]+1.5*vecK, B := proj3d(A,[A+V,vecJ]),
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(base3d,V),
Width:=6,
HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
draw("line", Proj3D([A,B]),
[legend:="$h$",labelpos:=0.5,labeldir:="N",Arrows:=2]),
draw("line", Proj3D([B,base3d[11,2]+V]) ),
draw("line", Proj3D([A,base3d[11,2]]) )
]
[//command
view(-6,6,-5,5.5), Marges(0,0,0,0), size(8),
viewDir(35,60), //angles de vues theta et phi
V := 8*vecJ,
// base = liste de points du plan xOy dans le sens direct
base := 0.75*[2+2.4*i, -2.9+3.6*i, -4.3+0.3*i, -2-i, 0.2-3.4*i, 3.1-1.2*i],
// base 3d : on transforme base en liste de points du plan y=-4
base3d := for z in base do [Im(z)-4*i,Re(z)] od,
A := base3d[11,2]+1.5*vecK, B := proj3d(A,[A+V,vecJ]),
// Prisme(listes de points 3D, vecteur 3D)
Cyl1:=Prisme(base3d,V),
Width:=6,
FillStyle:=none, A' := base3d[11,2],
a:= Proj3D(A'), b:=Proj3D(A'-0.25*vecJ),c:= Proj3D(A'-1.5*vecK),
angleD(b,a,c,0.5),
HideStyle:=userdash, HideWidth:=6, FillStyle:=full,
DrawPoly(Cyl1,4,0.5), // mode 4 et contraste 0.5
draw("line", Proj3D([A,B]),
[legend:="$h$",labelpos:=0.5,labeldir:="N",Arrows:=2]),
draw("line", Proj3D([B,base3d[11,2]+V]) ),
draw("line", Proj3D([A,base3d[11,2]])),
FillStyle:=none,
A' := base3d[11,2]+V,
a:= Proj3D(A'), b:=Proj3D(A'+0.25*vecJ),c:= Proj3D(A'-1.5*vecK),
angleD(b,a,c,0.5),
LineStyle:=dotted, Droite(Proj3D( [A'-0.25*vecJ,A'+0.25*vecJ]) ),
A' := base3d[11,2],
a:= Proj3D(A'), b:=Proj3D(A'-0.25*vecJ),c:= Proj3D(A'-1.5*vecK),
angleD(b,a,c,0.5),
]
[//command
Marges(0,0,0,0),
theta :=80*deg, phi :=70*deg,
V:=5*(-vecI+vecJ),
S:=Cylindre(M(0,0,-4),V,2,50,0),
DrawSmoothFacet(S,[color:=white,backculling:=0]),
HideStyle := userdash,
Dcylindre(M(0,0,-4),V,2,4),
A:=S[51,2],Width:=4,LabelSize:=footnotesize,
draw("line", Proj3D([A,A+V]),
[legend:="$h$",labelpos:=0.5,labeldir:=[0.2,i]]),
draw("line", Proj3D([M(0,0,-4)+V,A+V]),
[legend:="$r$",labelpos:=0.5,labeldir:=[0.2,i]]),
FillStyle:=none,
angleD(Proj3D(A+V),Proj3D(A),Proj3D(S[53,2]),0.25),
LineStyle:=HideStyle,
angleD(Proj3D(M(0,0,-4)+V),Proj3D(A+V),Proj3D(A),0.25),
]
[//command
view(-10,1,-10,0.5), Marges(0,0,0,0), size(8),
view3D(0,12,-10,10,-10,10),
theta :=40*deg, phi :=30*deg,
NewMac("f", "2*[1+1.5*t^2+i*t^3/1.5,1]", t),
D := [Origin, -vecI], // axe
C:=rotCurve(f(t), D, 0,1.5, 0,2*pi, 25, 50),
Build3D(
bdSep( // Plans séparateurs invisibles, surface non convexe
for k from 0 to 24 do
getplan([M(2*(1+1.5*(k*1.5/24)^2),0,0),vecI]),
od),
bdFacet(C, [color:=lightgray]),
bdDroite(D, scale:=1)
),
Display3D(),
tMin:=0, tMax:=1.5, NbPoints:=25, Width:=8,
Courbe3D(f(t))
]
[//command
view(-10,1,-10,0.5), Marges(0,0,0,0), size(8),
view3D(0,12,-10,10,-10,10),
theta :=40*deg, phi :=30*deg,
NewMac("f", "2*[1+1.5*t^2+i*t^3/1.5,1]", t),
D := [Origin, -vecI], // axe
C:=rotCurve(f(t), D, 0,1.5, 0,2*pi, 25, 50),
Build3D(
bdSep( // Plan séparateurs invisibles, surface non convexe
for k from 0 to 24 do
getplan([M(2*(1+1.5*(k*1.5/24)^2),0,0),vecI]),
od),
bdFacet(C, [color:=lightgray]),
bdDroite(D, [scale:=1,linestyle:=userdash]),
),
Display3D(),
tMin:=0, tMax:=1.5, NbPoints:=25, Width:=8,
Courbe3D(f(t)),
LabelDot(Proj3D(f(1)), "$\mathcal C$","E")
]
[//command
view(-2,7.5,-9.75,0.5), Marges(0,0,0,0), size(7.5),
view3D(-5,12,-12,10,-10,10),
theta:=20*deg, phi:=30*deg,
NewMac("f", "2*[1+1.5*t^2-i*t^3/1.5,1]",t),
D := [Origin,vecJ+vecI], // axe
C:=rotCurve(f(t),D,-1.5,0,-pi,pi,25,50),
Build3D(
bdFacet(C, [color:=lightgray,opacity:=0.95,contrast:=1]),
bdDroite(D, [scale:=1,linestyle:=userdash]),
bdLine(Bord(C),[width:=8])
),
Display3D(),
tMin:=-1.5, tMax:=0, NbPoints:=25, Width:=8,
Courbe3D(f(t)),
LabelDot(Proj3D(f(-1)),"$\mathscr{C}$","E",0,0.15),
LabelDot(Proj3D(8.5*(vecJ+vecI)),"$\Delta$","E",0,0.2),
]
[//command
//view(-8,8,-5.5,5),
Marges(0,0,0,0), //size(8),
V:= [4-2*i,-5],
C:=curve2Cone([4*cos(t)-cos(4*t)+i*(4*sin(t)-sin(4*t)),2],
0,2*pi,V,1,B),
P2:=[M(0,0,3)+V/2,vecJ+6*vecK],
Delta := [M(2,-5,-4), V],
// B récupère la liste des points 3d des bords haut et bas du cylindre
C2:= Merge3d(Intersection(P2,C)),
I := interDP([Delta,V],P2),
H1 := B[45,2], H2 := [H1[1],-5],
Build3D(
bdPlan(P2,[color:=white, opacity:=0.7, scale:=1.4,contrast:=0.5]),
bdFacet(C,[color:=white, opacity:=0.8, width:=2, border:=1]),
bdLine(C2, [width:=6, color:=black]),
bdLine([H1,H2], [arrows:=2,width:=6, color:=black]),
bdLine([V,H2], [width:=2, color:=black]),
bdLabel((H1+H2)/2,"$h$", [labelpos:=[0.25,1]])
),
Display3D(),
A:=(B[101,2]+B[103,2])/2, // 2ième point 3d du bord (le kième point est B[2k-1,2])
//E:=(B[-155,2]+B[45,2])/2, // 2ième point 3d du bord (le kième point est B[2k-1,2])
LabelSize:=footnotesize,
LabelDot(Proj3D(A),"$\mathscr{C}$","N",0,0.15),
LabelDot(Proj3D(V),"$S$","O",0,0.15),
draw("line", Proj3D(B), [LineStyle:=noline, FillStyle:=fdiag, FillColor:=black]),
]
Revenir vers Questions - Réponses
Utilisateurs parcourant ce forum : Aucun utilisateur inscrit et 19 invités