der_p = Polynomial.derivative(p);
Define a polynomial der_p
being a first partial derivative of
the polynomial p
.
import Modelica_LinearSystems2.Math.Polynomial; x = Polynomial.x(); p1 = -6*x^2 + 4*x -3; der_p = Polynomial.derivative(p1); // -12*x + 4
Polynomial.integral, Polynomial.derivativeValue.
encapsulated function derivative import Modelica_LinearSystems2.Math.Polynomial; input Polynomial p; output Polynomial der_p(redeclare Real c[size(p.c, 1) - 1]) "Derivative of Polynomial p"; end derivative;