I’m using maltab interface. I’m working on MPC for autonomous driving path tracking.
I formulated my MPC in the spatial domain i.e. each finite-horizon problem is discretized in space. This requires a spatial horizon (N in [m]) and a certain discretization (ds in [m]). However, although I’m keeping the number of nodes, N, constant, I want to vary ds in the loop.
In matlab, however, it does not allow me to change it in the loop. If I try to set time_steps in the loop, it doesn’t allow me:
ocp_set: field time_steps not supported, supported values are: p, constr_x0, constr_lbx, constr_ubx, constr_C, constr_D, constr_lg, constr_ug, constr_lh, constr_uh, constr_lbu, constr_ubu, cost_y_ref[_e], sl, su, x, xdot, u, pi, lam, z, cost_Vu, cost_Vx, cost_Vz, cost_W, cost_Z, cost_Zl, cost_Zu, cost_z, cost_zl, cost_zu, init_x, init_u, init_z, init_xdot, init_gnsf_phi, init_pi, nlp_solver_max_iter, qp_warm_start, warm_start_first_qp, print_level
Is there anyway I can change the shooting nodes time steps in the loop, in matlab?