I'm solving the 1D Poisson equation and am getting some funky numerical artifacts in the solution.
ClearAll["Global`*"];
L = 10.0;
alpha = 2.0*Pi/L;
f[x_] := (alpha^2)*Sin[alpha*x];
sol = DSolve[{-v''[x] == f[x], v[L] == 0, v[0] == 0}, v[x], {x, 0, L}];
v[x_] = v[x] /. sol
{2.44929*10^-17 x + 1. Sin[0.628319 x]}
The analytic solution really should be Sin[0.628319 x]. Why am I getting a small coefficient in front of the x in the first term. I thought DSolve was strictly symbolic.
Chop[]on the final solution. – David G. Stork Feb 18 '15 at 00:59