Skip to content

Commit

Permalink
Merge branch 'development' into inp_custom_geo_wind_profile
Browse files Browse the repository at this point in the history
  • Loading branch information
AMLattanzi authored Aug 2, 2024
2 parents 02cc343 + 4ae7f4a commit e5eb679
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
24 changes: 12 additions & 12 deletions Source/Diffusion/DiffusionSrcForState_N.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -236,9 +236,9 @@ DiffusionSrcForState_N (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
} else if (ext_dir_on_zhi) {
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) ) * dz_inv;
} else if (most_on_zlo && (qty_index == RhoTheta_comp)) {
zflux(i,j,k,qty_index) = -rhoFace * hfx_z(i,j,0);
} else if (most_on_zlo && (qty_index == RhoQ1_comp)) {
Expand Down Expand Up @@ -303,9 +303,9 @@ DiffusionSrcForState_N (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
} else if (ext_dir_on_zhi) {
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) ) * dz_inv;
} else if (most_on_zlo && (qty_index == RhoTheta_comp)) {
zflux(i,j,k,qty_index) = -rhoFace * hfx_z(i,j,0);
} else if (most_on_zlo && (qty_index == RhoQ1_comp)) {
Expand Down Expand Up @@ -366,9 +366,9 @@ DiffusionSrcForState_N (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
} else if (ext_dir_on_zhi) {
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) ) * dz_inv;
} else if (most_on_zlo && (qty_index == RhoTheta_comp)) {
zflux(i,j,k,qty_index) = -rhoFace * hfx_z(i,j,0);
} else if (most_on_zlo && (qty_index == RhoQ1_comp)) {
Expand Down Expand Up @@ -428,9 +428,9 @@ DiffusionSrcForState_N (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
} else if (ext_dir_on_zhi) {
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) ) * dz_inv;
zflux(i,j,k,qty_index) = rhoAlpha * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) ) * dz_inv;
} else if (most_on_zlo && (qty_index == RhoTheta_comp)) {
zflux(i,j,k,qty_index) = -rhoFace * hfx_z(i,j,0);
} else if (most_on_zlo && (qty_index == RhoQ1_comp)) {
Expand Down
24 changes: 12 additions & 12 deletions Source/Diffusion/DiffusionSrcForState_T.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,9 +262,9 @@ DiffusionSrcForState_T (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) );
} else if (ext_dir_on_zhi) {
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) );
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) );
} else {
GradCz = dz_inv * ( cell_prim(i, j, k, prim_index) - cell_prim(i, j, k-1, prim_index) );
}
Expand Down Expand Up @@ -337,9 +337,9 @@ DiffusionSrcForState_T (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) );
} else if (ext_dir_on_zhi) {
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) );
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) );
} else {
GradCz = dz_inv * ( cell_prim(i, j, k, prim_index) - cell_prim(i, j, k-1, prim_index) );
}
Expand Down Expand Up @@ -409,9 +409,9 @@ DiffusionSrcForState_T (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) );
} else if (ext_dir_on_zhi) {
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) );
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) );
} else {
GradCz = dz_inv * ( cell_prim(i, j, k, prim_index) - cell_prim(i, j, k-1, prim_index) );
}
Expand Down Expand Up @@ -480,9 +480,9 @@ DiffusionSrcForState_T (const Box& bx, const Box& domain,
+ 3. * cell_prim(i, j, k , prim_index)
- (1./3.) * cell_prim(i, j, k+1, prim_index) );
} else if (ext_dir_on_zhi) {
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k-1, prim_index)
- 3. * cell_prim(i, j, k , prim_index)
+ (1./3.) * cell_prim(i, j, k+1, prim_index) );
GradCz = dz_inv * ( (8./3.) * cell_prim(i, j, k , prim_index)
- 3. * cell_prim(i, j, k-1, prim_index)
+ (1./3.) * cell_prim(i, j, k-2, prim_index) );
} else {
GradCz = dz_inv * ( cell_prim(i, j, k, prim_index) - cell_prim(i, j, k-1, prim_index) );
}
Expand Down

0 comments on commit e5eb679

Please sign in to comment.