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

Re: [Orekit Users] orekit-7.0 called from matlab



If I want to use the propagator in MasterMode or any of the event detections such as eclipse detection, I am wondering if it is possible from within Matlab.  I have not had a lot of success figuring out how to handle the event handlers from within Matlab and I note that the examples avoid such.  I am using the TLE propagator.  I am thinking it will be necessary for me to learn some more java and write a wrapper program in java to pass the results back to Matlab.  Any thoughts to the contrary?

Cheers,
Ryan


From: Ryan Shepperd <ryan_shepperd@yahoo.com>
To: "orekit-users@orekit.org" <orekit-users@orekit.org>
Sent: Wednesday, February 4, 2015 8:41 PM
Subject: Re: [Orekit Users] orekit-7.0 called from matlab

Christophe, thanks.  In hindsight, I should have clued in to the fact that a previous getInstance error had gone away.  Orekit 7 seems to be working fine from Matlab.  Along with Rami's ISSTracker example, the following was a good resource for learning what some of Matlab's cryptic errors could really mean: http://undocumentedmatlab.com/blog/java-class-access-pitfalls 

Ryan




From: Christophe LE BRIS <chris.lebris@gmail.com>
To: Ryan Shepperd <ryan_shepperd@yahoo.com>
Cc: "orekit-users@orekit.org" <orekit-users@orekit.org>
Sent: Monday, February 2, 2015 1:54 AM
Subject: Re: [Orekit Users] orekit-7.0 called from matlab

Hello,

The method getITRF2005 is no more available in Orekit 7 API (was deprecated in 6.1). The new method is "getITRF".

Christophe



----- Original Message -----
From: Ryan Shepperd <ryan_shepperd@yahoo.com>
Sent: 02/02/2015 - 04:04
To: Rami Houdroge <rami.houdroge@hotmail.com>
Subject: Re: [Orekit Users] orekit-7.0 called from matlab

> Rami,
> Thank you for checking.  Yes, I had made the change on line 142 and placed orekit-7.0.jar in the expected lib directory, and restarted matlab (to be sure the orekit-6.0 instance was gone).  I have the error pasted below, but I am running matlab R2014b on a slightly older version of MacOS (Darwin Kernel Version 11.4.2).  I do have access to the current version of matlab on Windows and the current and earlier versions on Linux, so I will check those out tomorrow and see if my inability to use orekit-7.0 within matlab is limited to an OS or matlab version as it sounds like it must.
> Cheers,Ryan
>
>    Retrieving ISS Orbital Data...
> The class org.orekit.frames.FramesFactory has no property or method named 'getITRF2005'.
>
> Error in getPropagator (line 68)
> orekitData.frames.ITRF2005 = FramesFactory.getITRF2005(false);
>
>
> Error in ISSTracker>main (line 203)
>         propagator = getPropagator(p, v, iD);
>
> Error in ISSTracker>ISSTracker_OpeningFcn (line 163)
> main(hObject, handles)
>
> Error in gui_mainfcn (line 220)
>     feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
>
> Error in ISSTracker (line 110)
>         gui_mainfcn(gui_State, varargin{:});
>
> Error in ISSTracker>warndlgCallback (line 119)
> ISSTracker;
>  
> Error while evaluating DestroyedObject Callback
>
>
>      From: Rami Houdroge <rami.houdroge@hotmail.com>
>  To: "ryan_shepperd@yahoo.com" <ryan_shepperd@yahoo.com>
> Cc: "orekit-users@orekit.org" <orekit-users@orekit.org>
>  Sent: Sunday, February 1, 2015 4:05 PM
>  Subject: RE: [Orekit Users] orekit-7.0 called from matlab
>
> <!--#yiv6245305787 .yiv6245305787hmmessage P{margin:0px;padding:0px;}#yiv6245305787 body.yiv6245305787hmmessage{font-size:12pt;font-family:Calibri;}-->Hi Ryan,



>
> For ISSTracker, loading Orekit 7.0 instead of 6.1 works well for me. The errors you mentioned don't occur. I'm using R2013a.
>
> Question : when you replaced the jar file, did you also change the ISSTracker.m script (line 142) ? You should tell it to load the new jar file.
>
> Note : You can also load Orekit into Matlab at startup. This means you won't have to tell Matlab to load the jar manually (javaaddpath). This is done by :
> - adding the jar file to the jarext folder 'Matlab root'/java/jarext
> - adding the jar path to the classpath located at 'Matlab root'/toolbox/local/classpath.txt
>
> Cheers,
>
> Rami
>
>
> From: chris.lebris@gmail.com
> Date: Wed, 28 Jan 2015 12:24:23 +0100
> To: orekit-users@orekit.org
> Subject: Re: [Orekit Users] orekit-7.0 called from matlab
>
> Hello,
> I don't have R2014b but calling Orekit 7.0 from Matlab 2013a works well for me.
> Christophe
>
> 2015-01-28 9:59 GMT+01:00 Houdroge Rami (THALES SERVICES) <Rami.Houdroge@cnes.fr>:
>
> Hi Ryan,
>
> I will look into upgrading ISSTracker to orekit 7.0 and will get back to you.
>
> Cheers,
>
> Rami Houdroge
>
>
> -----Original Message-----
> From: orekit-users-request@orekit.org [mailto:orekit-users-request@orekit.org] On Behalf Of ryan_shepperd@yahoo.com
> Sent: mercredi 28 janvier 2015 05:00
> To: orekit-users@orekit.org
> Subject: [Orekit Users] orekit-7.0 called from matlab
>
> I was trying to explore possible uses of orekit from within matlab but ran into problems trying to use the advice at https://www.orekit.org/forge/projects/orekit/wiki/Integration_in_Matlab with orekit-7.0.jar and Matlab R2014b.  I get errors like
>
> Undefined variable "DataProvidersManager" or class "DataProvidersManager.getInstance".
>
> I am able to load and use orekit-6.0.jar using or following the example of "http://www.mathworks.com/matlabcentral/fileexchange/42733-isstracker-v1-0-0",
> which uses orekit-6.0.   Replacing orekit-6.0 with orekit-7.0 in isstracker
> resulted in the same error I have been encountering, so there seems to be something different that one must do to successfully load orekit-7.0 classes into matlab.
>
> I am happy I at least gained access to orekit-6.0 from within matlab.  I can at least take a look at the possibilities and maybe start to learn why my
> orekit-7.0 efforts failed.  However, I am very curious if anyone out there has been able to use orekit-7.0 from within a recent version of matlab.
>
>
>
>