.AixLib.Utilities.Math.Functions.round

Information

Overview

<

This function is there to round values. Same as Modelica.Blocks.Nonlinear.VariableLimiter but it's a function.

Known Limitations

The precision should not be set higher than 3 or 4 digits, otherwise simulation time will increase significantly.

Concept

Rounding real input signals to the given number of digits after the decimal point. The output is a real. This function may be used in conjunction with lookup tables that must not be interpolatated. The table data must then be provied with the set precision.

Interface

function round
  input Real u;
  input Integer digits;
  output Real y;
end round;

Revisions


Generated at 2024-04-28T18:16:21Z by OpenModelicaOpenModelica 1.22.3 using GenerateDoc.mos