Type miss-match in calling mex function (Uint16_T)

1 Ansicht (letzte 30 Tage)
fahad javed
fahad javed am 26 Okt. 2011
Hi,
I am running Matlab 7.7.0 (R2008b) on a windows machine. I am running the Statistical Pattern Recognition Toolbox for Matlab. http://cmp.felk.cvut.cz/cmp/software/stprtool/. The matlab m file calls a mex function. The type in signature in c file is uint16_T *. I am passing a double array which is being casted as uint16(I). When I run the code it is giving the following error:
Undefined function or method 'qpssvm_mex' for input arguments of type 'uint16'.
Calling code:
[x,exitflag,t,access,History] = qpssvm_mex(H,f,b,uint16(I),x0,...
options.tmax,options.tolabs,options.tolrel,options.verb);
MEX function signature:
void mexFunction( int nlhs, mxArray *plhs[],
int nrhs, const mxArray *prhs[] )
{
int exitflag; /* status of the solution (output arg) */
long t; /* number of iterations (output arg) */
double *x; /* solution vector (output arg)*/
double *History; /* UB and LB history (output arg) */
int verb; /* verbosity (input arg)*/
long tmax; /* max number of iteration (input arg)*/
double tolrel; /* stopping condition (input arg) */
double tolabs; /* stopping condition (input arg) */
double *x0; /* initial solution (input arg)*/
double *f; /* vector f (input arg) */
double b; /* scalar b (input arg) */
uint16_T *I; /* vector of uint16_T (input arg) */
double *diag_H; /* diagonal of matrix H */
long i ; /* loop variable */
double *tmp_ptr;
Any help will be greatly appreciated.
Fahad

Antworten (0)

Kategorien

Mehr zu Write C Functions Callable from MATLAB (MEX Files) finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by