Testwiki:Reference desk/Archives/Mathematics/2021 May 9

From testwiki
Revision as of 17:16, 4 July 2022 by imported>Qwerfjkl (Subst signature (via WP:JWB))
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Template:Error:not substituted

{| width = "100%"

|- ! colspan="3" align="center" | Mathematics desk |- ! width="20%" align="left" | < May 8 ! width="25%" align="center"|<< Apr | May | Jun >> ! width="20%" align="right" |Current desk > |}

Welcome to the Wikipedia Mathematics Reference Desk Archives
The page you are currently viewing is a transcluded archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


May 9

Deriving polynomial coefficients "synthetically"

Suppose you wanted to find the unknown coefficients the quadratic polynomial p(x) = Ax^2 + Bx + C, which happens to be 5x^2 + 13x^1 + 17. First, observe that the constant term C can be extracted by simply evaluating the polynomial at zero, ie: C = p(0) = 17. Furthermore, the sum of all coefficients is p(1) = 35 and the difference between even and odd terms of the polynomial given by p(-1) = 9. Remove the constant term from both to obtain the sum and difference of A and B, as in K = p(1) - p(0) = 35 - 17 = 5 + 13 = 18 and D = p(-1) - p(0) = 9 - 17 = 5 - 13 = -8, then solve with A = ((K + D)/2) = ((18 + (-8)) / 2) = 5 and B = ((K - D)/2) = ((18 - (-8)) / 2) = 13. Could this be extended to higher polynomials? Earl of Arundel (talk) 18:04, 9 May 2021 (UTC)

Yes. For any set of pairs (x1,y1),(x2,y2),...,(xn,yn) in which all xi values are distinct, there is a unique polynomial P(x) of degree at most n1 such that P(xi)=yi,i=1,2,...,n. See Template:Section link. Taking the n coefficients of the polynomial P(x)=jcjxj as unknowns, the n equations
j=0n1cjxij=yi,i=1,2,...,n
form a linear system of n equations with n unknowns. See Template:Section link.  --Lambiam 19:03, 9 May 2021 (UTC)
Awesome, thank you! Earl of Arundel (talk) 21:11, 9 May 2021 (UTC)
FYI, there's a systematic way to solve this system of linear equations, which is the Lagrange interpolation formula. It can come in handy a lot of times. Duckmather (talk) 20:18, 10 May 2021 (UTC)
Thank you! Yes, it looks like matrices are the way to go with that. Earl of Arundel (talk) 00:49, 12 May 2021 (UTC)