.Modelica_LinearSystems2.Math.Polynomial.plot

Information

Syntax

Polynomial.plot(
  p, nPoints, autoLabel, xLabel, yLabel, autoRange, x_min, x_max);

Description

Plot the given polynomial. If default arguments are used, as in:

import Modelica_LinearSystems2.Math.Polynomial;

p = Polynomial({1,2,3});
Polynomial.plot(p);

then the abszissa range is determined in such a way that all roots (i.e., p(x) = 0) and all extrema (i.e, dp(x) = ∂p/∂x = 0) are in the plotted range. As default legend, the String representation of the polynomial is used as generated by operator-'String' function (called by String(p)).

Interface

encapsulated function plot
  import Modelica;
  import DymolaCommands.Plot;
  import Modelica_LinearSystems2.Math.Polynomial;
  import Modelica.Utilities.Strings;
  import Complex;
  input Polynomial p "Polynomial to be plotted";
  input Integer nPoints(min = 2) = 200 "Number of points";
  input Boolean autoLabel = true "True, if automatically selected labels";
  input String xLabel = "" "Abszissa description, if autoLabel = false";
  input String yLabel = "" "Ordinate description, if autoLabel = false";
  input Boolean autoRange = true "True, if abszissa range is automatically determined";
  input Real x_min = -1.0 "Minimum abszissa value, if autoRange = false";
  input Real x_max = 1.0 "Maximum abszissa value, if autoRange = false";
end plot;

Generated at 2024-12-17T19:26:02Z by OpenModelicaOpenModelica 1.24.3 using GenerateDoc.mos