Skip to content

Commit 362a1e7

Browse files
committed
Merge branch 'develop'
2 parents 392e9f3 + 6cdbfee commit 362a1e7

File tree

287 files changed

+3088
-3395
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

287 files changed

+3088
-3395
lines changed

Common/doc/docmain.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file docmain.hpp
33
* \brief This file contains documentation for Doxygen and does not have any significance with respect to C++.
44
* \author F. Palacios
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).

Common/include/ad_structure.inl

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,29 +2,29 @@
22

33

44
namespace AD{
5-
#ifdef CODI_REVERSE_TYPE
5+
#if defined CODI_REVERSE_TYPE
66

77
typedef codi::DataStore CheckpointHandler;
88

99
/*--- Stores the indices of the input variables (they might be overwritten) ---*/
1010

11-
extern std::vector<unsigned int> inputValues;
11+
extern std::vector<su2double::GradientData> inputValues;
1212

1313
/*--- Current position inside the adjoint vector ---*/
1414

1515
extern int adjointVectorPosition;
1616

1717
/*--- Reference to the tape ---*/
1818

19-
extern codi::ChunkTape<double, int>& globalTape;
19+
extern su2double::TapeType& globalTape;
2020

2121
extern bool Status;
2222

2323
extern bool PreaccActive;
2424

25-
extern codi::ChunkTape<double, int>::Position StartPosition, EndPosition;
25+
extern su2double::TapeType::Position StartPosition, EndPosition;
2626

27-
extern std::vector<unsigned int> localInputValues;
27+
extern std::vector<su2double::GradientData> localInputValues;
2828

2929
extern std::vector<su2double*> localOutputValues;
3030

@@ -33,7 +33,7 @@ namespace AD{
3333

3434
inline void RegisterOutput(su2double& data){AD::globalTape.registerOutput(data);}
3535

36-
inline void ResetInput(su2double &data){data.getGradientData() = 0;}
36+
inline void ResetInput(su2double &data){data.getGradientData() = su2double::GradientData();}
3737

3838
inline void StartRecording(){AD::globalTape.setActive();}
3939

@@ -54,7 +54,7 @@ namespace AD{
5454

5555
inline void SetPreaccIn(const su2double &data){
5656
if (PreaccActive){
57-
if (data.getGradientData() != 0){
57+
if (data.isActive()){
5858
localInputValues.push_back(data.getGradientData());
5959
}
6060
}
@@ -63,7 +63,7 @@ namespace AD{
6363
inline void SetPreaccIn(su2double* data, const int size){
6464
if (PreaccActive){
6565
for (unsigned short i = 0; i < size; i++){
66-
if (data[i].getGradientData() != 0){
66+
if (data[i].isActive()){
6767
localInputValues.push_back(data[i].getGradientData());
6868
}
6969
}
@@ -74,7 +74,7 @@ namespace AD{
7474
if (PreaccActive){
7575
for (unsigned short i = 0; i < size_x; i++){
7676
for (unsigned short j = 0; j < size_y; j++){
77-
if (data[i][j].getGradientData() != 0){
77+
if (data[i][j].isActive()){
7878
localInputValues.push_back(data[i][j].getGradientData());
7979
}
8080
}
@@ -91,7 +91,7 @@ namespace AD{
9191

9292
inline void SetPreaccOut(su2double& data){
9393
if (PreaccActive){
94-
if (data.getGradientData() != 0){
94+
if (data.isActive()){
9595
localOutputValues.push_back(&data);
9696
}
9797
}
@@ -100,7 +100,7 @@ namespace AD{
100100
inline void SetPreaccOut(su2double* data, const int size){
101101
if (PreaccActive){
102102
for (unsigned short i = 0; i < size; i++){
103-
if (data[i].getGradientData() != 0){
103+
if (data[i].isActive()){
104104
localOutputValues.push_back(&data[i]);
105105
}
106106
}
@@ -111,7 +111,7 @@ namespace AD{
111111
if (PreaccActive){
112112
for (unsigned short i = 0; i < size_x; i++){
113113
for (unsigned short j = 0; j < size_y; j++){
114-
if (data[i][j].getGradientData() != 0){
114+
if (data[i][j].isActive()){
115115
localOutputValues.push_back(&data[i][j]);
116116
}
117117
}

Common/include/config_structure.hpp

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* \brief All the information about the definition of the physical problem.
44
* The subroutines and functions are in the <i>config_structure.cpp</i> file.
55
* \author F. Palacios, T. Economon, B. Tracey
6-
* \version 4.1.1 "Cardinal"
6+
* \version 4.1.2 "Cardinal"
77
*
88
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
99
* Dr. Thomas D. Economon ([email protected]).
@@ -55,7 +55,7 @@ using namespace std;
5555
* \brief Main class for defining the problem; basically this class reads the configuration file, and
5656
* stores all the information.
5757
* \author F. Palacios
58-
* \version 4.1.1 "Cardinal"
58+
* \version 4.1.2 "Cardinal"
5959
*/
6060

6161
class CConfig {
@@ -430,11 +430,10 @@ class CConfig {
430430
AoS; /*!< \brief Angle of sideSlip (just external flow). */
431431
bool Fixed_CL_Mode; /*!< \brief Activate fixed CL mode (external flow only). */
432432
su2double Target_CL; /*!< \brief Specify a target CL instead of AoA (external flow only). */
433-
su2double Damp_Fixed_CL; /*!< \brief Damping coefficient for fixed CL mode (external flow only). */
433+
su2double dCl_dAlpha; /*!< \brief Lift curve slope for fixed CL mode (1/deg, external flow only). */
434434
unsigned long Iter_Fixed_CL; /*!< \brief Iterations to re-evaluate the angle of attack (external flow only). */
435435
bool Update_AoA; /*!< \brief Boolean flag for whether to update the AoA for fixed lift mode on a given iteration. */
436436
su2double ChargeCoeff; /*!< \brief Charge coefficient (just for poisson problems). */
437-
su2double *U_FreeStreamND; /*!< \brief Reference variables at the infinity, free stream values. */
438437
unsigned short Cauchy_Func_Flow, /*!< \brief Function where to apply the convergence criteria in the flow problem. */
439438
Cauchy_Func_AdjFlow, /*!< \brief Function where to apply the convergence criteria in the adjoint problem. */
440439
Cauchy_Elems; /*!< \brief Number of elements to evaluate. */
@@ -5226,10 +5225,10 @@ class CConfig {
52265225
su2double GetTarget_CL(void);
52275226

52285227
/*!
5229-
* \brief Get the value of the damping coefficient for fixed CL mode.
5230-
* \return Damping coefficient for fixed CL mode.
5228+
* \brief Get the value for the lift curve slope for fixed CL mode.
5229+
* \return Lift curve slope for fixed CL mode.
52315230
*/
5232-
su2double GetDamp_Fixed_CL(void);
5231+
su2double GetdCl_dAlpha(void);
52335232

52345233
/*!
52355234
* \brief Get the value of iterations to re-evaluate the angle of attack.

Common/include/config_structure.inl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file config_structure.inl
33
* \brief In-Line subroutines of the <i>config_structure.hpp</i> file.
44
* \author F. Palacios, T. Economon
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).
@@ -1114,7 +1114,7 @@ inline bool CConfig::GetFixed_CL_Mode(void) { return Fixed_CL_Mode; }
11141114

11151115
inline su2double CConfig::GetTarget_CL(void) {return Target_CL; }
11161116

1117-
inline su2double CConfig::GetDamp_Fixed_CL(void) {return Damp_Fixed_CL; }
1117+
inline su2double CConfig::GetdCl_dAlpha(void) {return dCl_dAlpha; }
11181118

11191119
inline unsigned long CConfig::GetIter_Fixed_CL(void) {return Iter_Fixed_CL; }
11201120

Common/include/datatype_structure.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* \brief Headers for generalized datatypes.
44
* The subroutines and functions are in the <i>datatype_structure.cpp</i> file.
55
* \author T. Albring
6-
* \version 4.1.1 "Cardinal"
6+
* \version 4.1.2 "Cardinal"
77
*
88
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
99
* Dr. Thomas D. Economon ([email protected]).
@@ -64,7 +64,7 @@ typedef double passivedouble;
6464
* \brief Namespace for defining the datatype wrapper routines; this class features as a base class for
6565
* type interfaces for non-primitive dataypes e.g. used by AD, complex etc.
6666
* \author T. Albring
67-
* \version 4.1.1 "Cardinal"
67+
* \version 4.1.2 "Cardinal"
6868
*/
6969
namespace SU2_TYPE{
7070
/*!

Common/include/datatype_structure.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file datatype_structure.inl
33
* \brief In-Line subroutines of the <i>datatype_structure.hpp</i> file.
44
* \author T. Albring
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).

Common/include/datatypes/codi_forward_structure.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file codi_forward_structure.hpp
33
* \brief Header for codi forward type definition.
44
* \author T. Albring
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).

Common/include/datatypes/codi_forward_structure.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file codi_forward_structure.inl
33
* \brief Inline subroutines for <i>codi_forward_structure.hpp<i>.
44
* \author T. Albring
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).

Common/include/datatypes/codi_reverse_structure.hpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file codi_reverse_structure.hpp
33
* \brief Header for codi reverse type definition.
44
* \author T. Albring
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).
@@ -33,4 +33,8 @@
3333
#include "codi.hpp"
3434
#include "tools/dataStore.hpp"
3535

36+
#ifdef CODI_INDEX_TAPE
37+
typedef codi::RealReverseIndex su2double;
38+
#else
3639
typedef codi::RealReverse su2double;
40+
#endif

Common/include/datatypes/codi_reverse_structure.inl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* \file codi_reverse_structure.inl
33
* \brief Inline subroutines for <i>datatype_structure.hpp<i>.
44
* \author T. Albring
5-
* \version 4.1.1 "Cardinal"
5+
* \version 4.1.2 "Cardinal"
66
*
77
* SU2 Lead Developers: Dr. Francisco Palacios ([email protected]).
88
* Dr. Thomas D. Economon ([email protected]).

0 commit comments

Comments
 (0)