• 1
• 7
• 8
• 9
• 10
• 11 Cuchulainn
Posts: 61467
Joined: July 16th, 2004, 7:38 am
Location: Amsterdam
Contact:

### Re: About solving a transport equation

Take any (intro) book on numerical schemes for conservative laws. You can go with Roe, HLLC or FCT and you are done.
I am reading up some models and comparing/contrasting/modifying with my own method for linear advection and Burgers test suites (will summarise it soon).

Essentially,
Somewhere you (Monsieur JeanLeM mentioned Godounov scheme but couldn't find it. A related scheme (?) for the pde
$\frac{\partial u}{\partial t} +a\frac{\partial u}{\partial x} = 0$ on the interval $(0,1)$ (1)

is
$(u_i^{n+1} - u_i^{n})/k + a(u_i^{n+1} - u_{i-1}^{n})/h = 0$

here

$a > 0$ constant
$h,k$ step sizes in $x$ and $t$ directions, respectively.
http://www.datasimfinancial.com
http://www.datasim.nl

Every Time We Teach a Child Something, We Keep Him from Inventing It Himself
Jean Piaget FaridMoussaoui
Posts: 507
Joined: June 20th, 2008, 10:05 am
Location: Genève, Genf, Ginevra, Geneva

### Re: About solving a transport equation

Trying to be useful there, I just mention that we proposed some years ago  in this paper a method to compute explicitly solutions to these equations : more precisely one can compute explicitly (entropic or conservative) multi-dimensional solutions for conservation laws or Hamilton-Jacobi type equations, with convex fluxes (of Burger type) or non convex fluxes (to model multi-phase medium).
Hi Jean-Marc. It is said that the code is available on page 6 to reproduce the results but the link is dead. JohnLeM
Posts: 375
Joined: September 16th, 2008, 7:15 pm

### Re: About solving a transport equation

Trying to be useful there, I just mention that we proposed some years ago  in this paper a method to compute explicitly solutions to these equations : more precisely one can compute explicitly (entropic or conservative) multi-dimensional solutions for conservation laws or Hamilton-Jacobi type equations, with convex fluxes (of Burger type) or non convex fluxes (to model multi-phase medium).
Hi Jean-Marc. It is said that the code is available on page 6 to reproduce the results but the link is dead.
Hi Farid, yes the link is broken sorry. Moreover the code is lost - this was a 8 years old code, and I did not kept any archive of it :/ If needed, I could rewrite it  - AFAR I needed a special matrix factorization (I could provide the code) and a convex hull algorithm (I was using qhull but I think that boost convex_hull is fine now). FaridMoussaoui
Posts: 507
Joined: June 20th, 2008, 10:05 am
Location: Genève, Genf, Ginevra, Geneva

### Re: About solving a transport equation

Moreover the code is lost - this was a 8 years old code, and I did not kept any archive of it :/
What? I even have a copy of my 90's codes. In floppies .... Cuchulainn
Posts: 61467
Joined: July 16th, 2004, 7:38 am
Location: Amsterdam
Contact:

### Re: About solving a transport equation

Moreover the code is lost - this was a 8 years old code, and I did not kept any archive of it :/
What? I even have a copy of my 90's codes. In floppies ....
I have my paper tape backup of Dartmouth Basic for GE diodes' reliability testing from 1974. But I've lost the teletype..Besides, it makes more noise than drums. http://www.datasimfinancial.com
http://www.datasim.nl

Every Time We Teach a Child Something, We Keep Him from Inventing It Himself
Jean Piaget FaridMoussaoui
Posts: 507
Joined: June 20th, 2008, 10:05 am
Location: Genève, Genf, Ginevra, Geneva

### Re: About solving a transport equation

Hi Farid, yes the link is broken sorry. Moreover the code is lost - this was a 8 years old code, and I did not kept any archive of it :/ If needed, I could rewrite it  - AFAR I needed a special matrix factorization (I could provide the code) and a convex hull algorithm (I was using qhull but I think that boost convex_hull is fine now).
What you took as basis function in (5.8)? classic P1(/Q1)? JohnLeM
Posts: 375
Joined: September 16th, 2008, 7:15 pm

### Re: About solving a transport equation

Hi Farid, yes the link is broken sorry. Moreover the code is lost - this was a 8 years old code, and I did not kept any archive of it :/ If needed, I could rewrite it  - AFAR I needed a special matrix factorization (I could provide the code) and a convex hull algorithm (I was using qhull but I think that boost convex_hull is fine now).
What you took as basis function in (5.8)? classic P1(/Q1)?
Hello Farid, At that time I was considering the basis function given in (5.6), even if I would not recommend them today. Cuchulainn
Posts: 61467
Joined: July 16th, 2004, 7:38 am
Location: Amsterdam
Contact:

### Re: About solving a transport equation

Side remark:
An underlying sub-theme in this thread is that a linear advection $pde(t,x)$ on real line (Cauchy problem, OP's pde) was transformed to $(-1,1)$ or $(0,1)$ by transformations

$y = tanh (x)$ (1)

and
$y = 1/(1 + e^{-x)}$ (2)

,respectively.
These can be use for certain kinds of PDE just like the well-known and yugely popular $y = x/(1+x)$.

Test on BVN (Bivariate Normal distribution)
In my C++ book 2018 I wrote a novel algorithm to compute BVN. Using the fundamental theorem of calculus in 2 variables leads to a class Goursat hyperbolic pde $\frac{\partial^2 u}{\partial x \partial y} = f$ in the infinite plane. I truncated the plane to a biggish box and applied 2nd order and extrapolated 4th order fdm.
Now, I have used domain transformations (1) and (2) on that same Goursat and I the same results as West/Genz as well as exact 2-factor options based on $M(a,b;\rho)$ (examples taken from Haug 2007). You can tune to the desired accuracy (2nd, 3rd and 4th gears), in contrast to other methods which are WYSIWYG (only 5th gear).
This POC shows that (1) and (2) could be applied to other PDEs as well.
http://www.datasimfinancial.com
http://www.datasim.nl

Every Time We Teach a Child Something, We Keep Him from Inventing It Himself
Jean Piaget  