Skip to content
Snippets Groups Projects
Verified Commit 6feeee0b authored by Paul Dechamps's avatar Paul Dechamps :speech_balloon:
Browse files

(fix) Fix format + API test

parent eac86b00
No related branches found
No related tags found
1 merge request!1BLASTER v1.0
Pipeline #49400 passed
......@@ -190,7 +190,8 @@ void Closures::turbulentClosures(std::vector<double> &closureVars, double theta,
// ctEq = std::sqrt(Hstar * 0.015/(1-us) * (Hk-1)*(Hk-1)*(Hk-1)/(Hk*Hk*H));
// // Drela 1987
}
if (n * Hstar * Ctcon * ((Hk - 1.) * Hkc * Hkc) / ((1. - us) * (Hk * Hk) * H) <
if (n * Hstar * Ctcon * ((Hk - 1.) * Hkc * Hkc) /
((1. - us) * (Hk * Hk) * H) <
0.)
std::cout << "Negative sqrt encountered " << std::endl;
......@@ -268,7 +269,8 @@ void Closures::turbulentClosures(double &closureVars, double theta, double H,
ctEq = std::sqrt(Hstar * Ctcon * ((Hk - 1.) * Hkc * Hkc) /
((1. - us) * (Hk * Hk) * H)); // Here it is ctEq^0.5
}
if (Hstar * Ctcon * ((Hk - 1.) * Hkc * Hkc) / ((1. - us) * (Hk * Hk) * H) < 0.)
if (Hstar * Ctcon * ((Hk - 1.) * Hkc * Hkc) / ((1. - us) * (Hk * Hk) * H) <
0.)
std::cout << "Negative sqrt encountered " << std::endl;
closureVars = ctEq;
......
......@@ -82,7 +82,7 @@ def cfgInviscid(nthrds, verb):
def cfgBlast(verb):
return {
'Re' : 1e6, # Freestream Reynolds number
'Re' : 1e7, # Freestream Reynolds number
'Minf' : 0.2, # Freestream Mach number (used for the computation of the time step only)
'CFL0' : 1, # Inital CFL number of the calculation
'Verb': verb, # Verbosity level of the solver
......@@ -150,10 +150,8 @@ def main():
print(tms)
print(ccolors.ANSI_BLUE + 'PyTesting' + ccolors.ANSI_RESET)
tests = CTests()
tests.add(CTest('Cl', isol.getCl(), 0.226, 1e-2))
tests.add(CTest('Cd', isol.getCd()+vsol.Cdf, 0.00587, 1e-2))
tests.add(CTest('dCl_dAoA', adj.tdCl_AoA, 5.47, 1e-3))
tests.add(CTest('dCd_dAoA', adj.tdCd_AoA, 0.09531, 1e-3))
tests.add(CTest('Cl', isol.getCl(), 0.234, 1e-2, forceabs=True))
tests.add(CTest('Cd', isol.getCd()+vsol.Cdf, 0.005, 1e-2, forceabs=True))
tests.run()
# eof
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment