Commit 7169b618 authored by Olivier Lantsoght's avatar Olivier Lantsoght 🏁
Browse files

[MbsAux] Remove unused variables in MbsAux Structure only defined if SIMULINK was not defined.

parent f5c42ad6
......@@ -161,20 +161,6 @@ MbsAux * initMbsAux(MbsData *s)
mbs_aux->Rruc = get_dvec_1(nquc);
mbs_aux->Rred = get_dvec_1(nqu);
#ifndef MBS_SIMULINK
mbs_aux->y = get_dvec_1(2 * nqu);
mbs_aux->dydx = get_dvec_1(2 * nqu);
for (i = 1; i <= s->nqu; i++)
{
mbs_aux->y[i - 1] = s->q[s->qu[i]];
mbs_aux->y[i + s->nqu - 1] = s->qd[s->qu[i]];
mbs_aux->dydx[i - 1] = s->qd[s->qu[i]];
mbs_aux->dydx[i + s->nqu - 1] = s->udd[i];
}
#endif
/**/
return mbs_aux;
}
......@@ -260,12 +246,5 @@ void freeMbsAux(MbsAux *mbs_aux, MbsData *s)
free_dvec_1(mbs_aux->Rruc);
free_dvec_1(mbs_aux->Rred);
#ifndef MBS_SIMULINK
free_dvec_1(mbs_aux->y);
free_dvec_1(mbs_aux->dydx);
#endif
free(mbs_aux);
}
......@@ -24,7 +24,7 @@ typedef struct MbsAux_tag
double NRerr;
int MAX_NR_ITER; //!< max number of iteration for NR procedure
int n_iter_close_loop; //!< number of iterations after closing loop procedure in mbs_close_geo
//!< initialized at 0; if n_iter_close_loop<0 => en error has occured !
//!< initialized at 0; if n_iter_close_loop<0 => en error has occured !
double *h, **Jac;
double *huserc, **Juserc;
......@@ -86,9 +86,6 @@ typedef struct MbsAux_tag
double *Rruc; //!< vector of size [nqu+nqc x 1] that contains the reduced residue for the equations of motions after the first reduction (dependent variables)
double *Rred; //!< vector of size [nqu x 1] that contains the reduced residue of the equations of motion after the second reduction (driven variables)
#ifndef MBS_SIMULINK
double x, *y, *dydx;
#endif
} MbsAux;
......
......@@ -87,8 +87,4 @@ MbsAux_c._fields_ = [
("phi", ctypes.POINTER(ctypes.c_double)),
("R", ctypes.POINTER(ctypes.c_double)),
("Rruc", ctypes.POINTER(ctypes.c_double)),
("Rred", ctypes.POINTER(ctypes.c_double)),
("x", ctypes.c_double),
("y", ctypes.POINTER(ctypes.c_double)),
("dydx", ctypes.POINTER(ctypes.c_double))]
("Rred", ctypes.POINTER(ctypes.c_double)), ]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment