Streamwise periodicity for incompressible flow#773
Conversation
…treamwise Conflicts: SU2_CFD/include/solver_structure.hpp SU2_CFD/include/variables/CVariable.hpp SU2_CFD/src/solver_direct_mean_inc.cpp
…treamwise Conflicts: SU2_CFD/src/output_structure.cpp
…treamwise Conflicts: SU2_CFD/src/numerics_direct_mean_inc.cpp
…treamwise Conflicts: Common/include/config_structure.hpp
…treamwise Conflicts: .travis.yml SU2_CFD/include/variables/CIncEulerVariable.hpp SU2_CFD/src/output/output_structure_legacy.cpp SU2_CFD/src/solver_direct_mean_inc.cpp
…treamwise Conflicts: .travis.yml
…treamwise Conflicts: Common/src/config_structure.cpp SU2_CFD/include/variables/CEulerVariable.hpp SU2_CFD/src/output/output_structure_legacy.cpp SU2_CFD/src/solver_direct_mean_inc.cpp SU2_CFD/src/variables/CIncEulerVariable.cpp TestCases/serial_regression.py
…iodic_streamwise Conflicts: SU2_CFD/src/output/CFlowIncOutput.cpp SU2_CFD/src/solver_adjoint_discrete.cpp SU2_CFD/src/solver_structure.cpp
|
I guess one can ignore the CodeFactor complaints here as it just gives a vague complex code without any further line information error for CIncEulerSolver.cpp (which I could understand to some degree) and CSolver.hpp (which I dont understand at all). |
pcarruscag
left a comment
There was a problem hiding this comment.
Alright I think I covered everything.
World class documented code 👍
Loads of comments on this second pass, but they are just small re-arrangements to encapsulate the feature a bit better in terms of code, and in terms of side effects when not using it.
| residual[nDim] = Volume * U_i[0] * STANDARD_GRAVITY; | ||
| residual[nDim] = Volume * U_i[0] * STANDARD_GRAVITY / Force_Ref; |
|
No need to squash, the testcases repo is actually a bit messed up ATM because of that (oooops) |
| unsigned short Geo_Description; /*!< \brief Description of the geometry. */ | ||
| unsigned short Mesh_FileFormat; /*!< \brief Mesh input format. */ | ||
| unsigned short Tab_FileFormat; /*!< \brief Format of the output files. */ | ||
| unsigned short output_precision; /*!< \brief <ofstream>.precision(value) for SU2_DOT and HISTORY output */ |
There was a problem hiding this comment.
There is possibly other locations (edit: beyond history and SU2_DOT) where one can plug this, but it is a start for gradient validation
| /*-------------------------------------------------------------------------------------------*/ | ||
|
|
||
| /*--- Initialize/Allocate variables. ---*/ | ||
| su2double min_norm = numeric_limits<su2double>::max(); |
There was a problem hiding this comment.
Ah! no way, they've defined numeric_limits for the AD types, those guys rock.
| /*--- Incompressible flow, gradients primitive variables nDim+4, (P, vx, vy, vz, T, rho, beta) ---*/ | ||
| /*--- Incompressible flow, gradients primitive variables nDim+6, (P, vx, vy, vz, T, rho, beta, lamMu, EddyMu) ---*/ |
There was a problem hiding this comment.
Where the heck do you get them from?
There was a problem hiding this comment.
most of the time I just put the : and type want I want to have (crazy, right :) ) those github emoji cheatsheets are often incomplete
There was a problem hiding this comment.
🤦 here I was just trying to scroll down after typing :
|
Thanks a lot on the comments so far @pcarruscag . Helps quite a bit 👍 |
pcarruscag
left a comment
There was a problem hiding this comment.
I would not have written / documented / tested better myself.
I'll aprove it again for good measure.
|
All done? Is CodeFactor not letting you click the magic button? |
|
There we go :) |
Hi,
this PR adds streamwise periodic flow (incl energy eq) for the incompressible solver. For a more detailed information please see the website additions including a tutorial and theory section.
~half of the lines is .cfg's as those CHT setups require a bit more real estate. So the actual code is not too long.
Here a squash merge could be done as it merged develop quite a few times and has a bunch of 'small fix' commits. But to my knowledge that is not really necessary as.
I am ready to pass on the red lantern to someone else 🐌
Related Work
This work builds directly on #652 of @economon
PR Checklist