[Top][All Lists]

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

Re: Building Standalone Executables

From: Carlo de Falco
Subject: Re: Building Standalone Executables
Date: Sat, 13 Feb 2010 10:14:11 +0100

On 13 Feb 2010, at 01:37, Tim Felty wrote:


I am trying to build a standalone executable that makes use of Octave's computational routines.

I have looked at the manual and have built the simple example and had it work fine. However, I haven't been able to find any guide that describes anything more complex than creating matrices within a standalone app.

My code currently looks like this:

#include <iostream>
#include <octave/oct.h>

using namespace std;

    cout << "Hello Octave world! This is a test\n";
    int size;
    cin >> size;
 Matrix a_matrix = Matrix(1,size);
 Matrix b_matrix = Matrix(1,size);
 Matrix c_matrix = Matrix(1,size);
 for (int column = 0; column < size; ++column)
  a_matrix(column) = (column + 1);
  b_matrix(column) = column*3 + 2;
 c_matrix = a_matrix + b_matrix;
 cout << a_matrix;
 cout << b_matrix;
 cout << c_matrix;

// could not find infomration on how to use the Octave griddata function
 // or any Octave function from within C++
 double zi = griddata(a_matrix, b_matrix, c_matrix, 1, 3);


    return 0;

Any links to guides or just direct help would be appreciated.

look at the folder 'examples' in the octave sources

reply via email to

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