Skip to content

Commit 15fc461

Browse files
authored
Merge pull request #92 from nishanpoojary/master
Updated gifs and scripts
2 parents 4b038d8 + 8011e2c commit 15fc461

27 files changed

+536
-315
lines changed
83.3 KB
Binary file not shown.
-1.42 KB
Binary file not shown.

FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-functions/file1_multivar_func_examples.py

Lines changed: 26 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -17,45 +17,35 @@ def construct(self):
1717
rectangle_area[2].set_color(YELLOW_C)
1818
rectangle_area[4].set_color(BLUE_C)
1919

20+
21+
triangle = Polygon(np.array([-3,-1.5,0]), np.array([2,-1.5,0]), np.array([2,1.5,0]), np.array([-3,-1.5,0]), color = PURPLE)
2022

21-
square = Square(side_length = 5, color = PURPLE)
22-
square_area_func = TexMobject("Area", "=", "f(", "Length", ")")
23-
square_area_func[0].set_color(GREEN_C)
24-
square_area_func[2].set_color(ORANGE)
25-
square_area_func[3].set_color(BLUE_C)
26-
square_area_func[4].set_color(ORANGE)
27-
28-
square_area = TexMobject("Area", "=", "Length^2")
29-
square_area[0].set_color(GREEN_C)
30-
square_area[2].set_color(BLUE_C)
31-
23+
triangle_area_func = TexMobject("Area", "=", "f(", "Base", ",", "Height", ")").scale(0.6).move_to(1*DOWN)
24+
triangle_area_func[0].set_color(RED_C)
25+
triangle_area_func[2].set_color(ORANGE)
26+
triangle_area_func[3].set_color(YELLOW_C)
27+
triangle_area_func[5].set_color(BLUE_C)
28+
triangle_area_func[6].set_color(ORANGE)
3229

33-
circle = Circle(radius = 2, color = PINK)
34-
circle_area_func = TexMobject("Area", "=", "f(", "r", ")")
35-
circle_area_func[0].set_color(YELLOW_C)
36-
circle_area_func[2].set_color(ORANGE)
37-
circle_area_func[3].set_color(GREEN_C)
38-
circle_area_func[4].set_color(ORANGE)
30+
triangle_area = TexMobject("Area", "=", "\\frac{1}{2}", "\\times", "Base", "\\times", "Height").scale(0.6).move_to(1*DOWN)
31+
triangle_area[0].set_color(RED_C)
32+
triangle_area[2].set_color(GREEN_C)
33+
triangle_area[4].set_color(YELLOW_C)
34+
triangle_area[6].set_color(BLUE_C)
3935

40-
circle_area = TexMobject("Area", "=", "\\pi", "r^2")
41-
circle_area[0].set_color(YELLOW_C)
42-
circle_area[2].set_color(BLUE_C)
43-
circle_area[3].set_color(GREEN_C)
44-
45-
radius = Line(ORIGIN,2*RIGHT, color = RED_C)
46-
4736

4837

4938
braces_rect1 = Brace(rectangle, LEFT)
5039
eq_text1 = braces_rect1.get_text("Length").set_color(YELLOW_C)
5140
braces_rect2 = Brace(rectangle, UP)
5241
eq_text2 = braces_rect2.get_text("Breadth").set_color(BLUE_C)
53-
54-
braces_square = Brace(square, LEFT)
55-
braces_square_text = braces_square.get_text("Length").set_color(BLUE_C)
56-
57-
radius_text = TexMobject("r", color = GREEN_C).next_to(radius,UP)
5842

43+
44+
braces_triangle_height = Brace(triangle, RIGHT)
45+
braces_triangle_height_text = braces_triangle_height.get_text("Height").set_color(BLUE_C)
46+
47+
braces_triangle_base = Brace(triangle, DOWN)
48+
braces_triangle_base_text = braces_triangle_base.get_text("Base").set_color(YELLOW_C)
5949

6050

6151
self.play(ShowCreation(rectangle))
@@ -69,28 +59,19 @@ def construct(self):
6959
self.play(FadeOut(braces_rect1),FadeOut(eq_text1),FadeOut(braces_rect2),FadeOut(eq_text2),FadeOut(rectangle_area_func))
7060

7161

72-
self.play(Transform(rectangle, square))
73-
self.wait(1)
74-
self.play(GrowFromCenter(braces_square),Write(braces_square_text))
62+
self.play(Transform(rectangle, triangle))
7563
self.wait(1)
76-
self.play(Write(square_area_func))
64+
self.play(GrowFromCenter(braces_triangle_height),Write(braces_triangle_height_text))
7765
self.wait(1)
78-
self.play(Transform(square_area_func, square_area))
66+
self.play(GrowFromCenter(braces_triangle_base),Write(braces_triangle_base_text))
7967
self.wait(1)
80-
self.play(FadeOut(braces_square),FadeOut(braces_square_text),FadeOut(square_area_func))
81-
82-
83-
self.play(Transform(rectangle, circle))
68+
self.play(Write(triangle_area_func))
8469
self.wait(1)
85-
self.play(ShowCreation(radius),Write(radius_text))
70+
self.play(Transform(triangle_area_func, triangle_area))
8671
self.wait(1)
87-
self.play(FadeOut(radius_text),FadeOut(radius))
72+
self.play(FadeOut(braces_triangle_height),FadeOut(braces_triangle_height_text),FadeOut(braces_triangle_base),FadeOut(braces_triangle_base_text),FadeOut(triangle_area_func))
8873
self.wait(1)
89-
self.play(Write(circle_area_func))
90-
self.wait(1)
91-
self.play(Transform(circle_area_func, circle_area))
92-
self.wait(1)
93-
self.play(FadeOut(circle_area_func))
74+
9475

9576

9677

FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-functions/file2_multivariable_func_respresentation.py

Lines changed: 66 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@ def construct(self):
1212
self.play(FadeOut(topic))
1313

1414

15-
#circle = Circle()
16-
#circle.scale(3)
17-
1815
scalar_function = TextMobject("Scalar Valued Function")
1916
scalar_function.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
2017
scalar_function.scale(1.5)
@@ -69,30 +66,83 @@ def construct(self):
6966
number2.set_color(ORANGE)
7067

7168
output2 = TextMobject(r"$ \begin{bmatrix} 4 \\ 6 \end{bmatrix}$")
72-
#output2.scale(1.5)
7369
output2.set_color(BLUE_C)
7470
output2.move_to(3*RIGHT)
7571

76-
#eqn2_1 = TextMobject(r"f(2,1,3) = $2^2(1) + 2(1)(3)$")
77-
#eqn2_1.set_color(YELLOW)
78-
79-
#eqn2_2 = TextMobject(r"f(2,1,3) = $2 + 6$")
80-
#eqn2_2.set_color(YELLOW)
81-
72+
8273

8374
self.play(Write(eqn2))
8475

8576
self.wait()
8677
self.play(ApplyMethod(number2.move_to, 3*LEFT))
8778
self.play(FadeOut(number2))
8879

89-
#self.play(Transform(eqn2, eqn2_1))
90-
#self.wait(1)
91-
#self.play(Transform(eqn2, eqn2_2))
92-
#self.wait(1)
93-
9480
self.play(ApplyMethod(output2.move_to, 2.5*DOWN+4*RIGHT))
9581
self.wait()
9682
self.play(Write(vector_function))
9783
self.play(FadeOut(output2),FadeOut(eqn2), FadeOut(vector_function), FadeOut(rectangle))
98-
self.wait()
84+
self.wait()
85+
86+
87+
88+
class VectorValuedFunc(Scene):
89+
def construct(self):
90+
numberplane = NumberPlane()
91+
92+
rectangle = Rectangle(height = 1, width = 2, color = PURPLE).move_to(2.5*UP+5*RIGHT)
93+
94+
eqn = TextMobject(r"f(x,y) = $ \begin{bmatrix} xy \\ \frac{y}{x} \end{bmatrix}$").scale(0.6).move_to(2.5*UP+5*RIGHT).set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
95+
96+
dot1 = Dot().set_color(PINK).move_to(np.array([2,2,0]))
97+
98+
number1 = TextMobject("(2,2)").scale(0.6).next_to(dot1, RIGHT).set_color(PINK)
99+
100+
output1 = TextMobject(r"$ \begin{bmatrix} 4 \\ 1 \end{bmatrix}$").scale(0.6).set_color(YELLOW_C).move_to(2.5*UP+6.5*RIGHT)
101+
102+
vector1 = Arrow(np.array([2,2,0]), np.array([4,1,0]), color = RED_C, buff = 0.01, tip_length = 0.25)
103+
104+
dot2 = Dot().set_color(PINK).move_to(np.array([-1,2,0]))
105+
106+
number2 = TextMobject("(-1,2)").scale(0.6).next_to(dot2, RIGHT).set_color(PINK)
107+
108+
output2 = TextMobject(r"$ \begin{bmatrix} -2 \\ -2 \end{bmatrix}$").scale(0.6).set_color(YELLOW_C).move_to(2.5*UP+6.5*RIGHT)
109+
110+
vector2 = Arrow(np.array([-1,2,0]), np.array([-2,-2,0]), color = RED_C, buff = 0.01, tip_length = 0.25)
111+
112+
113+
vector_valued_function = TextMobject("Vector Valued Function").move_to(2.5*UP+3*LEFT).set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
114+
115+
116+
self.play(ShowCreation(numberplane))
117+
self.wait()
118+
self.play(ShowCreation(rectangle), ShowCreation(eqn))
119+
self.wait()
120+
self.play(ShowCreation(dot1), ShowCreation(number1))
121+
self.wait(0.5)
122+
self.play(ApplyMethod(number1.move_to, 2.5*UP+ 3.5*RIGHT))
123+
self.wait(0.5)
124+
self.play(FadeOut(number1))
125+
self.wait(0.5)
126+
self.play(ShowCreation(output1))
127+
self.wait(0.5)
128+
self.play(ShowCreation(vector1))
129+
self.wait(0.5)
130+
self.play(ApplyMethod(output1.move_to, 1*UP+ 4.5*RIGHT))
131+
self.wait()
132+
133+
134+
self.play(ShowCreation(dot2), ShowCreation(number2))
135+
self.wait(0.5)
136+
self.play(ApplyMethod(number2.move_to, 2.5*UP+ 3.5*RIGHT))
137+
self.wait(0.5)
138+
self.play(FadeOut(number2))
139+
self.wait(0.5)
140+
self.play(ShowCreation(output2))
141+
self.wait(0.5)
142+
self.play(ShowCreation(vector2))
143+
self.wait(0.5)
144+
self.play(ApplyMethod(output2.move_to, 2*DOWN+ 2.5*LEFT))
145+
self.wait()
146+
self.play(Write(vector_valued_function))
147+
self.wait(2)
148+

FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-functions/file3_sphere.py

Lines changed: 36 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -4,28 +4,24 @@ class Sphere(ThreeDScene):
44
def construct(self):
55
axes = ThreeDAxes() # creates a 3D Axis
66

7-
text3d = TextMobject(r"$f(x,y) \rightarrow Point(x,y,z)$")
8-
text3d1 = TextMobject(r"$f(x,y) \rightarrow Point(x,y, \sqrt{r^2 - x^2 - y^2})$")
9-
self.add_fixed_in_frame_mobjects(text3d)
10-
text3d.scale(0.7)
7+
text3d1 = TextMobject(r"$z = f(x,y) = \sqrt{r^2 - x^2 - y^2}$")
8+
119
text3d1.scale(0.7)
12-
text3d.to_corner(UL)
10+
1311
text3d1.to_corner(UL)
14-
text3d.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
12+
1513
text3d1.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
16-
self.play(Write(text3d))
14+
self.play(Write(text3d1))
1715
self.wait(1)
1816

19-
self.play(Transform(text3d,text3d1))
2017
self.add_fixed_in_frame_mobjects(text3d1)
21-
self.play(FadeOut(text3d))
2218

2319
sphere = ParametricSurface(
2420
lambda u, v: np.array([
2521
2*np.sin(u)*np.cos(v),
2622
2*np.sin(u)*np.sin(v),
2723
2*np.cos(u)
28-
]),u_min=0,u_max=PI,v_min=0,v_max=2*PI,checkerboard_colors=[RED_D, RED_E],
24+
]),u_min=0,u_max=PI/2,v_min=0,v_max=2*PI,checkerboard_colors=[RED_D, RED_E],
2925
resolution=(15, 32)).scale(1)
3026

3127

@@ -53,89 +49,77 @@ def construct(self):
5349

5450
dot_x_y1 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([-1,1,0]))
5551
dot_x_y_z1 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([-1,1,1.414]))
56-
dot_x_y_z_1 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([-1,1,-1.414]))
57-
line1 = DashedLine(np.array([-1,1,-1.414]), np.array([-1,1,1.414]), color = YELLOW_C)
52+
53+
line1 = DashedLine(np.array([-1,1,0]), np.array([-1,1,1.414]), color = YELLOW_C)
5854

5955
point_x_y1 = TexMobject("(-1,1,0)").set_color(BLUE_C).move_to(np.array([-1.5,1.5,0])).scale(0.5)
6056
point_x_y_z1 = TexMobject("(-1,1,\\sqrt{r^2 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,1.414])).scale(0.5)
6157
point_x_y_z1_2 = TexMobject("(-1,1,\\sqrt{4 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,1.414])).scale(0.5)
6258
point_x_y_z1_3 = TexMobject("(-1,1,\\sqrt{4 - 1 - 1})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,1.414])).scale(0.5)
6359
point_x_y_z1_4 = TexMobject("(-1,1,\\sqrt{2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,1.414])).scale(0.5)
6460
point_x_y_z1_5 = TexMobject("(-1,1,1.414)").set_color(BLUE_C).move_to(np.array([-1.5,1.5,1.414])).scale(0.5)
65-
66-
point_x_y_z_1 = TexMobject("(-1,1,\\sqrt{r^2 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,-1.414])).scale(0.5)
67-
point_x_y_z_1_2 = TexMobject("(-1,1,\\sqrt{4 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,-1.414])).scale(0.5)
68-
point_x_y_z_1_3 = TexMobject("(-1,1,\\sqrt{4 - 1 - 1})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,-1.414])).scale(0.5)
69-
point_x_y_z_1_4 = TexMobject("(-1,1,\\sqrt{2})").set_color(BLUE_C).move_to(np.array([-1.5,1.5,-1.414])).scale(0.5)
70-
point_x_y_z_1_5 = TexMobject("(-1,1,-1.414)").set_color(BLUE_C).move_to(np.array([-1.5,1.5,-1.414])).scale(0.5)
71-
61+
7262

7363
self.play(ShowCreation(dot_x_y1))
7464
self.add_fixed_orientation_mobjects(point_x_y1)
75-
self.play(ShowCreation(dot_x_y_z1), ShowCreation(dot_x_y_z_1), ShowCreation(line1))
76-
self.add_fixed_orientation_mobjects(point_x_y_z1, point_x_y_z_1)
65+
self.play(ShowCreation(dot_x_y_z1), ShowCreation(line1))
66+
self.add_fixed_orientation_mobjects(point_x_y_z1)
7767
self.wait(0.5)
78-
self.play(ReplacementTransform(point_x_y_z1,point_x_y_z1_2), ReplacementTransform(point_x_y_z_1,point_x_y_z_1_2))
79-
self.add_fixed_orientation_mobjects(point_x_y_z1_2, point_x_y_z_1_2)
68+
self.play(ReplacementTransform(point_x_y_z1,point_x_y_z1_2))
69+
self.add_fixed_orientation_mobjects(point_x_y_z1_2)
8070

8171
self.wait(0.5)
82-
self.play(ReplacementTransform(point_x_y_z1_2,point_x_y_z1_3), ReplacementTransform(point_x_y_z_1_2,point_x_y_z_1_3))
83-
self.add_fixed_orientation_mobjects(point_x_y_z1_3, point_x_y_z_1_3)
72+
self.play(ReplacementTransform(point_x_y_z1_2,point_x_y_z1_3))
73+
self.add_fixed_orientation_mobjects(point_x_y_z1_3)
8474
self.wait(0.5)
85-
self.play(ReplacementTransform(point_x_y_z1_3,point_x_y_z1_4), ReplacementTransform(point_x_y_z_1_3,point_x_y_z_1_4))
86-
self.add_fixed_orientation_mobjects(point_x_y_z1_4, point_x_y_z_1_4)
75+
self.play(ReplacementTransform(point_x_y_z1_3,point_x_y_z1_4))
76+
self.add_fixed_orientation_mobjects(point_x_y_z1_4)
8777
self.wait(0.5)
88-
self.play(ReplacementTransform(point_x_y_z1_4,point_x_y_z1_5), ReplacementTransform(point_x_y_z_1_4,point_x_y_z_1_5))
89-
self.add_fixed_orientation_mobjects(point_x_y_z1_5, point_x_y_z_1_5)
78+
self.play(ReplacementTransform(point_x_y_z1_4,point_x_y_z1_5))
79+
self.add_fixed_orientation_mobjects(point_x_y_z1_5)
9080

9181

9282

9383
dot_x_y2 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([0.5,-0.5,0]))
9484
dot_x_y_z2 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([0.5,-0.5,1.87]))
95-
dot_x_y_z_2 = Dot().scale(0.75).set_fill(RED_C).move_to(np.array([0.5,-0.5,-1.87]))
96-
line2 = DashedLine(np.array([0.5,-0.5,-1.87]), np.array([0.5,-0.5,1.87]), color = YELLOW_C)
85+
86+
line2 = DashedLine(np.array([0.5,-0.5,0]), np.array([0.5,-0.5,1.87]), color = YELLOW_C)
9787

9888
point_x_y2 = TexMobject("(0.5,-0.5,0)").set_color(BLUE_C).move_to(np.array([1.5,-1.5,0])).scale(0.5)
9989
point_x_y_z2 = TexMobject("(0.5,-0.5,\\sqrt{r^2 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,1.87])).scale(0.5)
10090
point_x_y_z2_2 = TexMobject("(0.5,-0.5,\\sqrt{4 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,1.87])).scale(0.5)
10191
point_x_y_z2_3 = TexMobject("(0.5,-0.5,\\sqrt{4 - 0.25 - 0.25})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,1.87])).scale(0.5)
10292
point_x_y_z2_4 = TexMobject("(0.5,-0.5,\\sqrt{3.5})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,1.87])).scale(0.5)
10393
point_x_y_z2_5 = TexMobject("(0.5,-0.5,1.87)").set_color(BLUE_C).move_to(np.array([1.5,-1.5,1.87])).scale(0.5)
104-
105-
point_x_y_z_2 = TexMobject("(0.5,-0.5,\\sqrt{r^2 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,-1.87])).scale(0.5)
106-
point_x_y_z_2_2 = TexMobject("(0.5,-0.5,\\sqrt{4 - x^2 - y^2})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,-1.87])).scale(0.5)
107-
point_x_y_z_2_3 = TexMobject("(0.5,-0.5,\\sqrt{4 - 0.25 - 0.25})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,-1.87])).scale(0.5)
108-
point_x_y_z_2_4 = TexMobject("(0.5,-0.5,\\sqrt{3.5})").set_color(BLUE_C).move_to(np.array([1.5,-1.5,-1.87])).scale(0.5)
109-
point_x_y_z_2_5 = TexMobject("(0.5,-0.5,-1.87)").set_color(BLUE_C).move_to(np.array([1.5,-1.5,-1.87])).scale(0.5)
110-
94+
11195

11296
self.play(ShowCreation(dot_x_y2))
11397
self.add_fixed_orientation_mobjects(point_x_y2)
114-
self.play(ShowCreation(dot_x_y_z2), ShowCreation(dot_x_y_z_2), ShowCreation(line2))
115-
self.add_fixed_orientation_mobjects(point_x_y_z2, point_x_y_z_2)
98+
self.play(ShowCreation(dot_x_y_z2), ShowCreation(line2))
99+
self.add_fixed_orientation_mobjects(point_x_y_z2)
116100
self.wait(0.5)
117-
self.play(ReplacementTransform(point_x_y_z2,point_x_y_z2_2), ReplacementTransform(point_x_y_z_2,point_x_y_z_2_2))
118-
self.add_fixed_orientation_mobjects(point_x_y_z2_2, point_x_y_z_2_2)
101+
self.play(ReplacementTransform(point_x_y_z2,point_x_y_z2_2))
102+
self.add_fixed_orientation_mobjects(point_x_y_z2_2)
119103

120104
self.wait(0.5)
121-
self.play(ReplacementTransform(point_x_y_z2_2,point_x_y_z2_3), ReplacementTransform(point_x_y_z_2_2,point_x_y_z_2_3))
122-
self.add_fixed_orientation_mobjects(point_x_y_z2_3, point_x_y_z_2_3)
105+
self.play(ReplacementTransform(point_x_y_z2_2,point_x_y_z2_3))
106+
self.add_fixed_orientation_mobjects(point_x_y_z2_3)
123107
self.wait(0.5)
124-
self.play(ReplacementTransform(point_x_y_z2_3,point_x_y_z2_4), ReplacementTransform(point_x_y_z_2_3,point_x_y_z_2_4))
125-
self.add_fixed_orientation_mobjects(point_x_y_z2_4, point_x_y_z_2_4)
108+
self.play(ReplacementTransform(point_x_y_z2_3,point_x_y_z2_4))
109+
self.add_fixed_orientation_mobjects(point_x_y_z2_4)
126110
self.wait(0.5)
127-
self.play(ReplacementTransform(point_x_y_z2_4,point_x_y_z2_5), ReplacementTransform(point_x_y_z_2_4,point_x_y_z_2_5))
128-
self.add_fixed_orientation_mobjects(point_x_y_z2_5, point_x_y_z_2_5)
111+
self.play(ReplacementTransform(point_x_y_z2_4,point_x_y_z2_5))
112+
self.add_fixed_orientation_mobjects(point_x_y_z2_5)
129113

130-
self.play(FadeOut(point_x_y1), FadeOut(point_x_y_z1_5), FadeOut(point_x_y_z_1_5), FadeOut(dot_x_y1), FadeOut(dot_x_y_z1), FadeOut(dot_x_y_z_1), FadeOut(line1))
131-
self.play(FadeOut(point_x_y2), FadeOut(point_x_y_z2_5), FadeOut(point_x_y_z_2_5), FadeOut(dot_x_y2), FadeOut(dot_x_y_z2), FadeOut(dot_x_y_z_2), FadeOut(line2))
114+
self.play(FadeOut(point_x_y1), FadeOut(point_x_y_z1_5))
115+
self.play(FadeOut(point_x_y2), FadeOut(point_x_y_z2_5))
132116

133117

134118

135119

136120
sphere_final = []
137121

138-
for u in range(0, 180, 15):
122+
for u in range(0, 90, 15):
139123
sphere_points1 = [np.array([2*np.sin(u*DEGREES)*np.cos(v*DEGREES), 2*np.sin(u*DEGREES)*np.sin(v*DEGREES), 2*np.cos(u*DEGREES)]) for v in range(0, 370, 10)]
140124
sphere_dots1 = [Dot().scale(0.75).set_fill(RED_C).move_to(pts) for pts in sphere_points1]
141125

@@ -158,20 +142,4 @@ def construct(self):
158142
self.begin_ambient_camera_rotation(rate=0.5)
159143
self.wait(3)
160144
self.play(ReplacementTransform(sphere_final_with_dots, sphere))
161-
self.wait(5)
162-
163-
164-
165-
166-
167-
168-
169-
170-
171-
172-
173-
174-
175-
176-
177-
145+
self.wait(5)

0 commit comments

Comments
 (0)