Chebychev Polynomial Coefficients, by Ron Zukerman
──────────────────────────────────────────────────
for HP 48 S/SX/G/GX
(Comp.sys.hp48)
Item: 2303 by Fallonjb95%cs14@cadetmail.usafa.af.mil
[Joshua B. L. Fallon]
Subj: need help with algorythm
Date: 21 Oct 1993
I only recently got my HP48gx, and am confused on how to
code this algorythm that I have. What I need to do, is
use this to determine Chebyshev polynomials. Then, take
the polynomial and put it into the standard polynomial
'list' form. (ie. {1 4 6 4 1}). I would have it in that
form to make it easier to change it to a transfer
function.( for EE). Any help at all would be a big help.
I need to be able to get only the nth polynomial.
C0(w) = 1
C1(w) = w
.
.
.
C (w) = 2w*C (w) - C (w)
n+1 n n-1
Thanks in advance for any help.
******************************************
* `` ` ----- *
* -= RAINMAN =- | *
* Blue \ / \ / *
* Skies... \ / *
* FALLONJB95%CS14@CADETMAIL.USAFA.AF.MIL *
******************************************
----------
Resp: 1 of 1 by ronzu@comm.mot.com [Ron Zuckerman]
Date: 21 Oct 1993
I only have a HP48SX, so I don't know what a standard
polynomial list form is supposed to look like. However,
here is a program to calculate the coefficients of a
Chebyshev polynomial:
<< -> N
<< [ 1 ]
IF N 0 > THEN [ 0 1 ]
IF N 1 > THEN
3 N 1 + FOR I
0 OVER OBJ-> DROP I ->ARRY 2 * 3 PICK
OBJ-> DROP 0 0 I ->ARRY - ROT DROP
NEXT
END
SWAP DROP
END
OBJ-> OBJ-> DROP ->LIST
>>
>>
To use the program just put the value of N on the stack
and run this program. The results are returned in a list
whose structure is as follows:
{ c0 c1 c2 ... cN }
where: Cn(w) = c0 + c1*w + c2*w^2 + ... + cN*w^N
Ron Zuckerman, KA4RPD E-mail: ronzu@isp.csg.mot.com
Phone: (708)523-7805 FAX: (708)523-7847