**Package: **sdo.requirements

**Superclasses: **

Impose function matching constraint on variable

Use the `sdo.requirements.FunctionMatching`

object
to impose a function matching constraint on the values of a variable
in a Simulink^{®} model. The variable can be a vector, matrix, or
a multidimensional array that is a parameter in your model, such as
the data of a lookup table in your model. You create the requirement
object, and specify the linear or quadratic function that you want
the variable to match. For example, for a two-dimensional variable,
you can specify that test data from dependent variable `V`

match
a linear function of independent variables `X`

and _{1}`X`

:_{2}

$$V={a}_{0}+{a}_{1}{X}_{1}+{a}_{2}{X}_{2}$$

Where, `a`

, _{0}`a`

,
and _{1}`a`

are the fit-coefficients,
and _{2}`X`

and _{1}`X`

are
vectors._{2}

You use the `evalRequirement`

method to evaluate
whether your test data satisfies the specified requirement, and specify
the independent variable vectors as inputs to the method. The software
calculates the fit-coefficients using the independent variables and
test data and then calculates the error between the test data and
the specified function of the independent variables.

You can use the requirement object as an input to your cost function and
use the `evalRequirement`

command in the cost function
to evaluate the requirement. You can then use the cost function and `sdo.optimize`

to perform response optimization,
subject to satisfaction of the specified requirement. If you are performing
sensitivity analysis, after you generate parameter samples, you can
use the cost function and `sdo.evaluate`

to
evaluate the requirement for each generated sample.

creates an `requirement`

=
sdo.requirements.FunctionMatching`sdo.requirements.FunctionMatching`

requirement object and
assigns default values to its properties. Use dot notation to customize the properties.
Use the `evalRequirement`

command to evaluate whether test data
satisfies the specified requirement.

creates the requirement object with additional options specified by one or more
`requirement`

= sdo.requirements.FunctionMatching(`Name,Value`

)`Name,Value`

pair arguments. `Name`

is a property name and
`Value`

is the corresponding value. `Name`

must
appear inside single quotes (`''`

). You can specify several name-value
pair arguments in any order as `Name1,Value1,...,NameN,ValueN`

.

Specify optional
comma-separated pairs of `Name,Value`

arguments. `Name`

is
the argument name and `Value`

is the corresponding value.
`Name`

must appear inside quotes. You can specify several name and value
pair arguments in any order as
`Name1,Value1,...,NameN,ValueN`

.

Use `Name,Value`

arguments to specify properties of the
requirement object during object creation. For example, ```
requirement
= sdo.requirements.FunctionMatching('Type','quadratic')
```

creates
an `sdo.requirements.FunctionMatching`

object
and specifies the function to be matched as quadratic.

evalRequirement | Evaluate satisfaction of function matching requirement |

Handle. To learn how handle classes affect copy operations, see Copying Objects (MATLAB).