math_polynom_from_roots: Compute polynomial from roots

View source: R/math.R

math_polynom_from_rootsR Documentation

Compute polynomial from roots

Description

The polynomial will be calculated according to the roots supplied in the list. If roots are complex it will also include the complex conjugated root. The resulting polynomial will be rounded according to round_digits.

Usage

math_polynom_from_roots(roots, round_digits = 9)

Arguments

roots

list of roots

round_digits

the number of digit used to round the polynomial coefficients

Value

polynomial character string

Author(s)

Florian Wagner florian.wagner@wagnius.ch

Examples

c(-5,0,2i)|>math_polynom_from_roots()
c(-5,0,2i,-2i)|>math_polynom_from_roots()
c(3,2+1i)|>math_polynom_from_roots()
c(3,2+1i,2-1i)|>math_polynom_from_roots()

wagnius-GmbH/slvwagner documentation built on Jan. 19, 2025, 7:10 a.m.