|
STAR
Cal STAR — firmware, DAQ server, and engine design
|
Variables | |
| float | R = 1.0 |
| float | L = 0.5 |
| float | Ke = 0.01 |
| float | Kt = 0.01 |
| float | J = 0.01 |
| float | B = 0.1 |
| A = np.array([[-R / L, -Ke / L, 0], [Kt / J, -B / J, 0], [0, 1, 0]]) | |
| C = np.array([[0, 0, 1]]) | |
| Q = np.diag([10, 1, 100]) | |
| R_mat = np.array([[0.01]]) | |
| P = solve_continuous_are(A, B, Q, R_mat) | |
| float | K = np.linalg.inv(R_mat) @ B.T @ P |
| float | dt = 0.001 |
| float | T = 5.0 |
| N = int(T / dt) | |
| t = np.linspace(0, T, N) | |
| x = np.zeros((3, 1)) | |
| float | r = 1.0 |
| x_hist = np.array(x_hist) | |
| u_hist = np.array(u_hist) | |
| float | u = -K @ x + K[0, 2] * r |
| float | dx = A @ x + B * u |
| figsize | |
| label | |
| color | |
| linestyle | |
Definition at line 22 of file lqr_motor.py.
| lqr_motor.B = 0.1 |
Definition at line 17 of file lqr_motor.py.
| lqr_motor.C = np.array([[0, 0, 1]]) |
Definition at line 24 of file lqr_motor.py.
| lqr_motor.color |
Definition at line 68 of file lqr_motor.py.
| float lqr_motor.dt = 0.001 |
Definition at line 39 of file lqr_motor.py.
| lqr_motor.figsize |
Definition at line 64 of file lqr_motor.py.
| float lqr_motor.J = 0.01 |
Definition at line 16 of file lqr_motor.py.
Definition at line 33 of file lqr_motor.py.
| float lqr_motor.Ke = 0.01 |
Definition at line 14 of file lqr_motor.py.
| float lqr_motor.Kt = 0.01 |
Definition at line 15 of file lqr_motor.py.
| float lqr_motor.L = 0.5 |
Definition at line 13 of file lqr_motor.py.
| lqr_motor.label |
Definition at line 67 of file lqr_motor.py.
| lqr_motor.linestyle |
Definition at line 68 of file lqr_motor.py.
Definition at line 41 of file lqr_motor.py.
| lqr_motor.Q = np.diag([10, 1, 100]) |
Definition at line 29 of file lqr_motor.py.
| float lqr_motor.R = 1.0 |
Definition at line 12 of file lqr_motor.py.
| lqr_motor.r = 1.0 |
Definition at line 45 of file lqr_motor.py.
| lqr_motor.R_mat = np.array([[0.01]]) |
Definition at line 30 of file lqr_motor.py.
| float lqr_motor.T = 5.0 |
Definition at line 40 of file lqr_motor.py.
Definition at line 42 of file lqr_motor.py.
| lqr_motor.u_hist = np.array(u_hist) |
Definition at line 47 of file lqr_motor.py.
| lqr_motor.x = np.zeros((3, 1)) |
Definition at line 44 of file lqr_motor.py.
| lqr_motor.x_hist = np.array(x_hist) |
Definition at line 47 of file lqr_motor.py.