help-octave
[Top][All Lists]
Advanced

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

Re: API for Octave


From: John W. Eaton
Subject: Re: API for Octave
Date: Wed, 22 Apr 1998 11:45:37 -0500 (CDT)

On 22-Apr-1998, Haisam K. Ido <address@hidden> wrote:

| Is there a way to call the different octave functions without being at the
| octave command line.  What if I wanted to call octave's fft within a C
| program, how would I do that without doing a system call?

Octave is written in a combination of C++, C, and Fortran.  Calling
the C++ parts from C would probably lead to problems.  If you are
using C++, you can call any of the functions in the liboctave library
fairly easily, but currently it works best if you are creating .oct
files, not standalone applications.  For the FFT example you mention,
would just be something like:

  #include appropriate headers

  Matrix m (n, m);

  // fill in values for m.

  ComplexMatrix result = m.fourier ();

Take a look at the Octave source for other examples.

jwe



reply via email to

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