Google Classroom
GeoGebraGeoGebra Classroom

Keishiro Ueki - 17 sep. 2020

Author:
Thijs
Based on 上木 敬士郎 Keishiro Ueki @ChocoLinkage - 17 sep. 2020 Setup Scripting #----------------------------------------- # Engine #----------------------------------------- α = Slider(0,360°,1°, 3, 300, true ,true) O = ( 0, 0) X = (-2, 0) M = Midpoint(O,X) Y = ( 0, 3.35) r = 2.5 X1= X + (cos(α),sin(α)) X2= Reflect(X1,X) sX1X2 = Segment(X1,X2) Frame = Polyline(O,X,Y,O) Bottom= (y = -13.8) #----------------------------------------- # Transmission #----------------------------------------- A1= Intersect(Circle(X1,r), Circle(O,r), 1) B1= Reflect(X1,A1) C1= Intersect(Circle(B1,2), Circle(Y,2), 1) D1= Reflect(C1,Y) E1= Reflect(B1,Y) F1= Reflect(D1,Line(B1,E1)) G1= Reflect(F1,Y) sOA1= Segment(O,A1) polX1=Polyline(X1,B1,C1,D1,E1,F1,G1,B1) A2= Intersect(Circle(X2,r), Circle(O,r), 1) B2= Reflect(X2,A2) C2= Intersect(Circle(B2,2), Circle(Y,2), 1) D2= Reflect(C2,Y) E2= Reflect(B2,Y) F2= Reflect(D2,Line(B2,E2)) G2= Reflect(F2,Y) sOA2= Segment(O,A2) polX2=Polyline(X2,B2,C2,D2,E2,F2,G2,B2) #----------------------------------------- # Legs #----------------------------------------- Q1= Intersect(Circle(E1,2), Circle(O,2), 1) Q2= Intersect(Circle(E2,2), Circle(O,2), 1) u1= Vector(E1, Midpoint(E1,Q1)) u2= Vector(E2, Midpoint(E2,Q2)) v1= Vector(-0.5 Q1) v2= Vector(-0.5 Q2) w = Vector(M) M1= {{x(u1),x(v1),x(w)}, {y(u1),y(v1),y(w)}} M2= {{x(u2),x(v2),x(w)}, {y(u2),y(v2),y(w)}} Lp = {(-2,-2, 0),(-1,-2, 0),(-1, 1, 0),(-1, 2, 0),( 0, 0, 1),( 0,-2, 0),( 0, 1, 0),( 0, 2, 0),( 0, 2, 1),( 3, 1, 0),( 3, 5, 0),( 3, 6, 0),( 4, 1, 0),( 4, 2, 0),( 4, 2, 1),( 4, 6, 0),( 4, 6, 1),( 7, 5, 0),( 8, 5, 0),( 8, 6, 0),( 8, 6, 1),( 7,10, 0),( 8,10, 0),( 8,10, 1),(10,10, 1),(10,10, 0),(10,10,-3)} LP1 = Zip(M1*p ,p,Lp) LP2 = Zip(M2*p ,p,Lp) Lm={ 1, 2, 3, 4, 5, 6, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25} Ln={ 6, 4,13,14, 9, 8, 9,15,12,19,20,16,15,17,17,21,22,23,21,24,26,24,25,27} Ls1=Zip(Segment(Element(LP1,m),Element(LP1,n)) ,m,Lm, n,Ln) Ls2=Zip(Segment(Element(LP2,m),Element(LP2,n)) ,m,Lm, n,Ln) #----------------------------------------- # Settings #----------------------------------------- Lobj={"O","X","M","Y","X1","X2", "A1","B1","C1","D1","E1","F1","G1", "A2","B2","C2","D2","E2","F2","G2"} Execute(Zip("ShowLabel("+obj+",false)", obj,Lobj)) Execute(Zip("SetPointSize("+obj+",4)", obj,Lobj)) Execute(Zip("SetDynamicColor("+obj+",0,0,0)", obj,Lobj)) Showlabel(Frame, false) Showlabel(Bottom,false) Setcolor(Bottom,"DarkRed") Lobj= {"sX1X2","sOA1","sOA2","polX1","polX2"} Execute(Zip("ShowLabel("+obj+",false)", obj,Lobj)) Lobj={"Q1","Q2","u1","u2","v1","v2","w"} Execute(zip("SetVisibleInView("+obj+", 1, false)", obj,Lobj)) Delete(Lobj) Setcolor(LP1,"Black") Setcolor(LP2,"Black") Setcolor(Ls1,"Black") Setcolor(Ls2,"Black") SetPointSize(LP1,4) SetPointSize(LP2,4) ShowGrid(false) ShowAxes(false) CenterView((1,-4)) SetVisibleInView(α,1,false) StartAnimation(α,true)