Consider the heat equation solution $h(x,t)$ where $x \in [0,1]$ and $t \geq 0$ with initial condition $h(x,t=0)=f(x)$ and Neumann boundary $\frac{d}{dx} h(x=0,t)=0$ and $\frac{d}{dx} h(x=1,t)=0$. Suppose $f(x)=x^n$ where $n \in \mathbb{N}$. Obviously, the solution $h$ can be expressed as an infinite Cosine series. However, I was wondering if for this particular choice of $f$, whether $h(x,t)$ has a closed form solution? If yes, then, great, what is the expression? :)
If not, then here is the next question: is there a good approximation for $\hat{h}(x,t) \approx h(x,t)$ such that $\hat{h}(x,t)$ is a polynomial of degree at most $n$ with respect to variable $x$ (does not necessarily need to be polynomial in $t$)?
Thanks,
Golabi
I assume the constant in your heat equation is $1$, so it's $$\dfrac{\partial h}{\partial t} = \dfrac{\partial^2 h}{\partial x^2}$$ If I'm not mistaken, your solution can be written as an integral of a Jacobi theta function:
$$h(x,t) = \int_0^1 s^n \vartheta_3\left(\dfrac{\pi (x-s)}{2}, e^{-\pi^2 t}\right)\; ds $$
although that probably won't help you much. It's basically equivalent to your cosine series.
For large $t$, there's not much point in approximating the solution using polynomials: the first few terms of your cosine series will give you a very good approximation, because $\exp(-n^2 \pi^2 t)$ goes to $0$ very rapidly unless $n$ is small.