Interpolation de NEWTON-TCHEBYCHEV
mcsane
-
dsy73 Messages postés 9917 Statut Contributeur -
dsy73 Messages postés 9917 Statut Contributeur -
Bonjour,
j'ai ecrit ce programme sous sage, en il me dit que 'p' n'est pas définie.
je ne suis pas trés douée en prgrammation et ne comprend pas pourquoi j'ai de type d'erreur. Merci d'avance pour votre aide
"def NEWTONTCHEBYCHEV(f,t,a,b,Ndigits,N):
corps = RealField(Ndigits); R.<X> = corps[]
T = TCHEBYCHEV(R,N+1)
ZEROS = T.roots(corps)
zeros = [ZEROS[k][0] for k in range(N+1)]
aa = corps(a); bb = corps(b)
Lx = [aa + ((bb-aa)/2)*(zeros[k]+1) for k in range(N+1)]
Ly = [f.subs({t:Lx[k]}) for k in range(N+1)]
for j in range(N):
p = NEWTONAITKEN(R,Lx,Ly)
return p"
j'ai ecrit ce programme sous sage, en il me dit que 'p' n'est pas définie.
je ne suis pas trés douée en prgrammation et ne comprend pas pourquoi j'ai de type d'erreur. Merci d'avance pour votre aide
"def NEWTONTCHEBYCHEV(f,t,a,b,Ndigits,N):
corps = RealField(Ndigits); R.<X> = corps[]
T = TCHEBYCHEV(R,N+1)
ZEROS = T.roots(corps)
zeros = [ZEROS[k][0] for k in range(N+1)]
aa = corps(a); bb = corps(b)
Lx = [aa + ((bb-aa)/2)*(zeros[k]+1) for k in range(N+1)]
Ly = [f.subs({t:Lx[k]}) for k in range(N+1)]
for j in range(N):
p = NEWTONAITKEN(R,Lx,Ly)
return p"
A voir également:
- Interpolation de NEWTON-TCHEBYCHEV
- Interpolation linéaire excel ✓ - Forum Excel
- Excel interpolation polynomiale - Forum Excel
- Interpolation linéaire formule ✓ - Forum Excel
- Interpolation polynomiale excel - Forum Excel
- Interpolation polynomiale - Forum Programmation