Changes between Version 1 and Version 2 of doc/maths/remez
 Timestamp:
 Dec 28, 2011, 10:09:28 PM (9 years ago)
Legend:
 Unmodified
 Added
 Removed
 Modified

doc/maths/remez
v1 v2 2 2 = Remez exchange toolbox = 3 3 4 The Remez exchange algorithm is a fast method for approximating functions in a Chebyshev space. The Lol Engine provides its own implementation of the Remez exchange algorithm to find '''polynomial approximations to real functions'''. Such polynomials are also known as minimax polynomials. 4 '''TL;DR:''' this toolbox helps find CPUfriendly approximations to complicated functions. 5 6 The Remez exchange algorithm is a fast method for approximating functions in a Chebyshev space. This sounds dull, but you don’t need to know what a Chebyshev space is. The Lol Engine provides its own implementation of the Remez exchange algorithm to find '''polynomial approximations to real functions'''. Such polynomials are also known as minimax polynomials. 5 7 6 8 == Example == 7 9 8 The following graph shows approximations of `sin(x)`over [π, π] using three different polynomials:9 * the Taylor series to the 5th order: ''xx³/ 6+x⁵/120''10 * the Taylor series to the 7th order: ''xx³/ 6+x⁵/120x⁷/5040''10 The following graph shows approximations of ''sin(x)'' over [π, π] using three different polynomials: 11 * the Taylor series to the 5th order: ''xx³/3!+x⁵/5! '' 12 * the Taylor series to the 7th order: ''xx³/3!+x⁵/5!x⁷/7! '' 11 13 * the minimax polynomial to the 5th order: ''x0.1587164x³+0.00585375x⁵'' 12 14 13 15 [[Image(taylorvsremez.png, nolink)]] 14 16 15 It is obvious that the polynomial found using the Remez method is closer to the sine curve than the Taylor series of same order, and even better than the next order.17 It is obvious that the polynomial found using the Remez method is closer to the sine curve than the Taylor series of same order, and still better than the Taylor series of the next order. If you want to approximate a function over an interval, Remez is always better. If you want to convince people that it is, please refer them to [blog:2011/12/21/betterfunctionapproximations this blog article]. 16 18 17 19 == Download ==