WOLFRAM SYSTEM MODELER

regSquare

Anti-symmetric square approximation with non-zero derivative in the origin

Wolfram Language

In[1]:=
SystemModel["Modelica.Fluid.Utilities.regSquare"]
Out[1]:=

Information

This information is part of the Modelica Standard Library maintained by the Modelica Association.

This function approximates x^2*sgn(x), such that the derivative is non-zero in x=0.

FunctionApproximationRange
y = regSquare(x)y ~= x^2*sgn(x)abs(x) >>delta
y = regSquare(x)y ~= x*deltaabs(x) << delta

With the default value of delta=0.01, the difference between x^2 and regSquare(x) is 41% around x=0.01, 0.4% around x=0.1 and 0.005% around x=1.

Syntax

y = regSquare(x, delta)

Inputs (2)

x

Type: Real

delta

Default Value: 0.01

Type: Real

Description: Range of significant deviation from x^2*sgn(x)

Outputs (1)

y

Type: Real

Revisions