help-octave
[Top][All Lists]
Advanced

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

Re: Invoking MATLAB class constructor


From: Kai Torben Ohlhus
Subject: Re: Invoking MATLAB class constructor
Date: Tue, 18 Dec 2018 11:09:47 +0100

On Mon, Dec 17, 2018 at 11:02 PM Colin Kikuchi <address@hidden> wrote:
Hello,
I am trying to adapt a program called MAxSym, developed in MATLAB, to run in Octave. Part of the program involves calling a class to create an object. For example I am attaching 'Model.m', which is how you create the object.

I have looked through some of the online Octave documentation and can't determine whether this is supported in Octave, and if so, what is the correct syntax that I should use to invoke the class constructor?

Thank you!

-Colin


Dear Colin,

The Octave and Matlab syntax to create an object of your class "Model" is:

   >> obj = Model()

but as your class "Model" is derived from the class "Check" from the package "MAxSym", Octave complains that is has no such class definition:

   error: class not found: MAxSym.Check


What Octave supports about classdef classes is documented here:


and here:


If you face further problems you can as for specific problems or error messages you get.

HTH,
Kai

reply via email to

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