Initial and boundary value problem

In summary, the conversation discusses the method of Separation of Variables to solve an initial and boundary value problem, where the solution is represented as a Fourier series. The coefficients are calculated using the function $H(x - \frac{L}{2} )$ and there is a discussion about simplifying the final result.
  • #1
mathmari
Gold Member
MHB
5,049
7
Hey! :eek:

I have to solve the following initial and boundary value problem:

$$u_t=u_{xx}, 0<x<L, t>0 (1)$$
$$u_x(0,t)=u_x(L,t)=0, t>0$$
$$u(x,0)=H(x - \frac{L}{2} ), 0<x<L, \text{ where } H(x)=1 \text{ for } x>0 \text{ and } H(x)=0 \text{ for } x<0$$

I have done the following:
Using the method of Separation of Variables, the solution is of the form: $u(x,t)=X(x) \cdot T(t)$
Replacing this at $(1)$, we get the following two problems:
$$\left.\begin{matrix}
X''+\lambda X=0, 0<x<L\\
X'(0)=X'(L)=0
\end{matrix}\right\}(2)$$
and
$$\left.\begin{matrix}
T'+ \lambda T=0, t>0
\end{matrix}\right\}(3)$$
$$u(x,0)=X(x)T(0)=H(x - \frac{L}{2} )$$

Solving the problem $(2)$ we get that the eigenfunctions are:
$$X_n(x)= \left\{\begin{matrix}
1 & , n=0 \\
\cos{(\frac{n \pi x}{L})} & , n=1,2,3, \dots
\end{matrix}\right.$$

and solving the problem $(3)$ we get:
$$T_n(t)= \left\{\begin{matrix}
A_0 & , n=0 \\
e^{-(\frac{n \pi}{L})^2t} & , n=1,2,3, \dots
\end{matrix}\right.$$

So the solution of the initial problem is of the form
$$u(x,t)=A_0 + \sum_{n=1}^{\infty}{ A_n \cos{(\frac{n \pi x}{L})} e^{-(\frac{n \pi}{L})^2t}}$$

$$u(x,0)=H(x - \frac{L}{2} ) \Rightarrow H(x - \frac{L}{2} )=A_0+ \sum_{n=1}^{\infty}{A_n \cos{(\frac{n \pi x}{L})}}$$

We can write the function $H(x - \frac{L}{2} )$ as a Fourier series to calculate the coefficients $A_0$ and $A_n$.

$$H(x - \frac{L}{2} )=\frac{a_0}{2}+\sum_{n=1}^{\infty}{a_n \cos{(\frac{n \pi x}{L})}}$$

$$A_0=\frac{a_0}{2}=\frac{1}{2}$$

$$A_n=a_n=\frac{2}{L} \int_0^L{H(x - \frac{L}{2} ) \cos{(\frac{n \pi x}{L})}}dx=\frac{2}{L} \int_{\frac{L}{2}}^L{\cos{(\frac{n \pi x}{L})}}dx=-\frac{2}{n \pi} \sin{(\frac{n \pi}{2})}$$

Is this correct so far?? (Wondering)

Is there a general formula for $\sin{(\frac{n \pi}{2})}$? For even $n$ it's equal to $0$, but for odd $n$ it's equal to $1$ or $-1$.
 
Physics news on Phys.org
  • #2
mathmari said:
Is there a general formula for $\sin{(\frac{n \pi}{2})}$? For even $n$ it's equal to $0$, but for odd $n$ it's equal to $1$ or $-1$.
Or should I just let it $\sin{(\frac{n \pi}{2})}$ in the sum? (Wondering)
 
  • #3
mathmari said:
Or should I just let it $\sin{(\frac{n \pi}{2})}$ in the sum? (Wondering)

That's probably what I would do. Yes, you could split the sum up into even and odd parts, and then simplify, but I think the final result would be more complicated than what you suggest here.
 
  • #4
Ackbach said:
That's probably what I would do. Yes, you could split the sum up into even and odd parts, and then simplify, but I think the final result would be more complicated than what you suggest here.

Ahaa..Ok! (Smile)
So is the solution of the problem:
$$u(x,t)=\frac{1}{2}-\sum_{n=1}^{\infty}{\frac{2}{n \pi} \sin{(\frac{n \pi}{2})} \cos{(\frac{n \pi x}{L})} e^{-(\frac{n \pi }{L})^2t}}$$ (Wondering)
 
  • #5
It looks right to me. If you plot partial sums, and increase the number of terms included, it starts to look more and more like the step function.
 
  • #6
Ackbach said:
It looks right to me. If you plot partial sums, and increase the number of terms included, it starts to look more and more like the step function.

Ok! Thank you for your answer! (Mmm)
 

FAQ: Initial and boundary value problem

1. What is an initial value problem?

An initial value problem is a type of mathematical problem that involves finding the solution to a differential equation at a specific starting point, known as the initial condition. The solution to an initial value problem is a function that satisfies both the differential equation and the initial condition.

2. What is a boundary value problem?

A boundary value problem is a type of mathematical problem that involves finding the solution to a differential equation with conditions specified at multiple points, known as boundary conditions. The solution to a boundary value problem is a function that satisfies both the differential equation and the boundary conditions.

3. What is the difference between initial and boundary value problems?

The main difference between initial and boundary value problems is the number of conditions that must be satisfied. In an initial value problem, there is only one initial condition at a specific starting point, while in a boundary value problem, there are multiple boundary conditions at different points. This means that the solution to a boundary value problem must satisfy a set of conditions, while the solution to an initial value problem only needs to satisfy one condition.

4. What are some real-world applications of initial and boundary value problems?

Initial and boundary value problems have many real-world applications, particularly in the fields of physics, engineering, and economics. For example, they can be used to model the motion of objects, the flow of fluids, and the growth of populations. They are also essential in solving problems in heat transfer, electrical circuits, and financial analysis.

5. How are initial and boundary value problems solved?

The solution to an initial or boundary value problem can be found using various techniques, such as separation of variables, series solutions, or numerical methods. The most appropriate method will depend on the specific problem and its complexity. In some cases, analytical solutions may not be possible, and approximations or numerical solutions may be used instead.

Similar threads

Back
Top