Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
6.1.1 - English

Change language to:
Français - 日本語 - Português - Русский

Please note that the recommended version of Scilab is 2025.0.0. This page might be outdated.
See the recommended documentation of this function

Scilab Help >> Polynomials > polfact

polfact

minimal real factors of a polynomial

Syntax

f = polfact(p)

Arguments

p

polynomial with real coefficients.

f

row vector [f0 f1 ... fn] of polynomials with real coefficients, such that p=prod(f). f0=f(1) is a constant polynomial. f(2:$) are polynomials of degree 1 or 2.

The coefficients of f polynomials are computed with a relative uncertainty of %eps1/degree(p).

Examples

x = poly(0,"x");
%eps^[1/3 1/7]

p = (1-x)^3
f = polfact(p)'
prod(f)

p = (1+x)^7
f = polfact(p)'
prod(f)
--> %eps^[1/3 1/7]
 ans  =
   0.0000061   0.0058047

--> p = (1-x)^3
 p  =
  1 -3x +3x² -x³

--> f = polfact(p)'
 f  =
  -1
  1.0000086 -2.0000086x +x²
  -0.9999914 +x

--> prod(f)
 ans  =
  1 -3x +3x² -x³


--> p = (1+x)^7
 p  =
  1 +7x +21x² +35x³ +35x⁴ +21x⁵ +7x⁶ +x⁷

--> f = polfact(p)'
 f  =
  1
  1.0092002 +x
  1.0114552 +2.011371x +x²
  0.9959088 +1.9958255x +x²
  0.9836859 +1.9836034x +x²

--> prod(f)
 ans  =
  1 +7x +21x² +35x³ +35x⁴ +21x⁵ +7x⁶ +x⁷

See also

  • factors — factorization in ℝ of a polynomial or a rational fraction
  • roots — roots of a polynomial
  • lcm — least common (positive) multiple of integers or of polynomials
  • cmndred — common denominator form
Report an issue
<< pol2str Polynomials poly >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Mon Jan 03 14:23:25 CET 2022