diff options
Diffstat (limited to 'FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity')
11 files changed, 627 insertions, 0 deletions
diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/Limits_and_Continuity_of_Multivariable_Function_Quiz.pdf b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/Limits_and_Continuity_of_Multivariable_Function_Quiz.pdf Binary files differnew file mode 100644 index 0000000..99918e5 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/Limits_and_Continuity_of_Multivariable_Function_Quiz.pdf diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file1_epsilon_delta_defn.py b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file1_epsilon_delta_defn.py new file mode 100644 index 0000000..803c122 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file1_epsilon_delta_defn.py @@ -0,0 +1,179 @@ +from manimlib.imports import *
+
+class EpsilonDelta(ThreeDScene):
+ def construct(self):
+ axes = ThreeDAxes() # creates a 3D Axis
+
+
+ sphere = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ 3*np.cos(u)
+ ]),u_min=0,u_max=PI/4,v_min=PI/2,v_max=PI,checkerboard_colors=[RED_D, RED_E],
+ resolution=(15, 32)).scale(1)
+
+
+ cylinder_z = ParametricSurface(
+ lambda u, v: np.array([
+ 0.25*np.cos(TAU * v),
+ 1.8* (1 - u),
+ 0.25*np.sin(TAU * v)
+
+ ]),
+ checkerboard_colors=[YELLOW_C, YELLOW_E], resolution=(6, 32)).fade(0.2).rotate(PI/4).move_to(np.array([-0.65,0.65,2.54]))
+
+
+ cylinder_x = ParametricSurface(
+ lambda u, v: np.array([
+ 0.3*np.cos(TAU * v)-1,
+ 0.3*np.sin(TAU * v)+1,
+ 2.6*(1 - u)
+ ]),
+ checkerboard_colors=[BLUE_C, BLUE_E], resolution=(6, 32)).fade(0.2)
+
+
+ delta_circle = Circle(radius= 0.3, color = BLACK).shift(1*LEFT+1*UP).set_fill(GREEN_E, opacity = 0.5)
+
+ epsilon_circle = [np.array([0.25*np.cos(i*DEGREES),0,0.25*np.sin(i*DEGREES)]) for i in range(361)]
+
+ epsilon_circle_polygon = Polygon(*epsilon_circle, color = RED_E, fill_color = RED_E, fill_opacity = 0.5).rotate(PI/4).move_to(np.array([0,0,2.54]))
+
+
+ dot_circle = Dot().move_to(np.array([-1,1,0])).set_fill("#000080")
+
+ dot_surface = Dot().rotate(-PI/4).scale(1.5).move_to(np.array([-1.2,1.2,2.7])).set_fill("#000080")
+
+ dot_L_epsilon1 = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).rotate(PI/4).move_to(np.array([0,0,2.3]))
+
+ dot_L_epsilon2 = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).rotate(PI/4).move_to(np.array([0,0,2.8]))
+
+ dot_L = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#006400", fill_color = "#006400", fill_opacity = 1).rotate(PI/4).move_to(np.array([0,0,2.54]))
+
+
+
+ self.add(axes)
+
+ axis = TextMobject(r"X",r"Y",r"Z")
+ axis[0].move_to(6*RIGHT)
+ axis[1].move_to(6*UP)
+ axis[2].move_to(np.array([0,0,3.7]))
+
+ self.add_fixed_orientation_mobjects(axis[2])
+ self.add_fixed_orientation_mobjects(axis[0])
+ self.add_fixed_orientation_mobjects(axis[1])
+
+ self.set_camera_orientation(phi=75*DEGREES,theta=135*DEGREES)
+ #self.set_camera_orientation(phi=80*DEGREES,theta=45*DEGREES)
+
+
+ self.play(ShowCreation(sphere),ShowCreation(delta_circle), ShowCreation(dot_circle))
+
+ temp_circle_center = TextMobject(r"$(a,b,0)$").scale(0.6).set_color(BLUE_C).move_to(1.7*LEFT+1.1*UP)
+ self.add_fixed_orientation_mobjects(temp_circle_center)
+ self.wait()
+
+ delta_lab = TextMobject(r"$\delta$", r"$-$", "disk").scale(0.5).move_to(0.6*LEFT+1.7*UP)
+ delta_lab[0].set_color(PINK).scale(1.3)
+ delta_lab[1].set_color(ORANGE)
+ delta_lab[2].set_color(GREEN_E)
+
+ self.add_fixed_orientation_mobjects(delta_lab)
+
+ self.play(ShowCreation(dot_surface))
+
+ temp_curve_circle_center = TextMobject(r"$(a,b,L)$").scale(0.6).set_color("#006400").move_to(np.array([-2,1,2.7]))
+ self.add_fixed_orientation_mobjects(temp_curve_circle_center)
+
+
+ self.wait()
+ self.play(ShowCreation(cylinder_x), FadeOut(dot_surface))
+ self.wait()
+
+ self.move_camera(phi=0* DEGREES,theta=135*DEGREES)
+ self.wait()
+
+ self.move_camera(phi=80* DEGREES,theta=225*DEGREES)
+ self.wait()
+
+ self.play(FadeOut(delta_lab), ShowCreation(cylinder_z))
+ self.wait()
+
+ self.play(FadeOut(temp_circle_center), FadeOut(temp_curve_circle_center),ShowCreation(epsilon_circle_polygon))
+
+ self.move_camera(phi=80* DEGREES,theta=325*DEGREES)
+
+ dot_L_epsilon1_lab = TextMobject(r"$L$", r"$-$", r"$\epsilon$").scale(0.6).move_to(np.array([-0.4,-0.4,2.3]))
+ dot_L_epsilon1_lab[0].set_color("#D4108A")
+ dot_L_epsilon1_lab[1].set_color("#006400")
+ dot_L_epsilon1_lab[2].set_color("#4DC8A1").scale(1.5)
+
+ dot_L_epsilon2_lab = TextMobject(r"$L$", r"$+$", r"$\epsilon$").scale(0.6).move_to(np.array([-0.4,-0.4,2.8]))
+ dot_L_epsilon2_lab[0].set_color("#D4108A")
+ dot_L_epsilon2_lab[1].set_color("#006400")
+ dot_L_epsilon2_lab[2].set_color("#4DC8A1").scale(1.5)
+
+ dot_L_lab = TextMobject(r"$L$").scale(0.6).set_color("#D4108A").move_to(np.array([-0.4,-0.4,2.54]))
+
+
+ self.play(ShowCreation(dot_L_epsilon1), ShowCreation(dot_L), ShowCreation(dot_L_epsilon2))
+ self.add_fixed_orientation_mobjects(dot_L_epsilon1_lab, dot_L_epsilon2_lab, dot_L_lab)
+ self.wait(4)
+
+ self.move_camera(phi=80* DEGREES,theta=45*DEGREES)
+ self.wait(2)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ '''
+
+
+
+
+
+
+
+
+
+
+
+ delta_lab = TextMobject(r"$\delta - disk$")
+ delta_lab.scale(0.5)
+ delta_lab.set_color(PINK)
+
+ self.play(ShowCreation(circle_center))
+ self.add_fixed_in_frame_mobjects(temp_circle_center)
+ temp_circle_center.move_to(1.5*RIGHT)
+ self.play(Write(temp_circle_center))
+
+ self.play(ShowCreation(curve_circle_center))
+ self.add_fixed_in_frame_mobjects(temp_curve_circle_center)
+ temp_curve_circle_center.move_to(1.9*UP+1*RIGHT)
+ self.play(Write(temp_curve_circle_center))
+
+
+ self.add_fixed_in_frame_mobjects(delta_lab)
+ delta_lab.move_to(0.4*DOWN+1.7*RIGHT)
+ self.play(Write(delta_lab))
+
+
+
+
+
+ self.begin_ambient_camera_rotation(rate=0.2)
+
+ self.play(ShowCreation(circle), ShowCreation(line1), ShowCreation(line2))
+ self.play(ShowCreation(line3), ShowCreation(line4))
+ self.wait(8)
+ '''
\ No newline at end of file diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file2_limit_approach_point.py b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file2_limit_approach_point.py new file mode 100644 index 0000000..57d1d45 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file2_limit_approach_point.py @@ -0,0 +1,66 @@ +from manimlib.imports import *
+
+class Limit(GraphScene):
+ CONFIG = {
+ "x_min": 0,
+ "x_max": 4,
+ "y_min": 0,
+ "y_max": 4,
+ "graph_origin": ORIGIN + 3* DOWN+4*LEFT,
+ "x_labeled_nums": list(range(0, 4)),
+ "y_labeled_nums": list(range(0, 5)),
+ }
+ def construct(self):
+ topic = TextMobject("Different paths of approach to limit point")
+ topic.scale(1.5)
+ topic.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
+ self.play(Write(topic))
+ self.wait(1)
+ self.play(FadeOut(topic))
+
+
+
+ XTD = self.x_axis_width/(self.x_max- self.x_min)
+ YTD = self.y_axis_height/(self.y_max- self.y_min)
+
+ self.setup_axes(animate = True)
+
+ y_x = self.get_graph(lambda x : x, x_min = -1, x_max = 4)
+ y_x_lab = self.get_graph_label(y_x, label = r"y = x")
+
+ y_xsquare = self.get_graph(lambda x : x*x, x_min = -1, x_max = 4)
+ y_xsquare_lab = self.get_graph_label(y_xsquare, label = r"y = x^2")
+
+ y_1 = self.get_graph(lambda x : 1, x_min = -1, x_max = 4)
+ y_1_lab = self.get_graph_label(y_1, label = r"y = 1")
+
+ y_2minusx = self.get_graph(lambda x : 2 - x, x_min = -1, x_max = 4, color = RED)
+ y_2minusx_lab = self.get_graph_label(y_2minusx, label = r"y = 2 - x")
+
+ limit_point = Dot().shift(self.graph_origin+1*XTD*RIGHT+1*YTD*UP)
+ limit_point_lab = TextMobject(r"(1,1)")
+ limit_point_lab.next_to(limit_point, DOWN)
+
+ self.play(ShowCreation(limit_point))
+ self.play(Write(limit_point_lab))
+ self.wait(1)
+
+ self.play(ShowCreation(y_x))
+ self.play(Write(y_x_lab))
+ self.wait(1)
+
+ self.play(ShowCreation(y_xsquare))
+ self.play(Write(y_xsquare_lab))
+ self.wait(1)
+
+ self.play(ShowCreation(y_1))
+ self.play(Write(y_1_lab))
+ self.wait(1)
+
+ self.play(ShowCreation(y_2minusx))
+ self.play(Write(y_2minusx_lab))
+ self.wait(1)
+
+
+
+
\ No newline at end of file diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file3_limit_approach_point_3d.py b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file3_limit_approach_point_3d.py new file mode 100644 index 0000000..f1007a4 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file3_limit_approach_point_3d.py @@ -0,0 +1,152 @@ +from manimlib.imports import *
+
+class Limit(ThreeDScene):
+ def construct(self):
+ axes = ThreeDAxes()
+
+ text3d = TextMobject(r"$f(x,y) = \frac{x - y}{x - 1}$")
+ self.add_fixed_in_frame_mobjects(text3d)
+
+ text3d.to_corner(UL)
+
+ text3d.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
+
+ self.play(Write(text3d))
+ self.wait(1)
+
+ limit_func = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ (3*np.sin(u)*np.cos(v) - 3*np.sin(u)*np.sin(v))/2*(3*np.sin(u)*np.cos(v) - 1)
+ ]),u_min=0,u_max=PI,v_min=0,v_max=2*PI, color = BLUE_C, fill_color = BLUE_C, fill_opacity = 0.1,
+ resolution=(15, 32)).scale(1)
+
+ limit_y_x =ParametricFunction(
+ lambda u : np.array([
+ u,
+ u,
+ 0
+ ]),color=GREEN_D,t_min=-3,t_max=3,
+ )
+
+ limit_y_1 =ParametricFunction(
+ lambda u : np.array([
+ u,
+ 1,
+ 1/2
+ ]),color=BLUE_D,t_min=-3,t_max=3,
+ )
+
+ limit_y_x_2 =ParametricFunction(
+ lambda u : np.array([
+ u,
+ u*u,
+ (u - u*u)/2*(u - 1)
+ ]),color=RED_D,t_min=-3,t_max=3,
+ )
+
+ limit_y_2_x =ParametricFunction(
+ lambda u : np.array([
+ u,
+ 2 - u,
+ 1
+ ]),color=YELLOW_D,t_min=-3,t_max=3,
+ )
+
+ plane_y_x = Polygon(np.array([-3,-3,-3]),np.array([3,3,-3]),np.array([3,3,3]),np.array([-3,-3,3]),np.array([-3,-3,-3]), color = GREEN_C, fill_color = GREEN_C, fill_opacity = 0.1)
+ plane_y_x_text = TextMobject(r"$y = x$", color = GREEN_C).move_to(np.array([5,0,3]))
+
+ plane_y_1 = Polygon(np.array([-3,1,-3]),np.array([3,1,-3]),np.array([3,1,3]),np.array([-3,1,3]),np.array([-3,1,-3]), color = BLUE_C, fill_color = BLUE_C, fill_opacity = 0.1)
+ plane_y_1_text = TextMobject(r"$y = 1$", color = BLUE_C).move_to(np.array([5,0,2.5]))
+
+
+ #Creating plane y = x^2
+ ######
+ y_x_2 = []
+ y_x_2.append(np.array([2, 4, -3]))
+ y_x_2.append(np.array([2, 4, 3]))
+ y_x_2_1 = [np.array([i, i*i, 3]) for i in np.arange(1.9,-2.1, -0.1)]
+
+ y_x_2 = y_x_2 + y_x_2_1
+
+ y_x_2.append(np.array([-2, 4, 3]))
+ y_x_2.append(np.array([-2, 4, -3]))
+
+ y_x_2_2 = [np.array([i, i*i, -3]) for i in np.arange(-2,2.1, 0.1)]
+
+ y_x_2 = y_x_2 + y_x_2_2
+ #y_x_2.append(np.array([-3, 9, 0]))
+
+ plane_y_x_2 = Polygon(*y_x_2, color = RED_C, fill_color = RED_C, fill_opacity = 0.1)
+ plane_y_x_2_text = TextMobject(r"$y = x^2$", color = RED_C).move_to(np.array([5,0,2]))
+
+ ######
+
+ plane_y_2_x = Polygon(np.array([-3,5,-3]),np.array([3,-1,-3]),np.array([3,-1,3]),np.array([-3,5,3]),np.array([-3,5,-3]), color = YELLOW_C, fill_color = YELLOW_C, fill_opacity = 0.1)
+ plane_y_2_x_text = TextMobject(r"$y = 2 - x$", color = YELLOW_C).move_to(np.array([5,0,1.5]))
+
+ line_1_1 = Line(np.array([1,1,-3]), np.array([1,1,3]), color = PINK)
+
+ point = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).move_to(np.array([1,1,0]))
+ point_text = TextMobject(r"$(1,1,0)$", color = WHITE).scale(0.7).move_to(np.array([1.8,1,0]))
+
+
+
+
+ self.set_camera_orientation(phi=70 * DEGREES, theta = -95*DEGREES)
+
+
+ self.add(axes)
+
+ axis = TextMobject(r"X",r"Y",r"Z")
+ axis[0].move_to(6*RIGHT)
+ axis[1].move_to(6*UP)
+ axis[2].move_to(3.7*UP)
+
+ self.add_fixed_in_frame_mobjects(axis[2])
+ self.add_fixed_orientation_mobjects(axis[0])
+ self.add_fixed_orientation_mobjects(axis[1])
+
+ self.play(ShowCreation(limit_func))
+ self.wait(2)
+
+ self.play(ShowCreation(plane_y_x))
+ self.add_fixed_orientation_mobjects(plane_y_x_text)
+ self.play(ShowCreation(limit_y_x))
+ self.wait()
+
+ self.play(ShowCreation(plane_y_1))
+ self.add_fixed_orientation_mobjects(plane_y_1_text)
+ self.play(ShowCreation(limit_y_1))
+ self.wait()
+
+ self.play(ShowCreation(plane_y_x_2))
+ self.add_fixed_orientation_mobjects(plane_y_x_2_text)
+ self.play(ShowCreation(limit_y_x_2))
+ self.wait()
+
+ self.play(ShowCreation(plane_y_2_x))
+ self.add_fixed_orientation_mobjects(plane_y_2_x_text)
+ self.play(ShowCreation(limit_y_2_x))
+ self.wait()
+
+ self.play(ShowCreation(line_1_1))
+ self.wait()
+
+ self.play(ShowCreation(point))
+ self.add_fixed_orientation_mobjects(point_text)
+ self.wait()
+
+ self.play(FadeOut(plane_y_x_text), FadeOut(plane_y_1_text), FadeOut(plane_y_x_2_text), FadeOut(plane_y_2_x_text))
+
+ self.move_camera(phi=0* DEGREES,theta=-95*DEGREES)
+ self.wait(2)
+ self.play(FadeOut(plane_y_x), FadeOut(plane_y_1), FadeOut(plane_y_x_2), FadeOut(plane_y_2_x))
+ self.wait(3)
+
+ self.move_camera(phi=75* DEGREES,theta=-95*DEGREES)
+ self.wait(3)
+
+
+
\ No newline at end of file diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file4_limit_different_point.py b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file4_limit_different_point.py new file mode 100644 index 0000000..0a43def --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file4_limit_different_point.py @@ -0,0 +1,115 @@ +from manimlib.imports import *
+
+class DifferentPoint(ThreeDScene):
+ def construct(self):
+ axes = ThreeDAxes()
+
+ text3d = TextMobject(r"$f(x,y) = \frac{x^2 - y^2}{x^2 + y^2}$")
+ self.add_fixed_in_frame_mobjects(text3d)
+
+ text3d.to_corner(UL)
+
+ text3d.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
+
+ self.play(Write(text3d))
+ self.wait(1)
+
+ limit_func = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ (np.cos(v)*np.cos(v) - np.sin(v)*np.sin(v))
+ ]),u_min=0,u_max=PI,v_min=0,v_max=2*PI,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ limit_func_copy1 = limit_func.copy()
+ limit_func_copy2 = limit_func.copy()
+
+ limit_func_x = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ (np.cos(v)*np.cos(v) - np.sin(v)*np.sin(v))
+ ]),u_min=0,u_max=PI,v_min=PI,v_max=2*PI,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ limit_func_y = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ (np.cos(v)*np.cos(v) - np.sin(v)*np.sin(v))
+ ]),u_min=0,u_max=PI,v_min=PI/2,v_max=3*PI/2,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ limit_x =ParametricFunction(
+ lambda u : np.array([
+ u,
+ 0,
+ 1
+ ]),color="#006400",t_min=-3,t_max=3,
+ )
+
+ limit_y =ParametricFunction(
+ lambda u : np.array([
+ 0,
+ u,
+ -1
+ ]),color="#000080",t_min=-3,t_max=3,
+ )
+
+ plane_x = Polygon(np.array([-3,0,-2]),np.array([3,0,-2]),np.array([3,0,2]),np.array([-3,0,2]),np.array([-3,0,-2]), color = GREEN, fill_color = GREEN, fill_opacity = 0.2)
+ plane_x_text = TextMobject(r"$y = 0$", color = GREEN_C).move_to(1.7*UP + 3.8*RIGHT)
+
+ plane_y = Polygon(np.array([0,-3,-2]),np.array([0,3,-2]),np.array([0,3,2]),np.array([0,-3,2]),np.array([0,-3,-2]), color = BLUE, fill_color = BLUE, fill_opacity = 0.2)
+ plane_y_text = TextMobject(r"$x = 0$", color = BLUE_C).move_to(1.7*UP + 3.8*RIGHT)
+
+ origin_x = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).move_to(np.array([0,0,0]))
+ origin_x_text = TextMobject(r"$(0,0,0)$", color = RED_C).scale(0.7).move_to(np.array([-0.6,0,-0.5]))
+
+ origin_y = Polygon(*[np.array([0,0.05*np.cos(i*DEGREES),0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).move_to(np.array([0,0,0]))
+ origin_y_text = TextMobject(r"$(0,0,0)$", color = RED_C).scale(0.7).move_to(np.array([0,-0.6,-0.5]))
+
+ self.set_camera_orientation(phi=80 * DEGREES, theta = 0*DEGREES)
+
+
+ self.add(axes)
+
+ axis = TextMobject(r"X",r"Y",r"Z")
+ axis[0].move_to(6*RIGHT)
+ axis[1].move_to(6*UP)
+ axis[2].move_to(3.7*UP)
+
+ self.add_fixed_in_frame_mobjects(axis[2])
+ self.add_fixed_orientation_mobjects(axis[0])
+ self.add_fixed_orientation_mobjects(axis[1])
+
+ self.play(ShowCreation(limit_func))
+
+ self.move_camera(phi=80* DEGREES,theta=105*DEGREES)
+
+ self.play(ShowCreation(plane_x))
+ self.add_fixed_in_frame_mobjects(plane_x_text)
+ self.wait()
+ self.play(ReplacementTransform(limit_func, limit_func_x))
+ self.play(FadeOut(plane_x), FadeOut(plane_x_text), ShowCreation(origin_x))
+ self.add_fixed_orientation_mobjects(origin_x_text)
+ self.play(ShowCreation(limit_x))
+
+ self.move_camera(phi=80* DEGREES,theta=15*DEGREES)
+ self.wait(3)
+
+ self.play(FadeOut(origin_x), FadeOut(origin_x_text), FadeOut(limit_x), ReplacementTransform(limit_func_x, limit_func_copy1))
+ self.play(ShowCreation(plane_y))
+ self.add_fixed_in_frame_mobjects(plane_y_text)
+ self.wait()
+ self.play(ReplacementTransform(limit_func_copy1, limit_func_y))
+ self.play(FadeOut(plane_y), FadeOut(plane_y_text), ShowCreation(origin_y))
+ self.add_fixed_orientation_mobjects(origin_y_text)
+ self.play(ShowCreation(limit_y))
+
+ self.move_camera(phi=80* DEGREES,theta=75*DEGREES)
+ self.wait(3)
+
+ self.play(FadeOut(origin_y), FadeOut(origin_y_text), FadeOut(limit_y), ReplacementTransform(limit_func_y, limit_func_copy2))
+ self.wait(2)
+
\ No newline at end of file diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file5_continuity_func.py b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file5_continuity_func.py new file mode 100644 index 0000000..99159a4 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/file5_continuity_func.py @@ -0,0 +1,115 @@ +from manimlib.imports import *
+
+class Continuity(ThreeDScene):
+ def construct(self):
+ axes = ThreeDAxes()
+
+ text3d = TextMobject(r"$f(x,y) = \frac{3x^2y}{x^2 + y^2}$")
+ self.add_fixed_in_frame_mobjects(text3d)
+
+ text3d.to_corner(UL)
+
+ text3d.set_color_by_gradient(RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE)
+
+ self.play(Write(text3d))
+ self.wait(1)
+
+
+ continuity_func = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ 9*np.sin(u)*np.cos(v)*np.cos(v)*np.sin(v)
+ ]),u_min=0,u_max=PI,v_min=0,v_max=2*PI,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ continuity_func_copy1 = continuity_func.copy()
+ continuity_func_copy2 = continuity_func.copy()
+
+ continuity_func_x = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ 9*np.sin(u)*np.cos(v)*np.cos(v)*np.sin(v)
+ ]),u_min=0,u_max=PI,v_min=PI,v_max=2*PI,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ continuity_func_y = ParametricSurface(
+ lambda u, v: np.array([
+ 3*np.sin(u)*np.cos(v),
+ 3*np.sin(u)*np.sin(v),
+ 9*np.sin(u)*np.cos(v)*np.cos(v)*np.sin(v)
+ ]),u_min=0,u_max=PI,v_min=PI/2,v_max=3*PI/2,checkerboard_colors=[YELLOW_C, YELLOW_E],
+ resolution=(15, 32)).scale(1)
+
+ continuity_x =ParametricFunction(
+ lambda u : np.array([
+ u,
+ 0,
+ 0
+ ]),color="#006400",t_min=-3,t_max=3,
+ )
+
+ continuity_y =ParametricFunction(
+ lambda u : np.array([
+ 0,
+ u,
+ 0
+ ]),color="#000080",t_min=-3,t_max=3,
+ )
+
+ plane_x = Polygon(np.array([-3,0,-3]),np.array([3,0,-3]),np.array([3,0,3]),np.array([-3,0,3]),np.array([-3,0,-3]), color = GREEN, fill_color = GREEN, fill_opacity = 0.2)
+ plane_x_text = TextMobject(r"$y = 0$", color = GREEN_C).move_to(1.7*UP + 3.8*RIGHT)
+
+ plane_y = Polygon(np.array([0,-3,-3]),np.array([0,3,-3]),np.array([0,3,3]),np.array([0,-3,3]),np.array([0,-3,-3]), color = BLUE, fill_color = BLUE, fill_opacity = 0.2)
+ plane_y_text = TextMobject(r"$x = 0$", color = BLUE_C).move_to(1.7*UP + 3.8*RIGHT)
+
+ origin_x = Polygon(*[np.array([0.05*np.cos(i*DEGREES),0,0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#000080", fill_color = "#000080", fill_opacity = 1).move_to(np.array([0,0,0]))
+ origin_x_text = TextMobject(r"$(0,0,0)$", color = RED_C).scale(0.7).move_to(np.array([-0.6,0,-0.5]))
+
+ origin_y = Polygon(*[np.array([0,0.05*np.cos(i*DEGREES),0.05*np.sin(i*DEGREES)]) for i in range(361)], color = "#006400", fill_color = "#006400", fill_opacity = 1).move_to(np.array([0,0,0]))
+ origin_y_text = TextMobject(r"$(0,0,0)$", color = RED_C).scale(0.7).move_to(np.array([0,-0.6,-0.5]))
+
+ self.set_camera_orientation(phi=80 * DEGREES, theta = 0*DEGREES)
+
+
+ self.add(axes)
+
+ axis = TextMobject(r"X",r"Y",r"Z")
+ axis[0].move_to(6*RIGHT)
+ axis[1].move_to(6*UP)
+ axis[2].move_to(3.7*UP)
+
+ self.add_fixed_in_frame_mobjects(axis[2])
+ self.add_fixed_orientation_mobjects(axis[0])
+ self.add_fixed_orientation_mobjects(axis[1])
+
+ self.play(ShowCreation(continuity_func))
+
+ self.move_camera(phi=80* DEGREES,theta=105*DEGREES)
+
+ self.play(ShowCreation(plane_x))
+ self.add_fixed_in_frame_mobjects(plane_x_text)
+ self.wait()
+ self.play(ReplacementTransform(continuity_func, continuity_func_x))
+ self.play(FadeOut(plane_x), FadeOut(plane_x_text))
+ self.play(ShowCreation(continuity_x), ShowCreation(origin_x))
+ self.add_fixed_orientation_mobjects(origin_x_text)
+
+ self.move_camera(phi=80* DEGREES,theta=15*DEGREES)
+ self.wait(3)
+
+ self.play(FadeOut(origin_x), FadeOut(origin_x_text), FadeOut(continuity_x), ReplacementTransform(continuity_func_x, continuity_func_copy1))
+ self.play(ShowCreation(plane_y))
+ self.add_fixed_in_frame_mobjects(plane_y_text)
+ self.wait()
+ self.play(ReplacementTransform(continuity_func_copy1, continuity_func_y))
+ self.play(FadeOut(plane_y), FadeOut(plane_y_text))
+ self.play(ShowCreation(continuity_y), ShowCreation(origin_y))
+ self.add_fixed_orientation_mobjects(origin_y_text)
+
+ self.move_camera(phi=80* DEGREES,theta=75*DEGREES)
+ self.wait(3)
+
+ self.play(FadeOut(origin_y), FadeOut(origin_y_text), FadeOut(continuity_y), ReplacementTransform(continuity_func_y, continuity_func_copy2))
+ self.wait(2)
\ No newline at end of file diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file1_epsilon_delta_defn.gif b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file1_epsilon_delta_defn.gif Binary files differnew file mode 100644 index 0000000..2378bcf --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file1_epsilon_delta_defn.gif diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file2_limit_approach_point.gif b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file2_limit_approach_point.gif Binary files differnew file mode 100644 index 0000000..830b6f1 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file2_limit_approach_point.gif diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file3_limit_approach_point_3d.gif b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file3_limit_approach_point_3d.gif Binary files differnew file mode 100644 index 0000000..4bccf8c --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file3_limit_approach_point_3d.gif diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file4_limit_different_point.gif b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file4_limit_different_point.gif Binary files differnew file mode 100644 index 0000000..9a831e4 --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file4_limit_different_point.gif diff --git a/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file5_continuity_func.gif b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file5_continuity_func.gif Binary files differnew file mode 100644 index 0000000..2a0a61f --- /dev/null +++ b/FSF-2020/calculus-of-several-variables/multivariable-functions-and-paritial-derivatives/multivariable-limits-and-continuity/gifs/file5_continuity_func.gif |