[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mldivide function in C++ API
From: |
Pantxo |
Subject: |
Re: mldivide function in C++ API |
Date: |
Mon, 2 Jun 2014 05:47:59 -0700 (PDT) |
Hello,
Fmldivide expects and octave_value_list as input argument. The following
should work:
#include <octave/oct.h>
#include <octave/builtin-defun-decls.h>
DEFUN_DLD(test_mldiv, args, nargout, "\
test_mldiv\n\
")
{
octave_value_list retval;
octave_value_list input;
Matrix A = args(0).matrix_value ();
ColumnVector B = args(1).column_vector_value ();
if (! error_state)
{
input.append (A);
input.append (B);
retval = Fmldivide (input);
// Alternatively, use ovl (...) to build an octave_value_list in-place:
retval = Fmldivide (ovl (A, B));
}
return retval;
}
Does it work for you?
Pantxo
--
View this message in context:
http://octave.1599824.n4.nabble.com/mldivide-function-in-C-API-tp4664414p4664422.html
Sent from the Octave - General mailing list archive at Nabble.com.