@@ -197,9 +197,9 @@ def rootlocus_pid_designer(plant, gain='P', sign=+1, input_signal='r',
197197 When first run, `deltaK` is set to 0; click on a branch of the root locus
198198 plot to try a different value. Each click updates plots and prints
199199 the corresponding `deltaK`. To tune all three PID gains, repeatedly call
200- `pid_designer `, and select a different `gain` each time (`'P'`, `'I '`,
201- or `'D'`). Make sure to add the resulting `deltaK` to your chosen initial
202- gain on the next iteration.
200+ `rootlocus_pid_designer `, and select a different `gain` each time (`'P'`,
201+ `'I'`, or `'D'`). Make sure to add the resulting `deltaK` to your chosen
202+ initial gain on the next iteration.
203203
204204 Example: to examine the effect of varying `Kp` starting from an intial
205205 value of 10, use the arguments `gain='P', Kp0=10`. Suppose a `deltaK`
@@ -331,5 +331,5 @@ def rootlocus_pid_designer(plant, gain='P', sign=+1, input_signal='r',
331331 outlist = ['output' , 'y' ])
332332 if plot :
333333 sisotool (loop , kvect = (0. ,))
334- return StateSpace ( loop [1 , 1 ]. A , loop [ 1 , 1 ]. B , loop [ 1 , 1 ]. C , loop [ 1 , 1 ]. D ,
335- loop [ 1 , 1 ] .dt )
334+ cl = loop [1 , 1 ] # closed loop transfer function with initial gains
335+ return StateSpace ( cl . A , cl . B , cl . C , cl . D , cl .dt )
0 commit comments