Skip to content

Commit a790275

Browse files
committed
doc: power and torque limits in manual
this is a bit more realistic and it removes some weird extreme negative torque solutions
1 parent 6613a1e commit a790275

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/src/manual/nonlinmpc.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ regenerative circuitry.
245245

246246
## Custom Nonlinear Inequality Constraints
247247

248-
Instead of limits on the torque, suppose that the motor can deliver a maximum of 3 watt:
248+
In addition to the torque limits, suppose that the motor can deliver a maximum of 3 watt:
249249

250250
```math
251251
P(t) = τ(t) ω(t) ≤ P_\mathrm{max}
@@ -288,6 +288,7 @@ specifying the number of custom inequality constraints `nc`:
288288
```@example man_nonlin
289289
Cwt, Pmax, nc = 1e5, 3, Hp+1
290290
nmpc2 = NonLinMPC(estim2; Hp, Hc, Nwt=Nwt, Mwt=[0.5, 0], Cwt, gc!, nc, p=Pmax)
291+
nmpc2 = setconstraint!(nmpc2; umin, umax)
291292
using JuMP; unset_time_limit_sec(nmpc2.optim) # hide
292293
nmpc2 # hide
293294
```

0 commit comments

Comments
 (0)