Jacobian not recorded correctly in AD preaccumulation region #2370
joshkellyjak
started this conversation in
General
Replies: 2 comments
-
The Jacobian matrix is passive, you'd need a TB of ram to run an inviscid NACA0012 otherwise. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Thank you, In this case what could be causing the tagging tool to interpret the jacobian as a preacc output? Maybe this is a bug in the tagging @oleburghardt ? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the bug
You will have to bear with me, I might get some of this wrong, I am not entirely sure what is going on here so I will try and include as much information as possible. Using the tape tagging method developed by @oleburghardt in #2343 and presented at the most recent SU2 Conference, a run of the full tape reveals that a variable used in a preaccumulation output is not properly recorded. The variable is the
val
in the functionPassiveAssign
inCSysMatrix.hpp
line 215.FORCEINLINE static ScalarType PassiveAssign(const SrcType& val) { return SU2_TYPE::GetValue(val); }
Following the call stack of the error reveals that the problem variables in
val
are the jacobian components calculated in the Roe and JST scheme (these are the two options I have tested). It is possible to resolve this error by simply moving the stopping of the preaccumulation region from before the call toupdateLinearSystem
in theComputeFlux
method of both these schemes, to after, as show below.`/--- Update the vector and system matrix. ---/
However, whilst this resolve the error in this location, the next error appears in the Giles boundary condition. Here the two jacobian components within the residual object are not recorded correctly in the preaccumulation output region also. This in
CEulerSolver.cpp:6556
.`/--- Compute the residual using an upwind scheme ---/
auto residual = conv_numerics->ComputeResidual(config);
I have tried simpy adding these components as preacc outputs however they are SIMD arrays and the datatype cannot be converted using the existing implementation.
I am not sure what is going on here, or the next steps to resolve this problem. Any further assistance would be greatly appreciated, thank you :)
Bug report checklist
Please make sure that you have followed the checklist below, many common problems can be solved by:
Desktop (please complete the following information):
Beta Was this translation helpful? Give feedback.
All reactions