Discretisation of a PDE in Lagrangian coordinates

  • #1
hunt_mat
Homework Helper
1,782
32
TL;DR Summary
Sense check for a discretisation scheme for 2D Lagrangian scheme
I am writing a 2D hydrocode in Lagrangian co-ordinates. I have never done this before, so I am completely clueless as to what I'm doing. I have a route as to what I want to do, but I don't know if this makes sense or not. I've gone from Eulerian to Lagrangian co-ordinates using the Piola identities and then using the finite volume method to get a discrete model. One of the equations that I've been looking at is:
[tex]
\frac{\partial D}{\partial X}-\frac{\partial C}{\partial Y}=0
[/tex]
Choosing a rectangle with vertices [itex](X,Y),(X+\delta X,Y),(X+\delta X,Y+\delta Y),(X+Y+\delta Y)[/itex] to integrate over, and using Green's theorem in the plane, one is able to obtain:
[tex]
\int_{X}^{X+\delta X}C(s,Y+\delta Y)+C(s,Y)ds+\int_{Y}^{Y+\delta Y}D(X,s)+D(X+\delta X,s)ds=0
[/tex]
If I then want to discretise this, I would use the approximation [itex]f(x)+f(x+\delta x/2)\approx f(x+\delta x/2)[/itex], and using the midpoint rule for integrals one then obtains:
[tex]
C(X+\delta X/2,Y+\delta Y/2)\delta X+D(X+\delta X/2,Y+\delta Y/2)\delta Y\approx 0
[/tex]
Does this sound reasonable to you?
 
Physics news on Phys.org
  • #2
I tihnk you have some sign errors.

You are using [tex]
\iint_R \frac{\partial D}{\partial X} - \frac{\partial C}{\partial Y}\,dX\,dY = \oint_{\partial R} (C\mathbf{e}_X + D\mathbf{e}_Y)\cdot d\mathbf{X}[/tex] where the boundary is traversed counter-clockwise, so that [tex]
\oint_{\partial R} = \int_{(X,Y)}^{(X + \delta X,Y)} + \int_{(X + \delta X, Y)}^{(X + \delta X, Y + \delta Y)} + \int_{(X + \delta X. Y + \delta Y)}^{(X,Y + \delta Y)} + \int_{(X,Y+ \delta Y)}^{(X,Y)}[/tex] and hence [tex]
\oint_{\partial R} (C\mathbf{e}_X + D\mathbf{e}_Y)\cdot d\mathbf{X} = \int_{X}^{X + \delta X} C(s,Y) - C(s,Y + \delta Y)\,ds + \int_Y^{Y + \delta Y} D(X + \delta X,s) - D(X, s)\,ds.[/tex]

How does your discretisation work? Are you storing the values of [itex]C[/itex] and [itex]D[/itex] at the midpoint of the cell or at the vertices of the cell? If at the midpoint, then the corners of the cell are at [itex](X_n \pm \frac12\delta X, Y_m \pm \frac12\delta Y)[/itex] and you should approximate values on the cell boundary by interpolation: [tex]\begin{split}
C(X_n \pm \tfrac12 \delta X, Y_m) &= \frac{C_{n\pm 1,m} + C_{n,m}}{2} \\
D(X_n, Y_m \pm \tfrac12 \delta Y) &= \frac{D_{n,m\pm 1} + D_{n,m}}2.\end{split}[/tex]
 
  • #3
The way you wrote Green's theorem is very odd. As you wrote it, it seems confused. It might be easier if you just wrote the normal [itex]\hat{\mathbf{n}}[/itex], and the flux, [itex]\mathbf{F}=(D,-C)[/itex]. It's I think that you've made an error with the signs of your normals.

I'm using the finite volume method, so I'm, storing things at the cell centres. The cell vertices are as I gave them.
 
  • #4
If you integrate [tex]
\frac{\partial D}{\partial X} - \frac{\partial C}{\partial Y}[/tex] over a rectangle, then applying the FTC to each term separately reduces it to [tex]\begin{split}
\int_Y^{Y + \delta Y} \int_X^{X+\delta X} \frac{\partial D}{ \partial X}\,dx\,dy - \int_X^{X+\delta X} \int_Y^{Y + \delta Y} \frac{\partial C}{ \partial Y}\,dy\,dx \\
=
\int_Y^{Y + \delta Y} D(X + \delta X, s) - D(X,s)\,ds - \int_X^{X + \delta X} C(s, Y + \delta Y) - C(s,Y)\,ds\end{split}[/tex] which is consistent with my expansion, but not with yours.
 
  • #5
Okay.
 

What is discretisation of a PDE in Lagrangian coordinates?

Discretisation of a partial differential equation (PDE) in Lagrangian coordinates involves approximating the continuous PDE using a discrete set of points in the Lagrangian framework. This allows for numerical solutions to be obtained through iterative methods.

Why is discretisation necessary in Lagrangian coordinates?

Discretisation is necessary in Lagrangian coordinates to transform the continuous PDE into a form that can be solved numerically on a computer. By discretising the PDE, it becomes possible to approximate the solution at discrete points in space and time.

What are the common methods used for discretisation of PDEs in Lagrangian coordinates?

Common methods for discretisation of PDEs in Lagrangian coordinates include finite difference methods, finite element methods, and spectral methods. Each method has its own advantages and disadvantages depending on the specific problem being solved.

How does discretisation affect the accuracy of the numerical solution in Lagrangian coordinates?

The accuracy of the numerical solution in Lagrangian coordinates is affected by the choice of discretisation method, the size of the discretisation grid, and the order of approximation used. Higher-order methods and finer grids generally lead to more accurate solutions, but may also require more computational resources.

What are some challenges associated with discretisation of PDEs in Lagrangian coordinates?

Some challenges associated with discretisation of PDEs in Lagrangian coordinates include stability issues, convergence problems, and difficulties in handling complex geometries. Careful consideration of these challenges is necessary to ensure accurate and reliable numerical solutions.

Similar threads

  • Differential Equations
Replies
1
Views
770
  • Differential Equations
Replies
3
Views
391
  • Differential Equations
Replies
1
Views
2K
  • Differential Equations
Replies
6
Views
1K
  • Differential Equations
Replies
13
Views
2K
  • Differential Equations
Replies
3
Views
1K
  • Differential Equations
Replies
1
Views
2K
  • Differential Equations
Replies
3
Views
1K
Replies
3
Views
2K
  • Differential Equations
Replies
5
Views
2K
Back
Top