octave-maintainers
[Top][All Lists]
Advanced

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

Re: 1D PDE solver for Octave


From: Carlo De Falco
Subject: Re: 1D PDE solver for Octave
Date: Mon, 4 Jul 2016 22:58:35 +0000

On 30 Jun 2016, at 15:54, Carlo De Falco <address@hidden> wrote:

>> I am using the C API to ida; my code is written in C++.
> 
> This is the same approach Franceso is using in ode15i/ode15s.


I stand corrected. 

Looking at your code I see it is in C++ but it is using the Matlab compatible
MEX API (which is a C API).

This is not what Francesco has been doing. 
Francesco is using the Octave C++ API:

https://www.gnu.org/software/octave/doc/interpreter/Oct_002dFiles.html#Oct_002dFiles

"Oct-files are pieces of C++ code that have been compiled with the Octave API 
into a dynamically loadable object. They take their name from the file which 
contains the object which has the extension .oct."

The latter is known to be much more efficient.

Apart from that there is not much more I can comment.

Actually whithout a working Makefile and whithout one single line of 
documentation,
not even a docstring describing input syntax, I sincerely doubt you will ever 
find anyone 
willing to spend more time looking at your code.

Can you provide a least one usage example?
What class of problems can your code solve?
How would you invoke your function?


For example, the attached file shows how to add a docstring and a demo
to your function. Type "help parabolic1d" to see the help and type
"demo parabolic1d" to see the code of the demo and the resulting plot.


c.





reply via email to

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