Tool independent compute_global_A/B/C/D methods

4 posts / 0 new
Last post
hyumo
Offline
Joined: 2017-04-04
Tool independent compute_global_A/B/C/D methods

Hi PyFMI developers,

I am curious if PyFMI could remove tool dependent checks in some of its methods, for example, compute_global_A/B/C/D method in Master class. These methods first checks if a certain FMU is generated from Jmodelica.org, if not, then return none, which reduces the compatibilty of FMUs generated from other tools. I wonder if there's a place that we can submit pull requests for a fix.

Thanks,

HYu

chria
Offline
Joined: 2009-07-29
Hi, Which tool specific

Hi,

Which tool specific options/functionality are you refering to? Computation of the A/B matrices on the CS Master algorithm?

Best

/Christian

hyumo
Offline
Joined: 2017-04-04
Yes.  For example, the

Yes. 

For example, the generation_tool() check is found in the following lines while computing global_A/B/C matrix.

https://trac.jmodelica.org/browser/PyFMI/trunk/src/pyfmi/master.pyx#L579

https://trac.jmodelica.org/browser/PyFMI/trunk/src/pyfmi/master.pyx#L595

https://trac.jmodelica.org/browser/PyFMI/trunk/src/pyfmi/master.pyx#L611

It is possible to use the _get_support_directional_derivatives check instead? Thanks a lot for the help.

Best,

HYu

chria
Offline
Joined: 2009-07-29
Hi,   I see. Removing these

Hi,

 

I see. Removing these are however problematic. When considering the FMI specification I don't believe that in the Co-Simulation case it is necessary to expose the states and state derivatives. These are needed in order to compute the A and B matrix. I believe though that we can possibly add a more relaxed test that check if they are available or not (irregardless if it is a JM FMU or not). I'll look into it.

 

Best

/Christian

Login or register to post comments