On 01/26/2017 08:50 AM, Brad Bell wrote:
In python, numpy will provide matrix operations for overloaded types.
This worked for AD matrix operations; see
http://www.seanet.com/~bradbell/pycppad/pycppad.htm
Is there a package, similar to numpy, that works for Octave ?
In Matlab, you can create a function like this (the @double directory
needs to be somewhere in your MATLABPATH):
@double/mtimes.m:
function r = mtimes (x, y)
fprintf ('my mtimes!\n');
r = builtin ('mtimes', x, y);
end
to overload the builtin mtimes function that is called for the syntax
"x * y" when x and y are double precision numeric objects (that
includes sparse and complex). You'd need a separate definition for
single.
Is that what you are looking for?
The overloading feature is not yet implemented in Octave for built-in
types like double and single.
jwe