functionsmoothHeaviside
Twice continuously differentiable approximation to the Heaviside function
Extends from Modelica.Icons.Function (Icon for functions).
Information
Twice Lipschitz continuously differentiable approximation to the
Heaviside(.,.) function.
Function is derived from a quintic polynomial going through (0,0) and (1,1),
with zero first and second order derivatives at those points.
See Example
Buildings.Utilities.Math.Examples.SmoothHeaviside.
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| Real | x | Argument | |
| Real | delta | Parameter used for scaling |
Outputs
| Type | Name | Default | Description |
|---|---|---|---|
| Real | y | Result |
Revisions
-
July 21, 2025 by Hongxiang Fu:
Made the function inlined.
This is for #4278. -
October 21, 2019:
Addeddelta.minattribute to guard against division by zero.
This is for issue 1202. -
September 13, 2019, by Kristoff Six and Filip Jorissen:
Once continuously differentiable replaced by twice continuously differentiable implementation. This is for issue 1202. -
March 15, 2016, by Michael Wetter:
ReplacedspliceFunctionwithregStep. This is for issue 300. -
July 17, 2015, by Marcus Fuchs:
Add link to example. -
February 5, 2015, by Filip Jorissen:
AddedsmoothOrder = 1. -
July 14, 2010, by Wangda Zuo, Michael Wetter:
First implementation.