summaryrefslogtreecommitdiff
path: root/FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py
diff options
context:
space:
mode:
authorPurusharth Saxena2020-07-19 13:21:24 +0530
committerGitHub2020-07-19 13:21:24 +0530
commita15447d7f518153438894928f960329cc32b1053 (patch)
tree599fba92f6d348653b43c6bc664a7318b6589df3 /FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py
parentae98b8f71568711d01ae8d561c1d068f7ce329b5 (diff)
parenteadaf1b3e4245b4b5f3b932334400c0f3a0dcd22 (diff)
downloadFSF-mathematics-python-code-archive-a15447d7f518153438894928f960329cc32b1053.tar.gz
FSF-mathematics-python-code-archive-a15447d7f518153438894928f960329cc32b1053.tar.bz2
FSF-mathematics-python-code-archive-a15447d7f518153438894928f960329cc32b1053.zip
Merge pull request #72 from simranchhattani/master
Final changes
Diffstat (limited to 'FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py')
-rw-r--r--FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py29
1 files changed, 29 insertions, 0 deletions
diff --git a/FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py b/FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py
new file mode 100644
index 0000000..6edc918
--- /dev/null
+++ b/FSF-2020/linear-algebra/vector-spaces/Vector-Spaces/Dual-Spaces/Linear_Functional.py
@@ -0,0 +1,29 @@
+from manimlib.imports import *
+import numpy as np
+class LinearFunctional(Scene):
+ def construct(self):
+ big_box=Rectangle().scale(2.7)
+ box = Rectangle(height=2,width=2,color=DARK_GREY).set_fill(color=PURPLE,opacity=350)
+ arrow1 = Arrow(color=RED).shift(1.8*LEFT+0.5*UP)
+ arrow2 = Arrow(color=RED).shift(1.8*LEFT+0.5*DOWN)
+ arrow3 = Arrow(color=GREEN).shift(0.5*UP+1.8*RIGHT)
+ arrow4 = Arrow(color=GREEN).shift(0.5*DOWN+1.8*RIGHT)
+ Linear = TextMobject("LINEAR",color=BLACK).scale(0.5).shift(0.2*UP)
+ Functional = TextMobject("FUNCTIONAL",color=BLACK).scale(0.5).shift(0.2*DOWN)
+ u = TextMobject(r"$\vec{u}$",color=YELLOW).scale(0.7).shift(2.8*LEFT+0.5*UP)
+ v = TextMobject(r"$\vec{v}$",color=YELLOW).scale(0.7).shift(2.8*LEFT+0.5*DOWN)
+ f1 = TextMobject(r"$f_1$",color=YELLOW).scale(0.7).shift(2.8*RIGHT+0.5*UP)
+ f2 = TextMobject(r"$f_2$",color=YELLOW).scale(0.7).shift(2.8*RIGHT+0.5*DOWN)
+ text = TextMobject(r"The Linear Functional is a function that takes $\vec{u}, \vec{v} \in$ V as inputs and gives the output $f_1, f_2\in$ F.").scale(0.55).shift(2*DOWN)
+ self.play(ShowCreation(big_box))
+ self.play(ShowCreation(box))
+ self.play(ShowCreation(Linear),ShowCreation(Functional))
+ self.wait(2)
+ self.play(ShowCreation(arrow1),ShowCreation(u))
+ self.play(ShowCreation(arrow3),ShowCreation(f1))
+ self.wait(0.7)
+ self.play(ShowCreation(arrow2),ShowCreation(v))
+ self.play(ShowCreation(arrow4),ShowCreation(f2))
+ self.wait(1)
+ self.play(ShowCreation(text))
+ self.wait(4)