Skip to content

Commit

Permalink
Expected output for balance checking improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
sjoelund authored and OpenModelica-Hudson committed Aug 10, 2017
1 parent 2252051 commit ac5733a
Show file tree
Hide file tree
Showing 6 changed files with 63 additions and 0 deletions.
10 changes: 10 additions & 0 deletions simulation/modelica/connectors/HeatTank.mos
Expand Up @@ -18,5 +18,15 @@ getErrorString(); // simulation failed, check error string.
// messages = "Failed to build model: HeatTank"
// end SimulationResult;
// "Error: Too many equations, over-determined system. The model has 10 equation(s) and 8 variable(s).
// [simulation/modelica/connectors/HeatTank.mo:32:1-35:15:writable] Warning: Equation 9 (size: 1) inlet.volumeFlowRate = 0.0 is not big enough to solve for enough variables.
// Remaining unsolved variables are:
// Already solved: inlet.volumeFlowRate
// Equations used to solve those variables:
// Equation 4 (size: 1): inlet.volumeFlowRate = 1.0
// [simulation/modelica/connectors/HeatTank.mo:32:1-35:15:writable] Warning: Equation 10 (size: 1) outlet.volumeFlowRate = 0.0 is not big enough to solve for enough variables.
// Remaining unsolved variables are:
// Already solved: outlet.volumeFlowRate
// Equations used to solve those variables:
// Equation 8 (size: 1): outlet.volumeFlowRate = 2.0
// "
// endResult
12 changes: 12 additions & 0 deletions simulation/modelica/equations/DoubleWhenConflict.mos
Expand Up @@ -16,5 +16,17 @@ getErrorString(); // simulation failed, check error string.
// messages = "Failed to build model: DoubleWhenConflict"
// end SimulationResult;
// "Error: Too many equations, over-determined system. The model has 2 equation(s) and 1 variable(s).
// Warning: Equation 2 (size: 1) algorithm
// when x <= 5.0 then
// close := false;
// end when;
// is not big enough to solve for enough variables.
// Remaining unsolved variables are:
// Already solved: close
// Equations used to solve those variables:
// Equation 1 (size: 1): algorithm
// when x >= 5.0 then
// close := true;
// end when;
// "
// endResult
27 changes: 27 additions & 0 deletions simulation/modelica/equations/IfEquationUnbalanced.mos
Expand Up @@ -19,12 +19,39 @@ simulate(IfEquationUnbalancedMissingElse); getErrorString();
// messages = "Failed to build model: IfEquationUnbalanced"
// end SimulationResult;
// "Error: Too few equations, under-determined system. The model has 1 equation(s) and 2 variable(s).
// [simulation/modelica/equations/IfEquationUnbalanced.mo:13:3-13:12:writable] Warning: Variable x does not have any remaining equation to be solved in.
// The original equations were:
// Equation 1: if x < 1.0 then
// x = time
// elseif x >= 1.0 then
// y = 2.0
// x = 1.0
// else
// x = 2.0 * time
// end if, which needs to solve for y
// "
// record SimulationResult
// resultFile = "",
// simulationOptions = "startTime = 0.0, stopTime = 1.0, numberOfIntervals = 500, tolerance = 1e-06, method = 'dassl', fileNamePrefix = 'IfEquationUnbalancedMissingElse', options = '', outputFormat = 'mat', variableFilter = '.*', cflags = '', simflags = ''",
// messages = "Failed to build model: IfEquationUnbalancedMissingElse"
// end SimulationResult;
// "Error: Too few equations, under-determined system. The model has 0 equation(s) and 2 variable(s).
// [simulation/modelica/equations/IfEquationUnbalanced.mo:4:3-9:9:writable] Warning: Equation 1 (size: 0) if x < 1.0 then
// x = time
// elseif x >= 1.0 then
// y = 2.0
// x = 1.0
// end if is not big enough to solve for enough variables.
// Remaining unsolved variables are: y
// Already solved: x
// Equations used to solve those variables:
// [simulation/modelica/equations/IfEquationUnbalanced.mo:2:3-2:12:writable] Warning: Variable x does not have any remaining equation to be solved in.
// The original equations were:
// Equation 1: if x < 1.0 then
// x = time
// elseif x >= 1.0 then
// y = 2.0
// x = 1.0
// end if, which needs to solve for y,
// "
// endResult
3 changes: 3 additions & 0 deletions simulation/modelica/equations/ModelBalance2.mos
Expand Up @@ -16,5 +16,8 @@ simulate(ModelBalance2);getErrorString();
// messages = "Failed to build model: ModelBalance2"
// end SimulationResult;
// "Error: Too few equations, under-determined system. The model has 1 equation(s) and 2 variable(s).
// [simulation/modelica/equations/ModelBalance2.mo:9:3-9:12:writable] Warning: Variable x does not have any remaining equation to be solved in.
// The original equations were:
// Equation 1: y = 2 + x, which needs to solve for y
// "
// endResult
6 changes: 6 additions & 0 deletions simulation/modelica/equations/ModelBalance3.mos
Expand Up @@ -18,5 +18,11 @@ getErrorString();
// messages = "Failed to build model: ModelBalance3"
// end SimulationResult;
// "Error: Too many equations, over-determined system. The model has 3 equation(s) and 2 variable(s).
// [simulation/modelica/equations/ModelBalance3.mo:14:3-14:12:writable] Warning: Equation 3 (size: 1) x = 2 + y is not big enough to solve for enough variables.
// Remaining unsolved variables are:
// Already solved: x, y
// Equations used to solve those variables:
// Equation 1 (size: 1): x = 2
// Equation 2 (size: 1): y = 2 + x
// "
// endResult
5 changes: 5 additions & 0 deletions simulation/modelica/equations/ModelBalance4.mos
Expand Up @@ -26,5 +26,10 @@ simulate(ModelBalance4); getErrorString();
// messages = "Failed to build model: ModelBalance4"
// end SimulationResult;
// "Error: Too many equations, over-determined system. The model has 3 equation(s) and 2 variable(s).
// [<interactive>:7:3-7:13:writable] Warning: Equation 3 (size: 1) b = 2.0 + time is not big enough to solve for enough variables.
// Remaining unsolved variables are:
// Already solved: b
// Equations used to solve those variables:
// Equation 1 (size: 1): b = 2.0
// "
// endResult

0 comments on commit ac5733a

Please sign in to comment.