﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
4729	The NF causes vector assignment of discrete variables to functions to look like implicit systems of equations	Francesco Casella	Per Östlund	"Many models in the MSL (e.g. [https://libraries.openmodelica.org/branches/newInst/Modelica_3.2.2/files/Modelica_3.2.2_Modelica.Blocks.Examples.NoiseExamples.Distributions.err Modelica.Blocks.Examples.NoiseExamples.Distributions]) fail when compiled with the NF because of this kind of error:
{{{
[OpenModelica/OMCompiler/Compiler/BackEnd/BackendDAETransform.mo:307:7-307:48:writable]
Error: Internal error BackendDAETransform.analyseStrongComponentBlock failed 
(Sorry - Support for Discrete Equation Systems is not yet implemented)
$PRE.uniformNoise.state[2]
$PRE.uniformNoise.state[1]
$PRE.uniformNoise.state[4]
$PRE.uniformNoise.state[3]
$PRE.uniformNoise.state = Modelica.Math.Random.Utilities.initialStateWithXorshift64star(uniformNoise.localSeed, uniformNoise.actualGlobalSeed, 4)
}}}

The flattened model with the old FE contains this equation
{{{
  {pre(uniformNoise.state[1]), pre(uniformNoise.state[2]), pre(uniformNoise.state[3]), pre(uniformNoise.state[4])} = Modelica.Math.Random.Generators.Xorshift128plus.initialState(uniformNoise.localSeed, uniformNoise.actualGlobalSeed);
}}}
while the new FE reports this
{{{
pre(uniformNoise.state) = Modelica.Math.Random.Generators.generator.initialState(uniformNoise.localSeed, uniformNoise.actualGlobalSeed);
}}}
Apparently, there is some issue with the DAEs returned by the NF that makes an explicit vector assignment erroneously look like an implicit system of equations, which the backend cannot (and should not, in this case) handle."	defect	closed	high	2.0.0	New Instantiation		fixed		
