Skip to content

Commit 539074f

Browse files
Merge pull request #14 from LearningToOptimize/mk/c1fix
Fixes for class 1
2 parents 3ab05e2 + 6039569 commit 539074f

File tree

11 files changed

+172
-89
lines changed

11 files changed

+172
-89
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
Admin.pptx
2-
*.DS_Store
2+
*.DS_Store

class01/Manifest.toml

Lines changed: 48 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ manifest_format = "2.0"
55
project_hash = "33fab7715768642c9fee44610a16a04e852547fe"
66

77
[[deps.ADTypes]]
8-
git-tree-sha1 = "7927b9af540ee964cc5d1b73293f1eb0b761a3a1"
8+
git-tree-sha1 = "60665b326b75db6517939d0e1875850bc4a54368"
99
uuid = "47edcb42-4c32-4615-8424-f2b9edc5f35b"
10-
version = "1.16.0"
10+
version = "1.17.0"
1111

1212
[deps.ADTypes.extensions]
1313
ADTypesChainRulesCoreExt = "ChainRulesCore"
@@ -216,10 +216,10 @@ uuid = "fa961155-64e5-5f13-b03f-caf6b980ea82"
216216
version = "0.5.0"
217217

218218
[[deps.CPUSummary]]
219-
deps = ["CpuId", "IfElse", "PrecompileTools", "Static"]
220-
git-tree-sha1 = "5a97e67919535d6841172016c9530fd69494e5ec"
219+
deps = ["CpuId", "IfElse", "PrecompileTools", "Preferences", "Static"]
220+
git-tree-sha1 = "f3a21d7fc84ba618a779d1ed2fcca2e682865bab"
221221
uuid = "2a0fbf3d-bb9c-48f3-b0a9-814d99fd7ab9"
222-
version = "0.2.6"
222+
version = "0.2.7"
223223

224224
[[deps.CRC32c]]
225225
uuid = "8bf52ea8-c179-5cab-976a-9e18b702a9bc"
@@ -268,9 +268,9 @@ version = "1.72.5"
268268

269269
[[deps.ChainRulesCore]]
270270
deps = ["Compat", "LinearAlgebra"]
271-
git-tree-sha1 = "06ee8d1aa558d2833aa799f6f0b31b30cada405f"
271+
git-tree-sha1 = "e4c6a16e77171a5f5e25e9646617ab1c276c5607"
272272
uuid = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
273-
version = "1.25.2"
273+
version = "1.26.0"
274274
weakdeps = ["SparseArrays"]
275275

276276
[deps.ChainRulesCore.extensions]
@@ -431,11 +431,6 @@ git-tree-sha1 = "fcbb72b032692610bfbdb15018ac16a36cf2e406"
431431
uuid = "adafc99b-e345-5852-983c-f28acb93d879"
432432
version = "0.3.1"
433433

434-
[[deps.Crayons]]
435-
git-tree-sha1 = "249fe38abf76d48563e2f4556bebd215aa317e15"
436-
uuid = "a8cc5b0e-0ffa-5ad4-8c14-923d3ee1735f"
437-
version = "4.1.1"
438-
439434
[[deps.CustomUnitRanges]]
440435
git-tree-sha1 = "1a3f97f907e6dd8983b744d2642651bb162a3f7a"
441436
uuid = "dc8bdbbb-1ca9-579f-8c36-e416f6a65cce"
@@ -1294,9 +1289,9 @@ version = "1.4.0"
12941289

12951290
[[deps.Latexify]]
12961291
deps = ["Format", "InteractiveUtils", "LaTeXStrings", "MacroTools", "Markdown", "OrderedCollections", "Requires"]
1297-
git-tree-sha1 = "4f34eaabe49ecb3fb0d58d6015e32fd31a733199"
1292+
git-tree-sha1 = "52e1296ebbde0db845b356abbbe67fb82a0a116c"
12981293
uuid = "23fbe1c1-3f47-55db-b15f-69d7ec21a316"
1299-
version = "0.16.8"
1294+
version = "0.16.9"
13001295

13011296
[deps.Latexify.extensions]
13021297
DataFramesExt = "DataFrames"
@@ -1525,9 +1520,9 @@ version = "1.42.1"
15251520

15261521
[[deps.MathTeXEngine]]
15271522
deps = ["AbstractTrees", "Automa", "DataStructures", "FreeTypeAbstraction", "GeometryBasics", "LaTeXStrings", "REPL", "RelocatableFolders", "UnicodeFun"]
1528-
git-tree-sha1 = "6e64d2321257cc52f47e193407d0659ea1b2b431"
1523+
git-tree-sha1 = "a370fef694c109e1950836176ed0d5eabbb65479"
15291524
uuid = "0a4f8689-d25c-4efe-a92b-7142dfc1aa53"
1530-
version = "0.6.5"
1525+
version = "0.6.6"
15311526

15321527
[[deps.MbedTLS]]
15331528
deps = ["Dates", "MbedTLS_jll", "MozillaCACerts_jll", "NetworkOptions", "Random", "Sockets"]
@@ -1708,9 +1703,9 @@ version = "1.5.0"
17081703

17091704
[[deps.OpenSSL_jll]]
17101705
deps = ["Artifacts", "JLLWrappers", "Libdl"]
1711-
git-tree-sha1 = "87510f7292a2b21aeff97912b0898f9553cc5c2c"
1706+
git-tree-sha1 = "2ae7d4ddec2e13ad3bddf5c0796f7547cf682391"
17121707
uuid = "458c3c95-2e84-50aa-8efc-19380b2a3a95"
1713-
version = "3.5.1+0"
1708+
version = "3.5.2+0"
17141709

17151710
[[deps.OpenSpecFun_jll]]
17161711
deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl"]
@@ -1855,9 +1850,9 @@ version = "2.3.0"
18551850

18561851
[[deps.Plots]]
18571852
deps = ["Base64", "Contour", "Dates", "Downloads", "FFMPEG", "FixedPointNumbers", "GR", "JLFzf", "JSON", "LaTeXStrings", "Latexify", "LinearAlgebra", "Measures", "NaNMath", "Pkg", "PlotThemes", "PlotUtils", "PrecompileTools", "Printf", "REPL", "Random", "RecipesBase", "RecipesPipeline", "Reexport", "RelocatableFolders", "Requires", "Scratch", "Showoff", "SparseArrays", "Statistics", "StatsBase", "TOML", "UUIDs", "UnicodeFun", "UnitfulLatexify", "Unzip"]
1858-
git-tree-sha1 = "3db9167c618b290a05d4345ca70de6d95304a32a"
1853+
git-tree-sha1 = "9a9216c0cf706cb2cc58fd194878180e3e51e8c0"
18591854
uuid = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
1860-
version = "1.40.17"
1855+
version = "1.40.18"
18611856

18621857
[deps.Plots.extensions]
18631858
FileIOExt = "FileIO"
@@ -1875,21 +1870,21 @@ version = "1.40.17"
18751870

18761871
[[deps.Pluto]]
18771872
deps = ["Base64", "Configurations", "Dates", "Downloads", "ExpressionExplorer", "FileWatching", "GracefulPkg", "HTTP", "HypertextLiteral", "InteractiveUtils", "LRUCache", "Logging", "LoggingExtras", "MIMEs", "Malt", "Markdown", "MsgPack", "Pkg", "PlutoDependencyExplorer", "PrecompileSignatures", "PrecompileTools", "REPL", "RegistryInstances", "RelocatableFolders", "Scratch", "Sockets", "TOML", "Tables", "URIs", "UUIDs"]
1878-
git-tree-sha1 = "bafdc7b4c064d9a473b08e70085273061251b8dd"
1873+
git-tree-sha1 = "6f5b316f990235ebbaca22a26e559eff010f6233"
18791874
uuid = "c3e4b0f8-55cb-11ea-2926-15256bba5781"
1880-
version = "0.20.13"
1875+
version = "0.20.15"
18811876

18821877
[[deps.PlutoDependencyExplorer]]
18831878
deps = ["ExpressionExplorer", "InteractiveUtils", "Markdown"]
1884-
git-tree-sha1 = "9071bfe6d1c3c51f62918513e8dfa0705fbdef7e"
1879+
git-tree-sha1 = "c3e5073a977b1c58b2d55c1ec187c3737e64e6af"
18851880
uuid = "72656b73-756c-7461-726b-72656b6b696b"
1886-
version = "1.2.1"
1881+
version = "1.2.2"
18871882

18881883
[[deps.PlutoTeachingTools]]
18891884
deps = ["Downloads", "HypertextLiteral", "Latexify", "Markdown", "PlutoUI"]
1890-
git-tree-sha1 = "d0f6e09433d14161a24607268d89be104e743523"
1885+
git-tree-sha1 = "85778cdf2bed372008e6646c64340460764a5b85"
18911886
uuid = "661c6b06-c737-4d37-b85c-46df65de6f69"
1892-
version = "0.4.4"
1887+
version = "0.4.5"
18931888

18941889
[[deps.PlutoUI]]
18951890
deps = ["AbstractPlutoDingetjes", "Base64", "ColorTypes", "Dates", "Downloads", "FixedPointNumbers", "Hyperscript", "HypertextLiteral", "IOCapture", "InteractiveUtils", "JSON", "Logging", "MIMEs", "Markdown", "Random", "Reexport", "URIs", "UUIDs"]
@@ -1934,15 +1929,9 @@ version = "1.2.1"
19341929

19351930
[[deps.Preferences]]
19361931
deps = ["TOML"]
1937-
git-tree-sha1 = "9306f6085165d270f7e3db02af26a400d580f5c6"
1932+
git-tree-sha1 = "0f27480397253da18fe2c12a4ba4eb9eb208bf3d"
19381933
uuid = "21216c6a-2e73-6563-6e65-726566657250"
1939-
version = "1.4.3"
1940-
1941-
[[deps.PrettyTables]]
1942-
deps = ["Crayons", "LaTeXStrings", "Markdown", "PrecompileTools", "Printf", "Reexport", "StringManipulation", "Tables"]
1943-
git-tree-sha1 = "1101cd475833706e4d0e7b122218257178f48f34"
1944-
uuid = "08abe8d2-0d0c-5749-adfa-8a2ac140af0d"
1945-
version = "2.4.0"
1934+
version = "1.5.0"
19461935

19471936
[[deps.Primes]]
19481937
deps = ["IntegerMathUtils"]
@@ -2179,9 +2168,9 @@ version = "2025.5.20+0"
21792168

21802169
[[deps.SciMLBase]]
21812170
deps = ["ADTypes", "Accessors", "Adapt", "ArrayInterface", "CommonSolve", "ConstructionBase", "Distributed", "DocStringExtensions", "EnumX", "FunctionWrappersWrappers", "IteratorInterfaceExtensions", "LinearAlgebra", "Logging", "Markdown", "Moshi", "PrecompileTools", "Preferences", "Printf", "RecipesBase", "RecursiveArrayTools", "Reexport", "RuntimeGeneratedFunctions", "SciMLOperators", "SciMLStructures", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface"]
2182-
git-tree-sha1 = "c056c723b68700fec386dfde8c577089df720c8e"
2171+
git-tree-sha1 = "1a1b2ed5178814d32374d98f808163c24d47f1d8"
21832172
uuid = "0bca4576-84f4-4d90-8ffe-ffa030f20462"
2184-
version = "2.108.0"
2173+
version = "2.110.0"
21852174

21862175
[deps.SciMLBase.extensions]
21872176
SciMLBaseChainRulesCoreExt = "ChainRulesCore"
@@ -2206,15 +2195,20 @@ version = "2.108.0"
22062195

22072196
[[deps.SciMLOperators]]
22082197
deps = ["Accessors", "ArrayInterface", "DocStringExtensions", "LinearAlgebra", "MacroTools"]
2209-
git-tree-sha1 = "7d3a1519dc4d433a6b20035eaff20bde8be77c66"
2198+
git-tree-sha1 = "aea915a39b547c48a18ee041120db1ae8df5a691"
22102199
uuid = "c0aeaf25-5076-4817-a8d5-81caf7dfa961"
2211-
version = "1.4.0"
2200+
version = "1.5.0"
22122201
weakdeps = ["SparseArrays", "StaticArraysCore"]
22132202

22142203
[deps.SciMLOperators.extensions]
22152204
SciMLOperatorsSparseArraysExt = "SparseArrays"
22162205
SciMLOperatorsStaticArraysCoreExt = "StaticArraysCore"
22172206

2207+
[[deps.SciMLPublic]]
2208+
git-tree-sha1 = "ed647f161e8b3f2973f24979ec074e8d084f1bee"
2209+
uuid = "431bcebd-1456-4ced-9d72-93c2757fff0b"
2210+
version = "1.0.0"
2211+
22182212
[[deps.SciMLStructures]]
22192213
deps = ["ArrayInterface"]
22202214
git-tree-sha1 = "566c4ed301ccb2a44cbd5a27da5f885e0ed1d5df"
@@ -2390,12 +2384,6 @@ weakdeps = ["ChainRulesCore", "InverseFunctions"]
23902384
StatsFunsChainRulesCoreExt = "ChainRulesCore"
23912385
StatsFunsInverseFunctionsExt = "InverseFunctions"
23922386

2393-
[[deps.StringManipulation]]
2394-
deps = ["PrecompileTools"]
2395-
git-tree-sha1 = "725421ae8e530ec29bcbdddbe91ff8053421d023"
2396-
uuid = "892a3eda-7b42-436c-8928-eab12a02cf0e"
2397-
version = "0.4.1"
2398-
23992387
[[deps.StructArrays]]
24002388
deps = ["ConstructionBase", "DataAPI", "Tables"]
24012389
git-tree-sha1 = "9537ef82c42cdd8c5d443cbc359110cbb36bae10"
@@ -2433,10 +2421,16 @@ uuid = "bea87d4a-7f5b-5778-9afe-8cc45184846c"
24332421
version = "7.2.1+1"
24342422

24352423
[[deps.SymbolicIndexingInterface]]
2436-
deps = ["Accessors", "ArrayInterface", "PrettyTables", "RuntimeGeneratedFunctions", "StaticArraysCore"]
2437-
git-tree-sha1 = "59ca6eddaaa9849e7de9fd1153b6faf0b1db7b80"
2424+
deps = ["Accessors", "ArrayInterface", "RuntimeGeneratedFunctions", "StaticArraysCore"]
2425+
git-tree-sha1 = "93104ca226670c0cb92ba8bc6998852ad55a2d4c"
24382426
uuid = "2efcf032-c050-4f8e-a9bb-153293bab1f5"
2439-
version = "0.3.42"
2427+
version = "0.3.43"
2428+
2429+
[deps.SymbolicIndexingInterface.extensions]
2430+
SymbolicIndexingInterfacePrettyTablesExt = "PrettyTables"
2431+
2432+
[deps.SymbolicIndexingInterface.weakdeps]
2433+
PrettyTables = "08abe8d2-0d0c-5749-adfa-8a2ac140af0d"
24402434

24412435
[[deps.SymbolicLimits]]
24422436
deps = ["SymbolicUtils"]
@@ -2446,9 +2440,9 @@ version = "0.2.2"
24462440

24472441
[[deps.SymbolicUtils]]
24482442
deps = ["AbstractTrees", "ArrayInterface", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "ExproniconLite", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TaskLocalValues", "TermInterface", "TimerOutputs", "Unityper"]
2449-
git-tree-sha1 = "cb2beb85947c0a894efa345c436edad20ecec977"
2443+
git-tree-sha1 = "8c103c491ccf3e2b4284635c24b5de768adc6be8"
24502444
uuid = "d1185830-fcd6-423d-90d6-eec64667417b"
2451-
version = "3.30.0"
2445+
version = "3.31.0"
24522446

24532447
[deps.SymbolicUtils.extensions]
24542448
SymbolicUtilsLabelledArraysExt = "LabelledArrays"
@@ -2459,10 +2453,10 @@ version = "3.30.0"
24592453
ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267"
24602454

24612455
[[deps.Symbolics]]
2462-
deps = ["ADTypes", "ArrayInterface", "Bijections", "CommonWorldInvalidations", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "LaTeXStrings", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "OffsetArrays", "PrecompileTools", "Primes", "RecipesBase", "Reexport", "RuntimeGeneratedFunctions", "SciMLBase", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArraysCore", "SymbolicIndexingInterface", "SymbolicLimits", "SymbolicUtils", "TermInterface"]
2463-
git-tree-sha1 = "6feaa0f2eb9728a6089ad81e31bf7539d41c8a30"
2456+
deps = ["ADTypes", "ArrayInterface", "Bijections", "CommonWorldInvalidations", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "LaTeXStrings", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "OffsetArrays", "PrecompileTools", "Primes", "RecipesBase", "Reexport", "RuntimeGeneratedFunctions", "SciMLBase", "SciMLPublic", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArraysCore", "SymbolicIndexingInterface", "SymbolicLimits", "SymbolicUtils", "TermInterface"]
2457+
git-tree-sha1 = "83d9eaffba90db9f0127ef4ae8ffa124e93b34f2"
24642458
uuid = "0c5d862f-8b57-4792-8d23-62f2024744c7"
2465-
version = "6.49.0"
2459+
version = "6.51.0"
24662460

24672461
[deps.Symbolics.extensions]
24682462
SymbolicsD3TreesExt = "D3Trees"
@@ -2562,9 +2556,9 @@ uuid = "3bb67fe8-82b1-5028-8e26-92a6c54297fa"
25622556
version = "0.11.3"
25632557

25642558
[[deps.Tricks]]
2565-
git-tree-sha1 = "0fc001395447da85495b7fef1dfae9789fdd6e31"
2559+
git-tree-sha1 = "372b90fe551c019541fafc6ff034199dc19c8436"
25662560
uuid = "410a4b4d-49e4-4fbc-ab6d-cb71b17b3775"
2567-
version = "0.1.11"
2561+
version = "0.1.12"
25682562

25692563
[[deps.TriplotBase]]
25702564
git-tree-sha1 = "4d4ed7f294cda19382ff7de4c137d24d16adc89b"

class01/background_materials/math_basics.html

Lines changed: 19 additions & 0 deletions
Large diffs are not rendered by default.

class01/background_materials/math_basics.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
### A Pluto.jl notebook ###
2-
# v0.20.13
2+
# v0.20.15
33

44
using Markdown
55
using InteractiveUtils

class01/background_materials/optimization_basics.html

Lines changed: 19 additions & 0 deletions
Large diffs are not rendered by default.

class01/background_materials/optimization_basics.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
### A Pluto.jl notebook ###
2-
# v0.20.13
2+
# v0.20.15
33

44
using Markdown
55
using InteractiveUtils

class01/background_materials/optimization_motivation.html

Lines changed: 19 additions & 0 deletions
Large diffs are not rendered by default.

class01/background_materials/optimization_motivation.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
### A Pluto.jl notebook ###
2-
# v0.20.13
2+
# v0.20.15
33

44
using Markdown
55
using InteractiveUtils
@@ -9,7 +9,6 @@ begin
99
class_dir = dirname(@__DIR__)
1010
import Pkg
1111
Pkg.activate("..")
12-
Pkg.status()
1312
end
1413

1514
# ╔═╡ 054eb7cf-cb60-41a0-9a87-215e36dcf53d

class01/class01_intro.html

Lines changed: 19 additions & 0 deletions
Large diffs are not rendered by default.

class01/class01_intro.jl

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
### A Pluto.jl notebook ###
2-
# v0.20.13
2+
# v0.20.15
33

44
using Markdown
55
using InteractiveUtils
@@ -57,13 +57,13 @@ begin
5757
MarkdownLiteral.@markdown(
5858
"""
5959
60-
[^cmu]: Zachary Manchester et al. Optimal Control and Reinforcement Learning at Carnegie Mellon University - [CMU 16-745]("https://optimalcontrol.ri.cmu.edu/")
60+
[^cmu]: Zachary Manchester et al. [Optimal Control and Reinforcement Learning at Carnegie Mellon University - CMU 16-745](https://optimalcontrol.ri.cmu.edu/)
6161
62-
[^OptProx]: Van Hentenryck, P., 2024. Fusing Artificial Intelligence and Optimization with Trustworthy Optimization Proxies. Collections, 57(02).
62+
[^OptProx]: Van Hentenryck, P., 2024. [Fusing Artificial Intelligence and Optimization with Trustworthy Optimization Proxies](https://www.siam.org/publications/siam-news/articles/fusing-artificial-intelligence-and-optimization-with-trustworthy-optimization-proxies/). Collections, 57(02).
6363
64-
[^ArmManip]: Guechi, E.H., Bouzoualegh, S., Zennir, Y. and Blažič, S., 2018. MPC control and LQ optimal control of a two-link robot arm: A comparative study. Machines, 6(3), p.37.
64+
[^ArmManip]: Guechi, E.H., Bouzoualegh, S., Zennir, Y. and Blažič, S., 2018. [MPC control and LQ optimal control of a two-link robot arm: A comparative study](https://www.mdpi.com/2075-1702/6/3/37). Machines, 6(3), p.37.
6565
66-
[^ZachMIT]: Zachary Manchester talk at MIT - [MIT Robotics - Zac Manchester - Composable Optimization for Robotic Motion Planning and Control]("https://www.youtube.com/watch?v=eSleutHuc0w&ab_channel=MITRobotics").
66+
[^ZachMIT]: Zachary Manchester talk at MIT - [MIT Robotics - Zac Manchester - Composable Optimization for Robotic Motion Planning and Control](https://www.youtube.com/watch?v=eSleutHuc0w&ab_channel=MITRobotics).
6767
6868
"""
6969
)
@@ -211,7 +211,9 @@ md"[^OptProx]"
211211
"""
212212

213213
# ╔═╡ 45275d44-e268-43cb-8156-feecd916a6da
214-
@htl """
214+
# ╠═╡ skip_as_script = true
215+
#=╠═╡
216+
Foldable(md"#### LearningToOptimize Project", @htl """
215217
<div style="
216218
border:1px solid #ccc;
217219
border-radius:6px;
@@ -346,7 +348,8 @@ md"[^OptProx]"
346348
</p>
347349
348350
</div>
349-
"""
351+
""")
352+
╠═╡ =#
350353

351354
# ╔═╡ c08f511e-b91d-4d17-a286-96469c31568a
352355
md"## Example: Robotic Arm Manipulation"
@@ -481,7 +484,7 @@ md"State $x$ is everything you need to define to determine the how your system w
481484
md"### Example: Pendulum"
482485

483486
# ╔═╡ baa3993c-96b0-474e-b5b4-f9eaea642a49
484-
function pendulum(θ_deg = 60; L = 4, fsize = (520, 450), _xlims=nothing)
487+
function pendulum(θ_deg = 60; L = 4, fsize = (520, 450), _xlims=nothing, _ylims=(-5, 5))
485488
θ = deg2rad(θ_deg)
486489
pivot = Point2f(0, 0)
487490
mass = Point2f(-L*sin(θ), -L*cos(θ)) # rod tip
@@ -495,11 +498,9 @@ function pendulum(θ_deg = 60; L = 4, fsize = (520, 450), _xlims=nothing)
495498
xgridvisible = false,
496499
ygridvisible = false)
497500
hidespines!(ax)
498-
499-
_y = -L*cos(θ)
500-
if _y > 0
501-
ylims!(ax, (-1, _y + 1))
502-
end
501+
if !isnothing(_ylims)
502+
ylims!(ax, _ylims)
503+
end
503504

504505
if !isnothing(_xlims)
505506
xlims!(ax, _xlims)
@@ -585,7 +586,7 @@ x \in S^{1} \times \mathbb{R} & \text{Cylinder}
585586
""")
586587

587588
# ╔═╡ 4d598933-05a9-44fa-b5a7-f7e1c7afb094
588-
md"## Control--Afine Systems
589+
md"## Control--Affine Systems
589590
590591
Non--linear Systems of the form:
591592
```math
@@ -594,7 +595,7 @@ Non--linear Systems of the form:
594595
595596
$\implies$ Non--linear in the state but affine in the input/control.
596597
597-
Control--Afine Systems are common in many mechanical systems.
598+
Control--Affine Systems are common in many mechanical systems.
598599
599600
"
600601

0 commit comments

Comments
 (0)