Anonymous user
Numerical integration/Gauss-Legendre Quadrature: Difference between revisions
Numerical integration/Gauss-Legendre Quadrature (view source)
Revision as of 04:45, 18 January 2021
, 3 years ago→{{header|MATLAB}}
m (→version 3, more precision: updated the output which has more precision.) |
|||
Line 1,127:
Translated from the Python solution.
<lang MATLAB>
%Print the result.
disp(GLGD_int(@(x) exp(x), -3, 3, 5));
%Integration using Gauss-Legendre quad
%Does almost the same as 'integral' in MATLAB
|