Skip to content

Commit ce97323

Browse files
committed
doc: idem
1 parent df6ff06 commit ce97323

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

docs/src/manual/nonlinmpc.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,7 @@ function gc!(LHS, Ue, Ŷe, _, p, ϵ)
281281
end
282282
return nothing
283283
end
284+
nothing;
284285
```
285286

286287
Here we implemented the custom nonlinear constraint function in the mutating form to reduce
@@ -294,12 +295,14 @@ Cwt, Pmax, nc = 1e5, 3, Hp+1
294295
p_nmpc2 = [Pmax, Hp]
295296
nmpc2 = NonLinMPC(estim2; Hp, Hc, Nwt=Nwt, Mwt=[0.5, 0], Cwt, gc!, nc, p=p_nmpc2)
296297
using JuMP; unset_time_limit_sec(nmpc2.optim) # hide
298+
nmpc2 # hide
297299
```
298300

299301
In addition to the 180° setpoint response:
300302

301303
```@example 1
302304
res3_ry = sim!(nmpc2, N, [180; 0]; plant=plant2, x_0=[0, 0], x̂_0=[0, 0, 0])
305+
nothing # hide
303306
```
304307

305308
a plot for the power ``P(t)`` is included below:

0 commit comments

Comments
 (0)