AJP
AJP

Reputation: 28543

Plot 3D graph in OpenModelica?

I have written the LorenzaAttractor class and have successfully plotted y and z against x in 2D. Is it possible to plot this in 3D?

model LorenzAttractor
  parameter Real sigma = 10;
  parameter Real rho = 28;
  parameter Real beta = 8/3;
  Real x (start=1);
  Real y (start = 1);
  Real z (start = 1);
equation
  der(x) = sigma*(y-x);
  der(y) = x * (rho-z) - y;
  der(z) = x*y - beta*z;
end LorenzAttractor;

Lorenza Attractor plotting y and z against x

Upvotes: 2

Views: 282

Answers (1)

JKRT
JKRT

Reputation: 1207

Not in OMEdit as far as I am aware. However, one alternative is to use the.csv or .mat file and use some auxiliary tool such as GNUPlot or some other plotting tool.

You can change the output here: enter image description here

The resulting file will be in the working directory of OMEdit: enter image description here

Upvotes: 1

Related Questions