Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom Python wrapper marker BC values appropriately nondimensionalized #2078

Merged
merged 2 commits into from
Jul 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions SU2_CFD/src/solvers/CHeatSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,7 @@ void CHeatSolver::BC_Isothermal_Wall(CGeometry *geometry, CSolver **solver_conta
SU2_OMP_FOR_STAT(OMP_MIN_SIZE)
for (auto iVertex = 0ul; iVertex < geometry->nVertex[val_marker]; iVertex++) {
if (IsPyCustom) {
Twall = geometry->GetCustomBoundaryTemperature(val_marker, iVertex);
Twall = geometry->GetCustomBoundaryTemperature(val_marker, iVertex) / config->GetTemperature_Ref();
}
IsothermalBoundaryCondition(geometry, solver_container[FLOW_SOL], config, val_marker, iVertex, Twall);
}
Expand All @@ -400,7 +400,7 @@ void CHeatSolver::BC_HeatFlux_Wall(CGeometry* geometry, CSolver** solver_contain
if (!geometry->nodes->GetDomain(iPoint)) continue;

if (IsPyCustom) {
Wall_HeatFlux = geometry->GetCustomBoundaryHeatFlux(val_marker, iVertex);
Wall_HeatFlux = geometry->GetCustomBoundaryHeatFlux(val_marker, iVertex) / config->GetHeat_Flux_Ref();
}
/*--- Viscous contribution to the residual at the wall. ---*/
const auto* Normal = geometry->vertex[val_marker][iVertex]->GetNormal();
Expand Down
4 changes: 2 additions & 2 deletions SU2_CFD/src/solvers/CNSSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ void CNSSolver::BC_HeatFlux_Wall_Generic(const CGeometry* geometry, const CConfi
/*--- If it is a customizable patch, retrieve the specified wall heat flux. ---*/

if (config->GetMarker_All_PyCustom(val_marker))
Wall_HeatFlux = geometry->GetCustomBoundaryHeatFlux(val_marker, iVertex);
Wall_HeatFlux = geometry->GetCustomBoundaryHeatFlux(val_marker, iVertex) / config->GetHeat_Flux_Ref();
else if (kind_boundary == HEAT_TRANSFER) {
const su2double Twall = nodes->GetTemperature(iPoint);
Wall_HeatFlux = Transfer_Coefficient * (Tinfinity - Twall);
Expand Down Expand Up @@ -710,7 +710,7 @@ void CNSSolver::BC_Isothermal_Wall_Generic(CGeometry *geometry, CSolver **solver
thermal_conductivity, There, Temperature_Ref);
}
else if (config->GetMarker_All_PyCustom(val_marker)) {
Twall = geometry->GetCustomBoundaryTemperature(val_marker, iVertex);
Twall = geometry->GetCustomBoundaryTemperature(val_marker, iVertex) / Temperature_Ref;
}

/*--- Compute the normal gradient in temperature using Twall ---*/
Expand Down