Skip to content
Open
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
18 changes: 9 additions & 9 deletions SU2_CFD/src/solvers/CAdjEulerSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1696,16 +1696,16 @@ void CAdjEulerSolver::Inviscid_Sensitivity(CGeometry *geometry, CSolver **solver
}

SoundSpeed = solver_container[FLOW_SOL]->GetNodes()->GetSoundSpeed(iPoint);
if (Vn<SoundSpeed && Vn>0) {
/*TODO: MDO compatible*/
Sens_BPress[iMarker]+=Psi[nDim+1]*(SoundSpeed*SoundSpeed-Vn*Vn)/(Vn*Gamma_Minus_One);
if (config->GetKind_ObjFunc()==SURFACE_STATIC_PRESSURE)
Sens_BPress[iMarker]+=1;
if (config->GetKind_ObjFunc()==SURFACE_TOTAL_PRESSURE) {
for (iDim=0; iDim<nDim; iDim++)
Sens_BPress[iMarker]+=0.5*Velocity[iDim]*Velocity[iDim]/(Vn*Vn);
if (Vn < SoundSpeed && Vn > 0) {
/*--- Sensitivity contribution for MDO compatibility. ---*/
Sens_BPress[iMarker] += Psi[nDim + 1] * (SoundSpeed * SoundSpeed - Vn * Vn) / (Vn * Gamma_Minus_One);
if (config->GetKind_ObjFunc() == SURFACE_STATIC_PRESSURE)
Sens_BPress[iMarker] += 1.0;
if (config->GetKind_ObjFunc() == SURFACE_TOTAL_PRESSURE) {
for (iDim = 0; iDim < nDim; iDim++)
Sens_BPress[iMarker] += 0.5 * Velocity[iDim] * Velocity[iDim] / (Vn * Vn);
}
}
}
}
Total_Sens_BPress+= Sens_BPress[iMarker] * scale * factor;
}
Expand Down
3 changes: 1 addition & 2 deletions SU2_CFD/src/solvers/CSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2264,6 +2264,7 @@ void CSolver::SetGridVel_Gradient(CGeometry *geometry, const CConfig *config) co
true, gridVel, 0, nDim, 0, gridVelGrad, rmatrix);
}


void CSolver::SetSolution_Limiter(CGeometry *geometry, const CConfig *config) {

const auto kindLimiter = config->GetKind_SlopeLimit();
Expand Down Expand Up @@ -3383,7 +3384,6 @@ void CSolver::Read_SU2_Restart_Metadata(CGeometry *geometry, CConfig *config, bo

position = text_line.find ("ITER=",0);
if (position != string::npos) {
// TODO: 'ITER=' has 5 chars, not 9!
text_line.erase (0,9); InnerIter_ = atoi(text_line.c_str());
}

Expand Down Expand Up @@ -3440,7 +3440,6 @@ void CSolver::Read_SU2_Restart_Metadata(CGeometry *geometry, CConfig *config, bo

position = text_line.find ("STREAMWISE_PERIODIC_PRESSURE_DROP=",0);
if (position != string::npos) {
// Erase the name from the line, 'STREAMWISE_PERIODIC_PRESSURE_DROP=' has 34 chars.
text_line.erase (0,34); SPPressureDrop_ = atof(text_line.c_str());
}

Expand Down
4 changes: 3 additions & 1 deletion SU2_CFD/src/solvers/CSpeciesFlameletSolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -480,13 +480,15 @@ void CSpeciesFlameletSolver::BC_Isothermal_Wall_Generic(CGeometry* geometry, CSo
su2double dist_ij = sqrt(dist_ij_2);

/*--- Compute the normal gradient in temperature using Twall. ---*/
///TODO: Account for preferential diffusion in computation of the heat flux
su2double dTdn = -(flowNodes->GetTemperature(Point_Normal) - temp_wall) / dist_ij;

///TODO: Account for preferential diffusion in computation of the heat flux

/*--- Get thermal conductivity. ---*/

su2double thermal_conductivity = flowNodes->GetThermalConductivity(iPoint);


/*--- Apply a weak boundary condition for the energy equation.
Compute the residual due to the prescribed heat flux. ---*/

Expand Down
Loading