Commit 8e3c8d72 authored by Sebastien Timmermans's avatar Sebastien Timmermans 🎹

[Fix] remove useless function print matrix vector in mbs_print_data, issue #61

parent 59a74d1d
Pipeline #4407 passed with stage
in 8 minutes and 56 seconds
......@@ -1039,7 +1039,7 @@ void mbs_print_equil(MbsEquil* eq)
}
mbs_msg(" nquch . . . . = %d \n", eq->options->nquch);
print_intvector("quch", eq->options->nquch, eq->options->quch);
mbs_msg("quch = "); print_ivec_1(eq->options->quch);
mbs_msg(" nxe . . . . = %d \n", eq->options->nxe);
mbs_msg("Variables \n");
......
......@@ -11,41 +11,6 @@
#include "mbs_user_interface.h"
#endif
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
// Those utility functions should be move elsewhere
// We should use function of useful_functions. h but signature is not the same ... we need to merge that all!
void print_vector(char* prefix, int n, double *vec){
int i;
mbs_msg(" %s = [", prefix);
for(i=1; i <= n ; i++){
mbs_msg(" %lf ", vec[i]);
}
mbs_msg("]\n");
}
void print_intvector(char* prefix, int n, int *vec){
int i;
mbs_msg(" %s = [", prefix);
for(i=1; i <= n ; i++){
mbs_msg(" %d ", vec[i]);
}
mbs_msg("]\n");
}
void print_matrix(char* prefix, int r, int c, double **mat){
int i, j;
mbs_msg(" %s = [", prefix);
for(i=1; i <= r ; i++){
for(j=1; j <= c ; j++){
mbs_msg(" %lf ", mat[i][j]);
}
mbs_msg(" \n ");
}
mbs_msg("]\n");
}
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
void mbs_print_data(MbsData* s){
mbs_msg("\n MbsData \n");
......@@ -69,30 +34,28 @@ void mbs_print_data(MbsData* s){
mbs_msg(" Nuser_model = %d \n", s->Nuser_model);
mbs_msg(" Nux . . . . = %d \n", s->Nux);
print_vector("g", 3, s->g);
mbs_msg("g = "); print_dvec_0(s->g,3);
print_vector("q ", s->njoint, s->q);
print_vector("qd ", s->njoint, s->qd);
print_vector("qdd", s->njoint, s->qdd);
print_vector("Qq", s->njoint, s->Qq);
mbs_msg("q = "); print_dvec_1(s->q);
mbs_msg("qd = "); print_dvec_1(s->qd);
mbs_msg("qdd = "); print_dvec_1(s->qdd);
mbs_msg("Qq = "); print_dvec_1(s->Qq);
mbs_msg("\n");
print_intvector("qc ", s->nqc, s->qc);
print_intvector("qu ", s->nqu, s->qu);
print_intvector("qa ", s->nqa, s->qa);
print_intvector("qv ", s->nqv, s->qv);
print_intvector("hu ", s->nhu, s->hu);
print_matrix("dpt ", 3, s->npt, s->dpt);
print_vector("m", s->njoint, s->m);
print_matrix("In ", 9, s->njoint, s->In);
print_matrix("l ", 3, s->njoint, s->l);
mbs_msg("qc = "); print_ivec_1(s->qc);
mbs_msg("qu = "); print_ivec_1(s->qu);
mbs_msg("qa = "); print_ivec_1(s->qa);
mbs_msg("qv = "); print_ivec_1(s->qv);
mbs_msg("hu = "); print_ivec_1(s->hu);
mbs_print_user_model(s->user_model);
/*printUserModel(s->usrMod);
mbs_msg("dpt = "); print_dmat_0(s->dpt,s->npt, s->npt);
mbs_msg("m = "); print_dvec_1(s->m);
mbs_msg("In = "); print_dmat_0(s->In, 9, s->njoint);
mbs_msg("l = "); print_dmat_0(s->l,3, s->njoint);
mbs_msg("\n");
printUserIO(s->userIO);*/
mbs_print_user_model(s->user_model);
}
void mbs_copy_data(MbsData* s, MbsData* s_copy)
......
......@@ -522,9 +522,6 @@ void scale_matrix(double** matrix, int* n, int* initzeros);
extern "C" {
#endif
void mbs_print_data(MbsData *mbs_data);
void print_vector(char* prefix, int n, double *vec);
void print_intvector(char* prefix, int n, int *vec);
void print_matrix(char* prefix, int r, int c, double **mat);
void mbs_copy_data(MbsData* s, MbsData* s_copy);
/*! \brief Reset all fields of a MbsData structure to initial values
*
......
Markdown is supported
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