Commit 9b274ac8 authored by Michel Henry's avatar Michel Henry
Browse files

fix advection boundary

parent 7e8c253a
...@@ -237,7 +237,7 @@ static void f_boundary(WeakBoundary *wbnd, FluidProblem *problem,const double *n ...@@ -237,7 +237,7 @@ static void f_boundary(WeakBoundary *wbnd, FluidProblem *problem,const double *n
if (unbnd - unmesh < 0) { if (unbnd - unmesh < 0) {
for (int id = 0; id < D; ++id) { for (int id = 0; id < D; ++id) {
f0[U+id] += ((unbnd - unmesh)*(vid<0?0:uext[id])-(unold - unmesh)*u[id])*rho/c; f0[U+id] += ((unbnd - unmesh)*(vid<0?0:uext[id])-(unold - unmesh)*u[id])*rho/c;
f00[(U+id)*n_fields+U+id] -= unold*rho/c; f00[(U+id)*n_fields+U+id] -= (unold-unmesh)*rho/c;
} }
} }
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment