summaryrefslogtreecommitdiff
path: root/FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py
diff options
context:
space:
mode:
authorPurusharth Saxena2020-06-23 18:06:56 +0530
committerGitHub2020-06-23 18:06:56 +0530
commitd0c1b826b41a0a0f93079b6ca755f2cef132ce6e (patch)
tree6c851e4ea4e369c536bb183aa9378926b78dcee6 /FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py
parenta896e8b74b1b4864f24d860ea82e4de46d2ff2c7 (diff)
parent959329ed76fb5350f5f68aeb8937a37b62138890 (diff)
downloadFSF-mathematics-python-code-archive-d0c1b826b41a0a0f93079b6ca755f2cef132ce6e.tar.gz
FSF-mathematics-python-code-archive-d0c1b826b41a0a0f93079b6ca755f2cef132ce6e.tar.bz2
FSF-mathematics-python-code-archive-d0c1b826b41a0a0f93079b6ca755f2cef132ce6e.zip
Merge branch 'master' into master
Diffstat (limited to 'FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py')
-rw-r--r--FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py b/FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py
new file mode 100644
index 0000000..633e500
--- /dev/null
+++ b/FSF-2020/calculus-of-several-variables/geometry-of-planes-and-curves/general-parametric-curves/file3_brachistochrone.py
@@ -0,0 +1,13 @@
+from manimlib.imports import *
+
+class brachistochrone(Scene):
+ def construct(self):
+ curve = ParametricFunction(
+ lambda t: np.array([
+ 0.5*(t - np.sin(t)),
+ 0.5*(1 - np.cos(t)),
+ 0
+ ]), t_max = np.pi
+ ).scale(5).rotate(540*DEGREES)
+ dot = Dot(color = RED, radius = 0.2)
+ self.play(FadeIn(curve), MoveAlongPath(dot, curve, run_time = 2))