- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » I cannot run examples in the...
I cannot run examples in the reference book/ users Guide
I cannot run examples in the reference book/ users Guide
Hi,
I am getting started with OpenModelica. I have installed the last version but since three days (!!!), I am not able to run the simplest examples in the reference book ( Peter Fritzson, Principles of Object-Oriented Modeling and Simulation with Modelica). In particaul, the following commands:
class HelloWorld
real x(start=1);
parameter Real a = 1;
equation
der(x)=-a*x;
end HelloWorld;
simulate(HelloWorld, stopTime = 2)
plot (x)
I always get this error:
Error occured building AST
Syntax Error
[<interactive>:7:1-7:8:writable] Error: Parser error: Unexpected token near: simulate (IDENT)
Please, does some body have an idea. I can't run neither examples in the Users' guide.
I am a former user of VBA and Matlab.
Windows 7
OpenModelica 1.8.0
Re: I cannot run examples in the reference book/ users Guide
How do you enter the commands and in what tool? If you enter the simulate and plot commands in the same command in OMNotebook/OMShell, note that you need a semicolon after the simulate command.
- sjoelund.se
- 1700 Posts
- Index
- » Usage and Applications
- » OpenModelica Usage and Applications
- » I cannot run examples in the...