Skip to content

Commit c066a94

Browse files
authored
InvertedPendulumMPCControl: fixed deprecated waring about using * for matrix multiplication (AtsushiSakai#631)
1 parent 058addd commit c066a94

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Control/InvertedPendulumMPCControl/inverted_pendulum_mpc_control.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ def mpc_control(x0):
7777
for t in range(T):
7878
cost += cvxpy.quad_form(x[:, t + 1], Q)
7979
cost += cvxpy.quad_form(u[:, t], R)
80-
constr += [x[:, t + 1] == A * x[:, t] + B * u[:, t]]
80+
constr += [x[:, t + 1] == A @ x[:, t] + B @ u[:, t]]
8181

8282
constr += [x[:, 0] == x0[:, 0]]
8383
prob = cvxpy.Problem(cvxpy.Minimize(cost), constr)

0 commit comments

Comments
 (0)