Opened 8 years ago
Closed 8 years ago
#4261 closed task (invalid)
No viable alternative near token: =
Reported by: | Owned by: | somebody | |
---|---|---|---|
Priority: | high | Milestone: | Future |
Component: | *unknown* | Version: | |
Keywords: | Cc: |
Description
Hi, I an new to OpenModelica and I am just trying to solve 3 basic simultaneous equations. But it gives me the error as "No viable alternative near token: ="
Does anybody know what is the issue..??
package test
model sim_test
mod_test aaa;
Real _x; output
Real _y; output
Real _z; output
outputs
_x = aaa.x;
_y = aaa.y;
_z = aaa.z;
end sim_test;
model mod_test
output Real x;
output Real y;
output Real z;
equation
x + y + z = 6;
2*x - y - z = 0;
5*y + 2*z = 11;
end mod_test;
end test;
Change History (2)
comment:1 by , 8 years ago
comment:2 by , 8 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Please ask this kind of questions on our forum:
https://openmodelica.org/forum
or in the Modelica section on stackoverflow:
http://stackoverflow.com/questions/tagged/modelica
Learn the Modelica language a bit more. You need "equation" instead of "outputs".
More on Modelica:
https://openmodelica.org/useresresources/modelica-courses
http://book.xogeny.com/
Well, this is not really OpenModelica related...
Try this: