Skip to content

Commit

Permalink
Rename initialize_y to compute_m
Browse files Browse the repository at this point in the history
  • Loading branch information
olejodd10 committed Apr 29, 2024
1 parent 7ea8c7c commit 5216870
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/SdqpLmpcConstant.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ static void get_column_M4(size_t index, real_t *column_M4) {
column_M4);
}

static void initialize_y(
static void compute_m(
size_t n_x,
size_t n_u,
size_t n_y,
Expand Down Expand Up @@ -453,7 +453,7 @@ void sdqp_lmpc_constant_cleanup(void) {

int sdqp_lmpc_constant_solve(size_t n_x, size_t n_u, size_t N, const real_t x0[n_x], real_t x[N][n_x], real_t u[N][n_u]) {
// initialize y
initialize_y(n_x, n_u, m_n_y, m_n_t, N, m_n_H,
compute_m(n_x, n_u, m_n_y, m_n_t, N, m_n_H,
CAST_CONST_2D_VLA(m_Q, n_x), CAST_CONST_2D_VLA(m_S, n_x), CAST_CONST_2D_VLA(m_R, n_u),
CAST_CONST_2D_VLA(m_A, n_x), CAST_CONST_2D_VLA(m_B, n_u), CAST_CONST_2D_VLA(m_C, n_x),
CAST_CONST_2D_VLA(m_Lt, n_x), x0, m_y);
Expand Down
4 changes: 2 additions & 2 deletions src/SdqpLmpcMmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ static void get_column_M4(size_t index, real_t *column_M4) {
}
}

static void initialize_y(
static void compute_m(
size_t n_x,
size_t n_u,
size_t N,
Expand Down Expand Up @@ -375,7 +375,7 @@ int sdqp_lmpc_mmc_solve(size_t n_x, size_t n_u, size_t N, const real_t x1_ref[N]
// initialize y
m_A = (real_t*)A;
m_B = (real_t*)B;
initialize_y(n_x, n_u, N, m_n_M, m_n_H, m_n_a,
compute_m(n_x, n_u, N, m_n_M, m_n_H, m_n_a,
m_q1, m_q2, x1_ref, x2_ref,
A, B, d,
m_x_min, m_x_max, m_n_sm, m_insertion_index_deviation_allowance, m_u_min, m_u_max,
Expand Down
4 changes: 2 additions & 2 deletions src/SdqpLmpcVarying.c
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ static void get_column_M4(size_t index, real_t *column_M4) {
}
}

static void initialize_y(
static void compute_m(
size_t n_x,
size_t n_u,
size_t n_y,
Expand Down Expand Up @@ -410,7 +410,7 @@ int sdqp_lmpc_varying_solve(size_t n_x, size_t n_u, size_t N, const real_t A[N][
// initialize y
m_A = (real_t*)A;
m_B = (real_t*)B;
initialize_y(n_x, n_u, m_n_y, m_n_t, N, m_n_M, m_n_H, m_n_a,
compute_m(n_x, n_u, m_n_y, m_n_t, N, m_n_M, m_n_H, m_n_a,
CAST_CONST_2D_VLA(m_Q, n_x), CAST_CONST_2D_VLA(m_S, n_x), CAST_CONST_2D_VLA(m_R, n_u), m_fx, m_fu,
A, B, d, CAST_CONST_2D_VLA(m_C, n_x),
m_y_min, m_y_max, CAST_CONST_2D_VLA(m_Lt, n_x), m_lt, m_u_min, m_u_max,
Expand Down

0 comments on commit 5216870

Please sign in to comment.