Skip to content

Commit 052a9b3

Browse files
committed
doc: minor modifications
1 parent 440b7c5 commit 052a9b3

File tree

2 files changed

+12
-6
lines changed

2 files changed

+12
-6
lines changed

docs/make.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ makedocs(
2727
"Examples" => [
2828
"Linear Design" => "manual/linmpc.md",
2929
"Nonlinear Design" => "manual/nonlinmpc.md",
30-
"MTK Integration" => "manual/mtk.md",
30+
"ModelingToolkit" => "manual/mtk.md",
3131
],
3232
],
3333
"Functions" => [

docs/src/manual/mtk.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,18 @@ using Logging; errlogger = ConsoleLogger(stderr, Error);
99
old_logger = global_logger(); global_logger(errlogger);
1010
```
1111

12-
## Pendulum Example
12+
## Pendulum Model
1313

1414
This example integrates the simple pendulum model of the [last section](@ref man_nonlin) in the
15-
[ModelingToolkit.jl](https://docs.sciml.ai/ModelingToolkit/stable/) (MTK) framework and
16-
extracts appropriate `f!` and `h!` functions to construct a [`NonLinModel`](@ref).
15+
[`ModelingToolkit.jl`](https://docs.sciml.ai/ModelingToolkit/stable/) (MTK) framework and
16+
extracts appropriate `f!` and `h!` functions to construct a [`NonLinModel`](@ref). An
17+
[`NonLinMPC`](@ref) is designed from this model and simulated to reproduce the results of
18+
the last section.
1719

1820
!!! danger "Disclaimer"
1921
This simple example is not an official interface to `ModelingToolkit.jl`. It is provided
20-
as a basic starting point template to combine both packages. There is no guarantee that
21-
it will work for all corner cases.
22+
as a basic starting template to combine both packages. There is no guarantee that it
23+
will work for all corner cases.
2224

2325
We first construct and instantiate the pendulum model:
2426

@@ -93,6 +95,8 @@ f_plant, h_plant, _, _ = generate_f_h(mtk_model, inputs, outputs)
9395
plant = setname!(NonLinModel(f_plant, h_plant, Ts, nu, nx, ny); u=vu, x=vx, y=vy)
9496
```
9597

98+
## Controller Design
99+
96100
We can than reproduce the Kalman filter and the controller design of the [last section](@ref man_nonlin):
97101

98102
```@example 1
@@ -127,6 +131,8 @@ savefig("plot2_MTK.svg"); nothing # hide
127131

128132
![plot2_MTK](plot2_MTK.svg)
129133

134+
## Acknowledgement
135+
130136
Authored by `1-Bart-1` and `baggepinnen`, thanks for the contribution.
131137

132138
```@setup 1

0 commit comments

Comments
 (0)