help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

octave function called from c code


From: Esposito Francesco
Subject: octave function called from c code
Date: Tue, 08 Mar 2011 17:45:16 +0100

Hi All,

I'm using filter function (y=filter(b,a,x,zi)) of Octave from a C application but my result is slightly different from the one obtained by using Octave from command line. Below my C-code:

functionArguments (0) = b;
functionArguments (1) = a;
functionArguments (2) = x;
functionArguments (3) = zi;

const octave_value_list result = feval ("filter", functionArguments);

Matrix res(n,1);
res = result(0).matrix_value();

But if I try to print one of the element of res

cout << res(n-1,0) << endl;

It appear different from the result of Octave command line. Why?

Thanks



reply via email to

[Prev in Thread] Current Thread [Next in Thread]