Commit 27129d7b authored by Jonathan Lambrechts's avatar Jonathan Lambrechts
Browse files

2 less bugs ... depot-2d ok

parent abbd5df6
Pipeline #9680 passed with stages
in 8 minutes and 43 seconds
...@@ -739,7 +739,7 @@ static void fluid_problem_volume(FluidProblem *problem, const double *solution_o ...@@ -739,7 +739,7 @@ static void fluid_problem_volume(FluidProblem *problem, const double *solution_o
fe_fields_df(problem->field_porosity, QP[iqp], dxidx, dsfporosity); fe_fields_df(problem->field_porosity, QP[iqp], dxidx, dsfporosity);
double c, dc[D], cold; double c, dc[D], cold;
fe_fields_eval_grad_sf(problem->field_porosity, mesh, iel, sfporosity, dsfporosity, problem->porosity, &c, &dc); fe_fields_eval_grad_sf(problem->field_porosity, mesh, iel, sfporosity, dsfporosity, problem->porosity, &c, &dc);
fe_fields_eval_sf(problem->field_porosity, mesh, iel, sfporosity, problem->porosity, &cold); fe_fields_eval_sf(problem->field_porosity, mesh, iel, sfporosity, problem->oldporosity, &cold);
double a = 0; double a = 0;
if (problem->n_fluids==2) { if (problem->n_fluids==2) {
double sfconcentration[problem->field_concentration->local_size]; double sfconcentration[problem->field_concentration->local_size];
...@@ -750,8 +750,9 @@ static void fluid_problem_volume(FluidProblem *problem, const double *solution_o ...@@ -750,8 +750,9 @@ static void fluid_problem_volume(FluidProblem *problem, const double *solution_o
const FEElement *mesh_element = problem->mesh->element; const FEElement *mesh_element = problem->mesh->element;
double meshf[mesh_element->nlocal]; double meshf[mesh_element->nlocal];
mesh_element->f(QP[iqp], meshf); mesh_element->f(QP[iqp], meshf);
for (int i = 0; i < mesh_element->nlocal; ++i) { for (int j=0; j<D; ++j) {
for (int j=0; j<D; ++j) { mesh_velocity[j] = 0;
for (int i = 0; i < mesh_element->nlocal; ++i) {
mesh_velocity[j] += meshf[i]*problem->mesh_velocity[el[i]*D+j]; mesh_velocity[j] += meshf[i]*problem->mesh_velocity[el[i]*D+j];
bf[j] += meshf[i]*problem->bulk_force[el[i]*D+j]; bf[j] += meshf[i]*problem->bulk_force[el[i]*D+j];
} }
......
Markdown is supported
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