Skip to content
Snippets Groups Projects
Commit 7d59f4e4 authored by Elias Pipping's avatar Elias Pipping
Browse files

[Cleanup] Rename: damping -> relaxation

parent a8067f1f
No related branches found
No related tags found
No related merge requests found
...@@ -456,7 +456,7 @@ int main(int argc, char *argv[]) { ...@@ -456,7 +456,7 @@ int main(int argc, char *argv[]) {
std::fstream velocityWriter("velocities", std::fstream::out); std::fstream velocityWriter("velocities", std::fstream::out);
std::fstream coefficientWriter("coefficients", std::fstream::out); std::fstream coefficientWriter("coefficients", std::fstream::out);
std::fstream iterationWriter("iterations", std::fstream::out); std::fstream iterationWriter("iterations", std::fstream::out);
std::fstream dampingWriter("damping", std::fstream::out); std::fstream relaxationWriter("relaxation", std::fstream::out);
auto timeSteppingScheme = auto timeSteppingScheme =
initTimeStepper(parset.get<Config::scheme>("timeSteps.scheme"), initTimeStepper(parset.get<Config::scheme>("timeSteps.scheme"),
...@@ -475,7 +475,7 @@ int main(int argc, char *argv[]) { ...@@ -475,7 +475,7 @@ int main(int argc, char *argv[]) {
parset.get<size_t>("solver.tnnmg.fixed_point_iterations"); parset.get<size_t>("solver.tnnmg.fixed_point_iterations");
auto const fixedPointTolerance = auto const fixedPointTolerance =
parset.get<double>("solver.tnnmg.fixed_point_tolerance"); parset.get<double>("solver.tnnmg.fixed_point_tolerance");
auto const damping = parset.get<double>("solver.damping"); auto const relaxation = parset.get<double>("solver.relaxation");
auto const requiredReduction = auto const requiredReduction =
parset.get<double>("solver.requiredReduction"); parset.get<double>("solver.requiredReduction");
auto const printProgress = parset.get<bool>("io.printProgress"); auto const printProgress = parset.get<bool>("io.printProgress");
...@@ -537,11 +537,11 @@ int main(int argc, char *argv[]) { ...@@ -537,11 +537,11 @@ int main(int argc, char *argv[]) {
if (state_fpi <= 2 // Let the first two steps pass through unchanged if (state_fpi <= 2 // Let the first two steps pass through unchanged
|| correction < requiredReduction * lastCorrection) { || correction < requiredReduction * lastCorrection) {
alpha = computed_state; alpha = computed_state;
dampingWriter << "N "; relaxationWriter << "N ";
} else { // alpha is still the old time step here } else { // alpha is still the old time step here
alpha *= damping; alpha *= relaxation;
Arithmetic::addProduct(alpha, 1.0 - damping, computed_state); Arithmetic::addProduct(alpha, 1.0 - relaxation, computed_state);
dampingWriter << "Y "; relaxationWriter << "Y ";
} }
lastCorrection = correction; lastCorrection = correction;
} }
...@@ -586,7 +586,7 @@ int main(int argc, char *argv[]) { ...@@ -586,7 +586,7 @@ int main(int argc, char *argv[]) {
velocityWriter << std::endl; velocityWriter << std::endl;
coefficientWriter << std::endl; coefficientWriter << std::endl;
iterationWriter << std::endl; iterationWriter << std::endl;
dampingWriter << std::endl; relaxationWriter << std::endl;
if (parset.get<bool>("io.writeVTK")) { if (parset.get<bool>("io.writeVTK")) {
SingletonVectorType vonMisesStress; SingletonVectorType vonMisesStress;
...@@ -610,7 +610,7 @@ int main(int argc, char *argv[]) { ...@@ -610,7 +610,7 @@ int main(int argc, char *argv[]) {
velocityWriter.close(); velocityWriter.close();
coefficientWriter.close(); coefficientWriter.close();
iterationWriter.close(); iterationWriter.close();
dampingWriter.close(); relaxationWriter.close();
Python::stop(); Python::stop();
} }
......
...@@ -48,7 +48,7 @@ verbosity = quiet ...@@ -48,7 +48,7 @@ verbosity = quiet
[solver] [solver]
tolerance = 1e-10 tolerance = 1e-10
damping = 0.5 relaxation = 0.5
requiredReduction = 0.5 requiredReduction = 0.5
[solver.tnnmg] [solver.tnnmg]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment