Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register
  • Index
  • » Users
  • » ara
  • » Profile

Posts

Posts

Aug-02-14 06:21:12
Category: Developer

Hi,

Trying to simulate a model which worked perfectly using Dymola, I got the error:
Divide by zero
:

equation
  der(H3) = omega;
  der(H2) = Vx * Modelica.Math.sin(theta)+ X * Modelica.Math.cos(theta) * omega;
  der(H1) = Vx* Modelica.Math.cos(theta)+ X * Modelica.Math.sin(theta) * omega;
  Vx = Y * omega;
  Vy = - omega * X ;

  der(theta) = (-Vx) / X;
  der(X) = Modelica.Math.cos(theta) * Vx- Modelica.Math.sin(theta) * Vy;
  der(Y) = Modelica.Math.sin(theta) * Vx+ Modelica.Math.cos(theta) * Vy;
  (-Modelica.Math.sin(theta) * der(X)) + X * der(theta) = 0;

Aug-02-14 00:12:33
Category: Programming

Hi,

Trying to simulate a model which worked perfectly using Dymola, I got the error:
Divide by zero
:

equation
  der(H3) = omega;
  der(H2) = Vx * Modelica.Math.sin(theta)+ X * Modelica.Math.cos(theta) * omega;
  der(H1) = Vx* Modelica.Math.cos(theta)+ X * Modelica.Math.sin(theta) * omega;
  Vx = Y * omega;
  Vy = - omega * X ;

  der(theta) = (-Vx) / X;
  der(X) = Modelica.Math.cos(theta) * Vx- Modelica.Math.sin(theta) * Vy;
  der(Y) = Modelica.Math.sin(theta) * Vx+ Modelica.Math.cos(theta) * Vy;
  (-Modelica.Math.sin(theta) * der(X)) + X * der(theta) = 0;

end AUT;

  • Index
  • » Users
  • » ara
  • » Profile
You are here: