Method of mdss.
Evaluate the model’s equations at given signal values.
Source: src/model/@mdss/functionValue.m
functionValues = functionValue(sys, stateDeltaVector, stateVector, inputVector, algebraicVector, binaryVector)functionValue evaluates every equality and inequality
equation of the model at the supplied signal values. Each equation row
is a multilinear expression in the signals
,
and functionValue returns the vector of those values, one
per equation row of the parameter matrix.
The six signal vectors are placed into the full signal vector using
the model’s index vectors (stateDeltaIndex,
stateIndex, inputIndex,
algebraicIndex, binaryIndex) and the
evaluation is delegated to the underlying tensor. For a CPNTensor the
assembled signal vector is passed to computeFunctionValue;
for a TTTensor the
tensor-train path computeFunctionValueMdss
is used.
| Argument | Description |
|---|---|
sys |
The mdss model. |
stateDeltaVector |
State-derivative values
(nState entries). |
stateVector |
State values
(nState entries). |
inputVector |
Input values
(nInput entries). |
algebraicVector |
Algebraic values
(nAlgebraic entries). |
binaryVector |
Binary values
(nBinary entries; [] if none). |
| Output | Description |
|---|---|
functionValues |
Column vector, one entry per equation row: that row’s multilinear expression evaluated at the supplied values. |
sys = stringParser.symbolicToMdss(["0 = m*xp1 - y1 - u1"; ...
"0 = y1 - k*x1"], 0, ...
["xp","x","u","y","z"], ["m","k"], [1200, 3]);
% Residuals at xp1 = 0, x1 = 0, u1 = 1, y1 = 0 (no binaries)
fv = functionValue(sys, 0, 0, 1, 0, []);mdss · jacobian · incidenceMatrix
· msim · CPNTensor · TTTensor
MyToolbox Documentation | Generated automatically by CI/CD pipeline