Topic
4 replies Latest Post - ‏2012-12-24T09:18:49Z by SystemAdmin
RVSA_Mohammad_Mozumdar
4 Posts
ACCEPTED ANSWER

Pinned topic Interfacing with Matlab/Maxima to evaluate parametric functions

‏2011-02-27T06:45:08Z |
We are exploring the PCE(Parametric Constraints Evaluator) examples that come with the Rhapsody 7.5.3 (especially the PowerSubsystem model). We setup the PCE for Matlab from Tools-> “PCE Environment Settings” and followed the instructions to configure Matlab (R2009b) such as
Adding following line in the classpath.txt file
win64=C:\Users\most\IBM\Rational\Rhapsody\7.5.3\Share\Profiles\PCE\matlab\pcenet.jar

and also “set path” to the C:\Users\most\IBM\Rational\Rhapsody\7.5.3\Share\Profiles\PCE\matlab

After setting PCE and successfully compiling the model, if we try to open the ConstraintViews to “evaluate” the parametric function, the system crashes and logs are followings..

PCE Plug-in Fatal error: Terminate command failed
java.io.IOException: An existing connection was forcibly closed by the remote host
Please reopen the Rhapsody project to continue.

We tried to change the PORT at PCE Environment Settings but the result is same!! Afterwards we installed Maxima but the same thing happened.

We might have missed something.. If anybody have some clue, it would be great..
BTW, We are using Rhapsody in windows 7 (64bit) version.

Thanks,
Mostafiz
Updated on 2012-12-24T09:18:49Z at 2012-12-24T09:18:49Z by SystemAdmin
  • Eldad Palachi
    Eldad Palachi
    7 Posts
    ACCEPTED ANSWER

    Re: Interfacing with Matlab/Maxima to evaluate parametric functions

    ‏2011-02-27T15:08:52Z  in response to RVSA_Mohammad_Mozumdar
    Hi Mostafiz,

    We have checked PCE on Windows 7 64 bit using MAXIMA, unfortunatley we cannot check it with MATLAB R2009.
    According to our tests it works fine.

    I recommend you open a support call and attach your model as well as a screenshot of you settings dialogs.
    In addition, please mention the Java version you are using.

    Thanks,

    Eldad
    • RVSA_Mohammad_Mozumdar
      4 Posts
      ACCEPTED ANSWER

      Re: Interfacing with Matlab/Maxima to evaluate parametric functions

      ‏2011-02-28T23:47:58Z  in response to Eldad Palachi
      Hi Eldad,
      Thanks for your reply. I am using JDK 1.6.0_23 and the version of MAXIMA is 5.23.2

      From the PCE Environment setting, we selected MAXIMA and browse the path for it (C:\Program Files (x86)\Maxima-5.23.2\lib\maxima\5.23.2\binary-gcl\maxima.exe). Then I click OK, and then immediately it freezes. When I would like to close Rhapsody after waiting substantial amount of time, A windows dialog box opens noting “Rhapsody MFC application is not responding” (Please see the attachment).
      Then I click on restore, I found following in the log of Rhapsody..

      PCE Plug-in Fatal error: Set command failed
      java.io.IOException: An existing connection was forcibly closed by the remote host
      Please reopen the Rhapsody project to continue.

      Any clue, why Rhapsody MFC application is not responding?

      Thanks,
      Mostafiz
    • RVSA_Mohammad_Mozumdar
      4 Posts
      ACCEPTED ANSWER

      Re: Interfacing with Matlab/Maxima to evaluate parametric functions

      ‏2011-06-13T23:54:26Z  in response to Eldad Palachi
      Hi Eldad,
      Thanks for your reply. BTW, do you know what is the cause of having following message in "pce.err" file..

      Exception in thread "main" com.telelogic.rhapsody.core.RhapsodyRuntimeException: Can't Query Interface object for IRPApplication
      at com.telelogic.rhapsody.core.RhapsodyAppServer.getActiveRhapsodyApplication(Native Method)
      at com.ibm.rhapsody.pce.Main.main(Main.java:263)
      Thanks,
      Mostafiz

      PS: My SysML Rhapsody project just hangs because of this bug..
  • SystemAdmin
    SystemAdmin
    1305 Posts
    ACCEPTED ANSWER

    Re: Interfacing with Matlab/Maxima to evaluate parametric functions

    ‏2012-12-24T09:18:49Z  in response to RVSA_Mohammad_Mozumdar
    It looks like a Java API issue, and we don't have enough info to investigate.
    You can tell the customer to do the following, it might help.
    1) For some reason it could be that the registration of Rhapsody as a COM server, failed during installation (could be due to OS permissions). The user can simple register Rhapsody by doing the follow
    - Open a Command DOS window
    - Goto the location of the Rhapsody installation root directory (where the 'Rhapsody.exe' resides in)
    - type 'regsvr32 RhapsodyServer.dll'
    This operation should cause a small popup after a few seconds indicating that the registration passed successfully. If not there is some OS permission which is blocking the user to do this operation, and therefore suggested to speak with system admin, or login as an admin and then do the above.

    2) If the above passed ok, and it doesn't help, please do the following
    - Open the 'rhapsody.ini' file (resides in the same directory of Rhapsody.exe)
    - under the 'General' section add this flag 'JavaAPILogFile=C:\tmp\javaAPI.log', the log file can be anywhere, and an be called anything (i just gave an example)
    next, run the scenario, exit Rhapsody, and send us the log file.