This package contains advection equation solved with the Finite Volume Methods by using the upwind flux.
Release Notes:
| Name | Description |
|---|---|
| AdvectionUpwind |
Implements the advection equation
where c is speed, with the Upwind numerical flux. The initial condition is
and boundary condition at the left is
The analytical solution of this problem is implemented in AdvectionAnalytic block
Release Notes:
model AdvectionUpwind
PDE.FiniteVolume.FVMIntegrator.FVIntegrator Advection(
bcl=0, bcr=0);
PDE.FiniteVolume.Fluxes.UpwindFlux.Upwind upwindNew;
Modelica.Blocks.Sources.RealExpression BCL[worldModel1.gcl](y=cos(-0.1
*time));
Modelica.Blocks.Sources.RealExpression BCR[worldModel1.gcr];
Modelica.Blocks.Sources.RealExpression speed(y=0.1);
MOL.Examples.Diffusion.DiffusionIC diffusionIC;
inner World.worldModel worldModel1(n=10);
equation
connect(Advection.y, upwindNew.u);
connect(speed.y, upwindNew.u1);
connect(BCL.y, Advection.u3);
connect(diffusionIC.y, Advection.u2);
connect(upwindNew.y, Advection.u);
connect(BCR.y, Advection.u4);
end AdvectionUpwind;