X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=solve_poisson.m;fp=solve_poisson.m;h=be1b1ec0faa5449ab27cc536f34f7e4c1e312c75;hb=1a5bceb9de6bd3a511e7edcb6ab08f84dae63948;hp=0000000000000000000000000000000000000000;hpb=7e9b78da72817519f82477be5e9852ed04913aa9;p=octave.git diff --git a/solve_poisson.m b/solve_poisson.m new file mode 100644 index 0000000..be1b1ec --- /dev/null +++ b/solve_poisson.m @@ -0,0 +1,17 @@ +function u = solve_poisson(integerN, f) + ## + ## Numerically solve the poisson equation, + ## + ## -u_xx(x) = f(x) + ## + ## in one dimension, subject to the boundary conditions, + ## + ## u(0) = 0 + ## u(1) = 1 + ## + ## over the interval [0,1]. It is assumed that the function `f` is at + ## least continuous on [0,1]. + ## + + [xs,h] = partition(integerN, a, b); +end