Skip to content

Instantly share code, notes, and snippets.

@notcome
Created November 10, 2015 08:15
Show Gist options
  • Save notcome/c4dfd2a7a2151172b8af to your computer and use it in GitHub Desktop.
Save notcome/c4dfd2a7a2151172b8af to your computer and use it in GitHub Desktop.
% http://www.tutorialspoint.com/execute_matlab_online.php
n = 8;
N = zeros(n+1);
c = linspace(1,n+1,n+1);
for i=1:n+1
for j=1:n+1
N(i,j)= ((j-1)/n)^(i-1);
end
c(i)=1/c(i);
end
b = c';
d=linsolve(N,b);
disp(N);
disp hello;
disp(b);
disp hello;
disp(d);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment