Opened 15 years ago

Last modified 12 years ago

#1214 closed defect

Simple Diode Circuit model Simulation gives wrong simulation results. Dymola correct result included. — at Version 2

Reported by: oscarperez Owned by: oscarperez
Priority: critical Milestone:
Component: Simulation Code Generation Version: 1.5.0RC3
Keywords: Cc: oscarperez

Description (last modified by Lennart Ochel)

I made a simple model of with a diode circuit. But when I try to simulate it, diode doesn't work (diode is always an open circuit). Am I doing something wrong?
I also test the same model on Dymola and it works correctly. This is a very simple model and I don't understand what is wrong with openmodelica.

model DiodeTest
  Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(V=10 , freqHz=1);
  Modelica.Electrical.Analog.Basic.Resistor resistor(R=1000);
  Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode(Vknee=0.7);
  Modelica.Electrical.Analog.Basic.Ground ground;
equation
  connect(idealDiode.n, resistor.p);
  connect(sineVoltage.p, idealDiode.p);
  connect(resistor.n, ground.p);
  connect(sineVoltage.n, ground.p);
end DiodeTest;

Attachments are images with the correct simulation result (Dymola) and the actual openmodelica simulation result. And also The onb model.

Kind Regards.

Change History (3)

by oscarperez, 15 years ago

onb file, And simulation images (correct result and openmodelica wrong result)

comment:1 by Martin Sjölund, 15 years ago

I'll confirm that the problem exists both for MSL2.2 and MSL3.1

comment:2 by Lennart Ochel, 12 years ago

Cc: oscarperez, → oscarperez
Description: modified (diff)
Note: See TracTickets for help on using tickets.