Skip to content
Snippets Groups Projects

Update README.md

Merged saizz requested to merge saizz-master-patch-88205 into master
1 file
+ 59
1
Compare changes
  • Side-by-side
  • Inline
+ 59
1
# Orthogonal
This is the public folder for the "Orthogonal Polynomials" team.
\ No newline at end of file
This is the public folder for the "Orthogonal Polynomials" team.
Reccurance Relationship Approach in Matlab ( Based on previous work done by Aflredo in Maple)
a=0;
b=0;
N = 50;
s= 1i;
digits = 100;
t = s*N;
r = [];
R = [];
r(1)= 0;
R(1)=((a+b+1)/2)*(exp(-2*t)/exp(-t));
for n = 1:N+1
r(n+1)=((1/2*t)*(4*R(n)^2+2*R(n)*(2*t-2*(n-1)-1-a-b)-2*a*t)-r(n));
R(n+1)=(r(n+1)*t*(a+r(n+1))*(t+R(n))) /(((-r(n+1)^2)*t+((-2*(n-1)-b-a-2)*R(n)-a*t))*r(n+1)+R(n)*(n)*(n+b));
end
aa(1) = (1/t)*(a+b+1-t-2*R(1));
bb(1)=(1/(t*(t+R(1))))*(-(a+b)*r(1)-(t/R(1)*((r(1)^2)+a*r(1))));
for n = 2:N+1
aa(n) = (1/t) *(2*(n-1) + a+b + 1-t-2*R(n));
bb(n) = (1/(t*(t+R(n)))) * ((n-1)*(n-1+b)-(2*(n-1)+a+b)*r(n)-(t/R(n)*((r(n)^2)+a*r(n))));
end
x = 1:length(aa);
plot(x, imag(aa), "go")
grid
J(1,1) = aa(1);
J(1,2) = 1;
for k = 2:N-1
J(k,k-1) = bb(k);
J(k,k) = aa(k);
J(k,k+1) = 1;
end
J(N,N-1) = bb(N);
J(N,N) = aa(N);
v = eig(J);
imv = imag(v);
relv = real(v);
q = 1:length(v);
plot(imv, relv, "bo")
grid
Loading