From a3b2a8caf9d928072d19f5495d99dfb9501c7654 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 6 Dec 2024 21:53:36 +0100 Subject: [PATCH 01/49] quick fix for normal point in sharp corner --- Common/src/geometry/CPhysicalGeometry.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 6e34e715be59..4969cb65a8ef 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8104,8 +8104,10 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { Normal = vertex[iMarker][iVertex]->GetNormal(); /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ + /*--- If the neighbor node is on a wall, we set it as a neighbor if there is no previous + neighbor. We also always overwrite a neighbor if an interior point is available. ---*/ Point_Normal = 0; - cos_max = -1.0; + cos_max = -2.0; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { jPoint = nodes->GetPoint(iPoint, iNeigh); scalar_prod = 0.0; @@ -8123,8 +8125,14 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Get maximum cosine ---*/ if (cos_alpha >= cos_max) { - Point_Normal = jPoint; - cos_max = cos_alpha; + /*--- If point is on the wall, only add it if Point_Normal was not set before. ---*/ + if ( (!nodes->GetViscousBoundary(iPoint)) || + (nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0) + ) + Point_Normal = jPoint; + /*--- Only set angle if it is not on a wall. */ + if (!nodes->GetViscousBoundary(iPoint)) + cos_max = cos_alpha; } } vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); From 9863c1dffde1fbdc6767269f7e1b5fcf2a3c70fa Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 6 Dec 2024 21:55:35 +0100 Subject: [PATCH 02/49] quick fix for normal point in sharp corner --- Common/src/geometry/CPhysicalGeometry.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 4969cb65a8ef..2a37e7f84b74 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8104,8 +8104,9 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { Normal = vertex[iMarker][iVertex]->GetNormal(); /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ - /*--- If the neighbor node is on a wall, we set it as a neighbor if there is no previous - neighbor. We also always overwrite a neighbor if an interior point is available. ---*/ + /*--- If the node is on a wall, we set it as a neighbor only if no neighbor points + have been found yet. We also always overwrite a neighbor if an interior point + is available. ---*/ Point_Normal = 0; cos_max = -2.0; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { From 8c71e6dd40754536e0581ef2c96d78c004170093 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 6 Dec 2024 22:23:29 +0100 Subject: [PATCH 03/49] clang-format --- Common/src/geometry/CPhysicalGeometry.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 2a37e7f84b74..ca82a46f918d 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -7009,9 +7009,9 @@ void CPhysicalGeometry::FindUniqueNode_PeriodicBound(const CConfig* config) { * ---*/ } break; // Actually no more than one streamwise periodic marker pair is allowed - } // receiver conditional - } // periodic conditional - } // marker loop + } // receiver conditional + } // periodic conditional + } // marker loop /*--- Copy the Coordinates and norm into send buffer. ---*/ for (unsigned short iDim = 0; iDim < nDim; iDim++) Buffer_Send_RefNode[iDim] = nodes->GetCoord(iPointMin, iDim); @@ -8127,13 +8127,10 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Get maximum cosine ---*/ if (cos_alpha >= cos_max) { /*--- If point is on the wall, only add it if Point_Normal was not set before. ---*/ - if ( (!nodes->GetViscousBoundary(iPoint)) || - (nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0) - ) + if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0))) Point_Normal = jPoint; /*--- Only set angle if it is not on a wall. */ - if (!nodes->GetViscousBoundary(iPoint)) - cos_max = cos_alpha; + if (!nodes->GetViscousBoundary(iPoint)) cos_max = cos_alpha; } } vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); From e0dd4c75fc985d470c73dde591e779a5a41764dc Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sat, 7 Dec 2024 09:39:37 +0100 Subject: [PATCH 04/49] check why clang-format error --- Common/src/geometry/CPhysicalGeometry.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index ca82a46f918d..42f35ac0b635 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8127,8 +8127,8 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Get maximum cosine ---*/ if (cos_alpha >= cos_max) { /*--- If point is on the wall, only add it if Point_Normal was not set before. ---*/ - if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0))) - Point_Normal = jPoint; + /*if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0)))*/ + Point_Normal = jPoint; /*--- Only set angle if it is not on a wall. */ if (!nodes->GetViscousBoundary(iPoint)) cos_max = cos_alpha; } From a4946c31a56f43e0e00b7e287f7af455bbcac8c0 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sat, 7 Dec 2024 09:48:02 +0100 Subject: [PATCH 05/49] check why clang-format error --- Common/src/geometry/CPhysicalGeometry.cpp | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 42f35ac0b635..6e34e715be59 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -7009,9 +7009,9 @@ void CPhysicalGeometry::FindUniqueNode_PeriodicBound(const CConfig* config) { * ---*/ } break; // Actually no more than one streamwise periodic marker pair is allowed - } // receiver conditional - } // periodic conditional - } // marker loop + } // receiver conditional + } // periodic conditional + } // marker loop /*--- Copy the Coordinates and norm into send buffer. ---*/ for (unsigned short iDim = 0; iDim < nDim; iDim++) Buffer_Send_RefNode[iDim] = nodes->GetCoord(iPointMin, iDim); @@ -8104,11 +8104,8 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { Normal = vertex[iMarker][iVertex]->GetNormal(); /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ - /*--- If the node is on a wall, we set it as a neighbor only if no neighbor points - have been found yet. We also always overwrite a neighbor if an interior point - is available. ---*/ Point_Normal = 0; - cos_max = -2.0; + cos_max = -1.0; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { jPoint = nodes->GetPoint(iPoint, iNeigh); scalar_prod = 0.0; @@ -8126,11 +8123,8 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Get maximum cosine ---*/ if (cos_alpha >= cos_max) { - /*--- If point is on the wall, only add it if Point_Normal was not set before. ---*/ - /*if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0)))*/ Point_Normal = jPoint; - /*--- Only set angle if it is not on a wall. */ - if (!nodes->GetViscousBoundary(iPoint)) cos_max = cos_alpha; + cos_max = cos_alpha; } } vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); From 40119afc22cde249038c2e4bdb53a1f0cc02f71a Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sat, 7 Dec 2024 12:21:55 +0100 Subject: [PATCH 06/49] clang-format error --- Common/src/geometry/CPhysicalGeometry.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 6e34e715be59..4b3b76c0a812 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -7009,9 +7009,9 @@ void CPhysicalGeometry::FindUniqueNode_PeriodicBound(const CConfig* config) { * ---*/ } break; // Actually no more than one streamwise periodic marker pair is allowed - } // receiver conditional - } // periodic conditional - } // marker loop + } // receiver conditional + } // periodic conditional + } // marker loop /*--- Copy the Coordinates and norm into send buffer. ---*/ for (unsigned short iDim = 0; iDim < nDim; iDim++) Buffer_Send_RefNode[iDim] = nodes->GetCoord(iPointMin, iDim); @@ -8105,7 +8105,7 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ Point_Normal = 0; - cos_max = -1.0; + cos_max = -2.0; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { jPoint = nodes->GetPoint(iPoint, iNeigh); scalar_prod = 0.0; @@ -8123,8 +8123,9 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { /*--- Get maximum cosine ---*/ if (cos_alpha >= cos_max) { - Point_Normal = jPoint; - cos_max = cos_alpha; + if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0))) + Point_Normal = jPoint; + if (!nodes->GetViscousBoundary(iPoint)) cos_max = cos_alpha; } } vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); From 18054d66314cd226e3825b3ec4f9f7e198823636 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sat, 7 Dec 2024 12:26:47 +0100 Subject: [PATCH 07/49] clang-format fix --- Common/src/geometry/CPhysicalGeometry.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 4b3b76c0a812..2099e3a63137 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -7009,9 +7009,9 @@ void CPhysicalGeometry::FindUniqueNode_PeriodicBound(const CConfig* config) { * ---*/ } break; // Actually no more than one streamwise periodic marker pair is allowed - } // receiver conditional - } // periodic conditional - } // marker loop + } // receiver conditional + } // periodic conditional + } // marker loop /*--- Copy the Coordinates and norm into send buffer. ---*/ for (unsigned short iDim = 0; iDim < nDim; iDim++) Buffer_Send_RefNode[iDim] = nodes->GetCoord(iPointMin, iDim); From 35785022e8beec8069c296ffeee2d07584a4744b Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 13 Dec 2024 13:47:33 +0100 Subject: [PATCH 08/49] use wall distance --- Common/src/geometry/CPhysicalGeometry.cpp | 77 +++++++++++++++++------ 1 file changed, 57 insertions(+), 20 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 2099e3a63137..fa2ee064d6c6 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8089,11 +8089,16 @@ void CPhysicalGeometry::ComputeMeshQualityStatistics(const CConfig* config) { } } +/*--- Note that we do not find the real normal neighbor here, since it usually does not exist. + Instead, we determine the interior node that is closest to the wall node. If there is no + interior node, we have to take the closest wall node. ---*/ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { - su2double cos_max, scalar_prod, norm_vect, norm_Normal, cos_alpha, diff_coord, *Normal; + su2double dist_min; unsigned long Point_Normal, jPoint; - unsigned short iNeigh, iMarker, iDim; - unsigned long iPoint, iVertex; + unsigned short iNeigh, iMarker, jNeigh; + unsigned long iPoint, kPoint, iVertex; + // did we find an interiornode? + bool interiorNode; for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && @@ -8101,33 +8106,65 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { iPoint = vertex[iMarker][iVertex]->GetNode(); - Normal = vertex[iMarker][iVertex]->GetNormal(); + const su2double* Coord_i = nodes->GetCoord(iPoint); /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ Point_Normal = 0; - cos_max = -2.0; + // we use distance + dist_min = 1.0e10; + interiorNode = false; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { jPoint = nodes->GetPoint(iPoint, iNeigh); - scalar_prod = 0.0; - norm_vect = 0.0; - norm_Normal = 0.0; - for (iDim = 0; iDim < nDim; iDim++) { - diff_coord = nodes->GetCoord(jPoint, iDim) - nodes->GetCoord(iPoint, iDim); - scalar_prod += diff_coord * Normal[iDim]; - norm_vect += diff_coord * diff_coord; - norm_Normal += Normal[iDim] * Normal[iDim]; + const su2double* Coord_j = nodes->GetCoord(jPoint); + + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; } - norm_vect = sqrt(norm_vect); - norm_Normal = sqrt(norm_Normal); - cos_alpha = scalar_prod / (norm_vect * norm_Normal); - /*--- Get maximum cosine ---*/ - if (cos_alpha >= cos_max) { - if ((!nodes->GetViscousBoundary(iPoint)) || ((nodes->GetViscousBoundary(iPoint)) && (cos_max < -1.0))) + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min) ) { Point_Normal = jPoint; - if (!nodes->GetViscousBoundary(iPoint)) cos_max = cos_alpha; + dist_min = distance; + interiorNode = true; } + } + + // if we did not find a normal neighbor, then loop over the cells that are connected to the point + if (interiorNode == false) { + // find neighbor nodes to i. + for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = nodes->GetPoint(iPoint, iNeigh); + // now loop over the nodes of the neighbors + for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { + kPoint = nodes->GetPoint(jPoint, jNeigh); + + if (kPoint == iPoint) continue; + + const su2double* Coord_k = nodes->GetCoord(kPoint); + // now find the distance from ipoint to kpoint + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min) ) { + Point_Normal = kPoint; + dist_min = distance; + interiorNode = true; + } + } + } + } + vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); } } From 5a89f908f20ff925a2c9f396ee68be21970033d7 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 13 Dec 2024 13:55:46 +0100 Subject: [PATCH 09/49] clang --- Common/src/geometry/CPhysicalGeometry.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index fa2ee064d6c6..9ce660300af9 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8126,12 +8126,11 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { } // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min) ) { - Point_Normal = jPoint; - dist_min = distance; - interiorNode = true; + if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { + Point_Normal = jPoint; + dist_min = distance; + interiorNode = true; } - } // if we did not find a normal neighbor, then loop over the cells that are connected to the point @@ -8156,7 +8155,7 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { } // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min) ) { + if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { Point_Normal = kPoint; dist_min = distance; interiorNode = true; From 087a12c11be96a18828708b057ca624515e35c3f Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sun, 15 Dec 2024 10:52:19 +0100 Subject: [PATCH 10/49] introduce nearest_neighbor --- Common/include/geometry/CGeometry.hpp | 6 ++ .../include/geometry/CMultiGridGeometry.hpp | 8 +- Common/include/geometry/CPhysicalGeometry.hpp | 8 +- Common/include/geometry/dual_grid/CVertex.hpp | 15 +++- Common/src/geometry/CMultiGridGeometry.cpp | 79 ++++++++++++++++++ Common/src/geometry/CPhysicalGeometry.cpp | 80 +++++++++++++++++++ SU2_CFD/src/drivers/CDriver.cpp | 13 ++- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 9 ++- 8 files changed, 210 insertions(+), 8 deletions(-) diff --git a/Common/include/geometry/CGeometry.hpp b/Common/include/geometry/CGeometry.hpp index 738618ba2cd0..007a423e4085 100644 --- a/Common/include/geometry/CGeometry.hpp +++ b/Common/include/geometry/CGeometry.hpp @@ -1179,6 +1179,12 @@ class CGeometry { */ inline virtual void FindNormal_Neighbor(const CConfig* config) {} + /*! + * \brief A virtual member. + * \param[in] config - Definition of the particular problem. + */ + inline virtual void FindNearest_Neighbor(const CConfig* config) {} + /*! * \brief A virtual member. */ diff --git a/Common/include/geometry/CMultiGridGeometry.hpp b/Common/include/geometry/CMultiGridGeometry.hpp index c3e897f7f311..cecb65bbd75f 100644 --- a/Common/include/geometry/CMultiGridGeometry.hpp +++ b/Common/include/geometry/CMultiGridGeometry.hpp @@ -123,11 +123,17 @@ class CMultiGridGeometry final : public CGeometry { void SetRestricted_GridVelocity(const CGeometry* fine_grid) override; /*! - * \brief Find and store the closest neighbor to a vertex. + * \brief Find and store the closest, most normal, neighbor to a vertex. * \param[in] config - Definition of the particular problem. */ void FindNormal_Neighbor(const CConfig* config) override; + /*! + * \brief Find and store the closest interior neighbor to a vertex. + * \param[in] config - Definition of the particular problem. + */ + void FindNearest_Neighbor(const CConfig* config) override; + /*! * \brief Mach the near field boundary condition. * \param[in] config - Definition of the particular problem. diff --git a/Common/include/geometry/CPhysicalGeometry.hpp b/Common/include/geometry/CPhysicalGeometry.hpp index 8214e4ea7f0d..8681fbc772f8 100644 --- a/Common/include/geometry/CPhysicalGeometry.hpp +++ b/Common/include/geometry/CPhysicalGeometry.hpp @@ -560,11 +560,17 @@ class CPhysicalGeometry final : public CGeometry { void ComputeMeshQualityStatistics(const CConfig* config) override; /*! - * \brief Find and store the closest neighbor to a vertex. + * \brief Find and store the closest, most normal, neighbor to a vertex. * \param[in] config - Definition of the particular problem. */ void FindNormal_Neighbor(const CConfig* config) override; + /*! + * \brief Find and store the closest interior neighbor to a vertex. + * \param[in] config - Definition of the particular problem. + */ + void FindNearest_Neighbor(const CConfig* config) override; + /*! * \brief Read the sensitivity from an input file. * \param[in] config - Definition of the particular problem. diff --git a/Common/include/geometry/dual_grid/CVertex.hpp b/Common/include/geometry/dual_grid/CVertex.hpp index 56c195c6e3fe..4a31ee80bdb7 100644 --- a/Common/include/geometry/dual_grid/CVertex.hpp +++ b/Common/include/geometry/dual_grid/CVertex.hpp @@ -45,7 +45,8 @@ class CVertex : public CDualGrid { long PeriodicPoint[5] = {-1}; /*!< \brief Store the periodic point of a boundary (iProcessor, iPoint) */ bool ActDisk_Perimeter = false; /*!< \brief Identify nodes at the perimeter of the actuator disk */ short Rotation_Type; /*!< \brief Type of rotation associated with the vertex (MPI and periodic) */ - unsigned long Normal_Neighbor; /*!< \brief Index of the closest neighbor. */ + unsigned long Normal_Neighbor; /*!< \brief Index of the closest, most normal, neighbor. */ + unsigned long Nearest_Neighbor; /*!< \brief Index of the closest interior neighbor. */ su2double Basis_Function[3] = {0.0}; /*!< \brief Basis function values for interpolation across zones. */ public: @@ -319,4 +320,16 @@ class CVertex : public CDualGrid { * \return Index of the closest neighbor. */ inline unsigned long GetNormal_Neighbor(void) const { return Normal_Neighbor; } + + /*! + * \brief Set the index of the closest interior neighbor to a point on the boundaries. + * \param[in] val_Nearest_Neighbor - Index of the closest neighbor. + */ + inline void SetNearest_Neighbor(unsigned long val_Nearest_Neighbor) { Nearest_Neighbor = val_Nearest_Neighbor; } + + /*! + * \brief Get the value of the closest neighbor. + * \return Index of the closest neighbor. + */ + inline unsigned long GetNearest_Neighbor(void) const { return Nearest_Neighbor; } }; diff --git a/Common/src/geometry/CMultiGridGeometry.cpp b/Common/src/geometry/CMultiGridGeometry.cpp index c3c600e8a124..291df133c94d 100644 --- a/Common/src/geometry/CMultiGridGeometry.cpp +++ b/Common/src/geometry/CMultiGridGeometry.cpp @@ -1089,3 +1089,82 @@ void CMultiGridGeometry::FindNormal_Neighbor(const CConfig* config) { } } } +/*--- We determine the interior node that is closest to the wall node. If there is no + interior node, we have to take the closest wall node. ---*/ +void CMultiGridGeometry::FindNearest_Neighbor(const CConfig* config) { + su2double dist_min; + unsigned long Point_Normal, jPoint; + unsigned short iNeigh, iMarker, jNeigh; + unsigned long iPoint, kPoint, iVertex; + // did we find an interiornode? + bool interiorNode; + + for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { + if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && + config->GetMarker_All_KindBC(iMarker) != INTERNAL_BOUNDARY && + config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { + for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { + iPoint = vertex[iMarker][iVertex]->GetNode(); + const su2double* Coord_i = nodes->GetCoord(iPoint); + + /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ + Point_Normal = 0; + // we use distance + dist_min = 1.0e10; + interiorNode = false; + for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = nodes->GetPoint(iPoint, iNeigh); + const su2double* Coord_j = nodes->GetCoord(jPoint); + + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { + Point_Normal = jPoint; + dist_min = distance; + interiorNode = true; + } + } + + // if we did not find a normal neighbor, then loop over the cells that are connected to the point + if (interiorNode == false) { + // find neighbor nodes to i. + for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = nodes->GetPoint(iPoint, iNeigh); + // now loop over the nodes of the neighbors + for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { + kPoint = nodes->GetPoint(jPoint, jNeigh); + + if (kPoint == iPoint) continue; + + const su2double* Coord_k = nodes->GetCoord(kPoint); + // now find the distance from ipoint to kpoint + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { + Point_Normal = kPoint; + dist_min = distance; + interiorNode = true; + } + } + } + } + + vertex[iMarker][iVertex]->SetNearest_Neighbor(Point_Normal); + } + } + } +} diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 9ce660300af9..b18e040c6bf5 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8170,6 +8170,86 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { } } +/*--- We determine the interior node that is closest to the wall node. If there is no + interior node, we have to take the closest wall node. ---*/ +void CPhysicalGeometry::FindNearest_Neighbor(const CConfig* config) { + su2double dist_min; + unsigned long Point_Normal, jPoint; + unsigned short iNeigh, iMarker, jNeigh; + unsigned long iPoint, kPoint, iVertex; + // did we find an interiornode? + bool interiorNode; + + for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { + if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && + config->GetMarker_All_KindBC(iMarker) != INTERNAL_BOUNDARY && + config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { + for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { + iPoint = vertex[iMarker][iVertex]->GetNode(); + const su2double* Coord_i = nodes->GetCoord(iPoint); + + /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ + Point_Normal = 0; + // we use distance + dist_min = 1.0e10; + interiorNode = false; + for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = nodes->GetPoint(iPoint, iNeigh); + const su2double* Coord_j = nodes->GetCoord(jPoint); + + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { + Point_Normal = jPoint; + dist_min = distance; + interiorNode = true; + } + } + + // if we did not find a normal neighbor, then loop over the cells that are connected to the point + if (interiorNode == false) { + // find neighbor nodes to i. + for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = nodes->GetPoint(iPoint, iNeigh); + // now loop over the nodes of the neighbors + for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { + kPoint = nodes->GetPoint(jPoint, jNeigh); + + if (kPoint == iPoint) continue; + + const su2double* Coord_k = nodes->GetCoord(kPoint); + // now find the distance from ipoint to kpoint + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { + Point_Normal = kPoint; + dist_min = distance; + interiorNode = true; + } + } + } + } + + vertex[iMarker][iVertex]->SetNearest_Neighbor(Point_Normal); + } + } + } +} + void CPhysicalGeometry::SetBoundSensitivity(CConfig* config) { unsigned short iMarker, icommas; unsigned long iVertex, iPoint, (*Point2Vertex)[2], nPointLocal = 0, nPointGlobal = 0; diff --git a/SU2_CFD/src/drivers/CDriver.cpp b/SU2_CFD/src/drivers/CDriver.cpp index 015e808b6269..dd7ad5da513b 100644 --- a/SU2_CFD/src/drivers/CDriver.cpp +++ b/SU2_CFD/src/drivers/CDriver.cpp @@ -777,6 +777,12 @@ void CDriver::InitializeGeometryFVM(CConfig *config, CGeometry **&geometry) { if (rank == MASTER_NODE) cout << "Searching for the closest normal neighbors to the surfaces." << endl; geometry[MESH_0]->FindNormal_Neighbor(config); + /*--- Identify closest interior neighbor, this is a replacement of the FindNormal_Neighbor implementation ---*/ + + if (rank == MASTER_NODE) cout << "Searching for the closest interior neighbors to the surfaces." << endl; + geometry[MESH_0]->FindNearest_Neighbor(config); + + /*--- Store the global to local mapping. ---*/ if (rank == MASTER_NODE) cout << "Storing a mapping from global to local point index." << endl; @@ -833,10 +839,13 @@ void CDriver::InitializeGeometryFVM(CConfig *config, CGeometry **&geometry) { geometry[iMGlevel]->SetBoundControlVolume(geometry[iMGlevel-1], config, ALLOCATE); geometry[iMGlevel]->SetCoord(geometry[iMGlevel-1]); - /*--- Find closest neighbor to a surface point ---*/ + /*--- Find closest, most normal, neighbor to a surface point ---*/ geometry[iMGlevel]->FindNormal_Neighbor(config); + /*--- Find closest interior neighbor to a surface point (eventual replacement of FindNormal_Neighbor) ---*/ + geometry[iMGlevel]->FindNearest_Neighbor(config); + /*--- Store our multigrid index. ---*/ geometry[iMGlevel]->SetMGLevel(iMGlevel); @@ -2517,7 +2526,7 @@ void CDriver::InitializeInterface(CConfig **config, CSolver***** solver, CGeomet else interface_type = NO_TRANSFER; } - + if (interface_type != NO_TRANSFER) { auto nVar = 4; interface[donor][target] = new CConjugateHeatInterface(nVar, 0); diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index 02b91c8ab2cf..33c27733b3e6 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -260,7 +260,8 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai /*--- Check if the node belongs to the domain (i.e, not a halo node) ---*/ if (geometry->nodes->GetDomain(iPoint)) { - const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); + const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNearest_Neighbor(); + //const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); su2double shearStress = 0.0; for(auto iDim = 0u; iDim < nDim; iDim++) { @@ -459,7 +460,8 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont } else { // smooth wall /*--- distance to closest neighbor ---*/ - const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + //const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNearest_Neighbor(); su2double distance2 = GeometryToolbox::SquaredDistance(nDim, geometry->nodes->GetCoord(iPoint), @@ -507,7 +509,8 @@ void CTurbSSTSolver::SetTurbVars_WF(CGeometry *geometry, CSolver **solver_contai for (auto iVertex = 0u; iVertex < geometry->nVertex[val_marker]; iVertex++) { const auto iPoint = geometry->vertex[val_marker][iVertex]->GetNode(); - const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + //const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNearest_Neighbor(); if (!geometry->nodes->GetDomain(iPoint_Neighbor)) continue; su2double Y_Plus = solver_container[FLOW_SOL]->GetYPlus(val_marker, iVertex); From ce27533ebf4aa737e763c42a975d66d01e7e889c Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sun, 15 Dec 2024 21:43:04 +0100 Subject: [PATCH 11/49] restore original normalneighbor --- Common/src/geometry/CPhysicalGeometry.cpp | 75 ++++++----------------- 1 file changed, 19 insertions(+), 56 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index b18e040c6bf5..4d1e90b6dba3 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8089,16 +8089,11 @@ void CPhysicalGeometry::ComputeMeshQualityStatistics(const CConfig* config) { } } -/*--- Note that we do not find the real normal neighbor here, since it usually does not exist. - Instead, we determine the interior node that is closest to the wall node. If there is no - interior node, we have to take the closest wall node. ---*/ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { - su2double dist_min; + su2double cos_max, scalar_prod, norm_vect, norm_Normal, cos_alpha, diff_coord, *Normal; unsigned long Point_Normal, jPoint; - unsigned short iNeigh, iMarker, jNeigh; - unsigned long iPoint, kPoint, iVertex; - // did we find an interiornode? - bool interiorNode; + unsigned short iNeigh, iMarker, iDim; + unsigned long iPoint, iVertex; for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && @@ -8106,64 +8101,32 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { iPoint = vertex[iMarker][iVertex]->GetNode(); - const su2double* Coord_i = nodes->GetCoord(iPoint); + Normal = vertex[iMarker][iVertex]->GetNormal(); /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ Point_Normal = 0; - // we use distance - dist_min = 1.0e10; - interiorNode = false; + cos_max = -1.0; for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { jPoint = nodes->GetPoint(iPoint, iNeigh); - const su2double* Coord_j = nodes->GetCoord(jPoint); - - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; + scalar_prod = 0.0; + norm_vect = 0.0; + norm_Normal = 0.0; + for (iDim = 0; iDim < nDim; iDim++) { + diff_coord = nodes->GetCoord(jPoint, iDim) - nodes->GetCoord(iPoint, iDim); + scalar_prod += diff_coord * Normal[iDim]; + norm_vect += diff_coord * diff_coord; + norm_Normal += Normal[iDim] * Normal[iDim]; } + norm_vect = sqrt(norm_vect); + norm_Normal = sqrt(norm_Normal); + cos_alpha = scalar_prod / (norm_vect * norm_Normal); - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { + /*--- Get maximum cosine ---*/ + if (cos_alpha >= cos_max) { Point_Normal = jPoint; - dist_min = distance; - interiorNode = true; - } - } - - // if we did not find a normal neighbor, then loop over the cells that are connected to the point - if (interiorNode == false) { - // find neighbor nodes to i. - for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { - jPoint = nodes->GetPoint(iPoint, iNeigh); - // now loop over the nodes of the neighbors - for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { - kPoint = nodes->GetPoint(jPoint, jNeigh); - - if (kPoint == iPoint) continue; - - const su2double* Coord_k = nodes->GetCoord(kPoint); - // now find the distance from ipoint to kpoint - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } - - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { - Point_Normal = kPoint; - dist_min = distance; - interiorNode = true; + cos_max = cos_alpha; } } - } - } - vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); } } From 5f8b6ba75627e72202ae98dd261994747cc2909a Mon Sep 17 00:00:00 2001 From: bigfooted Date: Sun, 15 Dec 2024 23:07:37 +0100 Subject: [PATCH 12/49] clang --- Common/src/geometry/CPhysicalGeometry.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 4d1e90b6dba3..91252fc9ed56 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8125,8 +8125,8 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { if (cos_alpha >= cos_max) { Point_Normal = jPoint; cos_max = cos_alpha; - } - } + } + } vertex[iMarker][iVertex]->SetNormal_Neighbor(Point_Normal); } } From f5f2de9aa83b99224193bb6e6c9aae7c94870ec8 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Tue, 7 Jan 2025 17:09:58 +0100 Subject: [PATCH 13/49] cleanup old implementation, start new --- Common/include/geometry/CGeometry.hpp | 6 -- .../include/geometry/CMultiGridGeometry.hpp | 6 -- Common/include/geometry/CPhysicalGeometry.hpp | 6 -- Common/include/geometry/dual_grid/CVertex.hpp | 11 --- Common/src/geometry/CMultiGridGeometry.cpp | 79 --------------- Common/src/geometry/CPhysicalGeometry.cpp | 80 ---------------- .../include/solvers/CFVMFlowSolverBase.hpp | 8 ++ .../include/solvers/CFVMFlowSolverBase.inl | 7 +- SU2_CFD/include/solvers/CSolver.hpp | 8 ++ SU2_CFD/include/solvers/CTurbSSTSolver.hpp | 1 + SU2_CFD/src/drivers/CDriver.cpp | 9 -- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 95 ++++++++++++++++--- 12 files changed, 105 insertions(+), 211 deletions(-) diff --git a/Common/include/geometry/CGeometry.hpp b/Common/include/geometry/CGeometry.hpp index 007a423e4085..738618ba2cd0 100644 --- a/Common/include/geometry/CGeometry.hpp +++ b/Common/include/geometry/CGeometry.hpp @@ -1179,12 +1179,6 @@ class CGeometry { */ inline virtual void FindNormal_Neighbor(const CConfig* config) {} - /*! - * \brief A virtual member. - * \param[in] config - Definition of the particular problem. - */ - inline virtual void FindNearest_Neighbor(const CConfig* config) {} - /*! * \brief A virtual member. */ diff --git a/Common/include/geometry/CMultiGridGeometry.hpp b/Common/include/geometry/CMultiGridGeometry.hpp index cecb65bbd75f..09a3ca06d905 100644 --- a/Common/include/geometry/CMultiGridGeometry.hpp +++ b/Common/include/geometry/CMultiGridGeometry.hpp @@ -128,12 +128,6 @@ class CMultiGridGeometry final : public CGeometry { */ void FindNormal_Neighbor(const CConfig* config) override; - /*! - * \brief Find and store the closest interior neighbor to a vertex. - * \param[in] config - Definition of the particular problem. - */ - void FindNearest_Neighbor(const CConfig* config) override; - /*! * \brief Mach the near field boundary condition. * \param[in] config - Definition of the particular problem. diff --git a/Common/include/geometry/CPhysicalGeometry.hpp b/Common/include/geometry/CPhysicalGeometry.hpp index 8681fbc772f8..3abbdb72ac53 100644 --- a/Common/include/geometry/CPhysicalGeometry.hpp +++ b/Common/include/geometry/CPhysicalGeometry.hpp @@ -565,12 +565,6 @@ class CPhysicalGeometry final : public CGeometry { */ void FindNormal_Neighbor(const CConfig* config) override; - /*! - * \brief Find and store the closest interior neighbor to a vertex. - * \param[in] config - Definition of the particular problem. - */ - void FindNearest_Neighbor(const CConfig* config) override; - /*! * \brief Read the sensitivity from an input file. * \param[in] config - Definition of the particular problem. diff --git a/Common/include/geometry/dual_grid/CVertex.hpp b/Common/include/geometry/dual_grid/CVertex.hpp index 4a31ee80bdb7..9dd4c691386c 100644 --- a/Common/include/geometry/dual_grid/CVertex.hpp +++ b/Common/include/geometry/dual_grid/CVertex.hpp @@ -321,15 +321,4 @@ class CVertex : public CDualGrid { */ inline unsigned long GetNormal_Neighbor(void) const { return Normal_Neighbor; } - /*! - * \brief Set the index of the closest interior neighbor to a point on the boundaries. - * \param[in] val_Nearest_Neighbor - Index of the closest neighbor. - */ - inline void SetNearest_Neighbor(unsigned long val_Nearest_Neighbor) { Nearest_Neighbor = val_Nearest_Neighbor; } - - /*! - * \brief Get the value of the closest neighbor. - * \return Index of the closest neighbor. - */ - inline unsigned long GetNearest_Neighbor(void) const { return Nearest_Neighbor; } }; diff --git a/Common/src/geometry/CMultiGridGeometry.cpp b/Common/src/geometry/CMultiGridGeometry.cpp index 291df133c94d..c3c600e8a124 100644 --- a/Common/src/geometry/CMultiGridGeometry.cpp +++ b/Common/src/geometry/CMultiGridGeometry.cpp @@ -1089,82 +1089,3 @@ void CMultiGridGeometry::FindNormal_Neighbor(const CConfig* config) { } } } -/*--- We determine the interior node that is closest to the wall node. If there is no - interior node, we have to take the closest wall node. ---*/ -void CMultiGridGeometry::FindNearest_Neighbor(const CConfig* config) { - su2double dist_min; - unsigned long Point_Normal, jPoint; - unsigned short iNeigh, iMarker, jNeigh; - unsigned long iPoint, kPoint, iVertex; - // did we find an interiornode? - bool interiorNode; - - for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { - if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && - config->GetMarker_All_KindBC(iMarker) != INTERNAL_BOUNDARY && - config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { - for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { - iPoint = vertex[iMarker][iVertex]->GetNode(); - const su2double* Coord_i = nodes->GetCoord(iPoint); - - /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ - Point_Normal = 0; - // we use distance - dist_min = 1.0e10; - interiorNode = false; - for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { - jPoint = nodes->GetPoint(iPoint, iNeigh); - const su2double* Coord_j = nodes->GetCoord(jPoint); - - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } - - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { - Point_Normal = jPoint; - dist_min = distance; - interiorNode = true; - } - } - - // if we did not find a normal neighbor, then loop over the cells that are connected to the point - if (interiorNode == false) { - // find neighbor nodes to i. - for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { - jPoint = nodes->GetPoint(iPoint, iNeigh); - // now loop over the nodes of the neighbors - for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { - kPoint = nodes->GetPoint(jPoint, jNeigh); - - if (kPoint == iPoint) continue; - - const su2double* Coord_k = nodes->GetCoord(kPoint); - // now find the distance from ipoint to kpoint - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } - - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { - Point_Normal = kPoint; - dist_min = distance; - interiorNode = true; - } - } - } - } - - vertex[iMarker][iVertex]->SetNearest_Neighbor(Point_Normal); - } - } - } -} diff --git a/Common/src/geometry/CPhysicalGeometry.cpp b/Common/src/geometry/CPhysicalGeometry.cpp index 91252fc9ed56..6e34e715be59 100644 --- a/Common/src/geometry/CPhysicalGeometry.cpp +++ b/Common/src/geometry/CPhysicalGeometry.cpp @@ -8133,86 +8133,6 @@ void CPhysicalGeometry::FindNormal_Neighbor(const CConfig* config) { } } -/*--- We determine the interior node that is closest to the wall node. If there is no - interior node, we have to take the closest wall node. ---*/ -void CPhysicalGeometry::FindNearest_Neighbor(const CConfig* config) { - su2double dist_min; - unsigned long Point_Normal, jPoint; - unsigned short iNeigh, iMarker, jNeigh; - unsigned long iPoint, kPoint, iVertex; - // did we find an interiornode? - bool interiorNode; - - for (iMarker = 0; iMarker < config->GetnMarker_All(); iMarker++) { - if (config->GetMarker_All_KindBC(iMarker) != SEND_RECEIVE && - config->GetMarker_All_KindBC(iMarker) != INTERNAL_BOUNDARY && - config->GetMarker_All_KindBC(iMarker) != NEARFIELD_BOUNDARY) { - for (iVertex = 0; iVertex < nVertex[iMarker]; iVertex++) { - iPoint = vertex[iMarker][iVertex]->GetNode(); - const su2double* Coord_i = nodes->GetCoord(iPoint); - - /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ - Point_Normal = 0; - // we use distance - dist_min = 1.0e10; - interiorNode = false; - for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { - jPoint = nodes->GetPoint(iPoint, iNeigh); - const su2double* Coord_j = nodes->GetCoord(jPoint); - - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } - - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { - Point_Normal = jPoint; - dist_min = distance; - interiorNode = true; - } - } - - // if we did not find a normal neighbor, then loop over the cells that are connected to the point - if (interiorNode == false) { - // find neighbor nodes to i. - for (iNeigh = 0; iNeigh < nodes->GetnPoint(iPoint); iNeigh++) { - jPoint = nodes->GetPoint(iPoint, iNeigh); - // now loop over the nodes of the neighbors - for (jNeigh = 0; jNeigh < nodes->GetnPoint(jPoint); jNeigh++) { - kPoint = nodes->GetPoint(jPoint, jNeigh); - - if (kPoint == iPoint) continue; - - const su2double* Coord_k = nodes->GetCoord(kPoint); - // now find the distance from ipoint to kpoint - su2double distance = 0.0; - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_k[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } - - // Take the interior node that is closest to the wall node. - if ((nodes->GetViscousBoundary(kPoint) == false) && (distance < dist_min)) { - Point_Normal = kPoint; - dist_min = distance; - interiorNode = true; - } - } - } - } - - vertex[iMarker][iVertex]->SetNearest_Neighbor(Point_Normal); - } - } - } -} - void CPhysicalGeometry::SetBoundSensitivity(CConfig* config) { unsigned short iMarker, icommas; unsigned long iVertex, iPoint, (*Point2Vertex)[2], nPointLocal = 0, nPointGlobal = 0; diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp b/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp index 2aa31880baea..d5ed37c18487 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp @@ -2419,6 +2419,14 @@ class CFVMFlowSolverBase : public CSolver { return YPlus[val_marker][val_vertex]; } + /*! + * \brief Set the y plus. + * \param[in] val_yplus - new value of yplus + */ + inline void SetYPlus(su2double val_yplus, unsigned short val_marker, unsigned long val_vertex) final { + YPlus[val_marker][val_vertex] = val_yplus; + } + /*! * \brief Get the u_tau . * \param[in] val_marker - Surface marker where the coefficient is computed. diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl index d7a634e82271..6db04c401113 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl @@ -2498,10 +2498,15 @@ void CFVMFlowSolverBase::Friction_Forces(const CGeometry* geometr FrictionVel = sqrt(fabs(WallShearStress[iMarker][iVertex]) / Density); if (!wallfunctions && (MGLevel == MESH_0 || geometry->nodes->GetDomain(iPoint))) { - // for CMultiGridGeometry, the normal neighbor of halo nodes in not set + // for CMultiGridGeometry, the normal neighbor of halo nodes is not set iPointNormal = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); Coord_Normal = geometry->nodes->GetCoord(iPointNormal); WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); + //nijso: we can modifiy y+ as well now? + + + + YPlus[iMarker][iVertex] = WallDistMod * FrictionVel / (Viscosity / Density); } diff --git a/SU2_CFD/include/solvers/CSolver.hpp b/SU2_CFD/include/solvers/CSolver.hpp index 2ed78a78a9be..343c2fec26a1 100644 --- a/SU2_CFD/include/solvers/CSolver.hpp +++ b/SU2_CFD/include/solvers/CSolver.hpp @@ -2989,6 +2989,14 @@ class CSolver { */ inline virtual su2double GetYPlus(unsigned short val_marker, unsigned long val_vertex) const { return 0; } + /*! + * \brief A virtual member. + * \param[in] val_marker - Surface marker where the coefficient is computed. + * \param[in] val_vertex - Vertex of the marker val_marker where the coefficient is evaluated. + * \return Value of the y plus. + */ + inline virtual void SetYPlus(su2double val_yplus, unsigned short val_marker, unsigned long val_vertex) {}; + /*! * \brief A virtual member. * \param[in] val_marker - Surface marker where the coefficient is computed. diff --git a/SU2_CFD/include/solvers/CTurbSSTSolver.hpp b/SU2_CFD/include/solvers/CTurbSSTSolver.hpp index 78aa77200950..506797769fd8 100644 --- a/SU2_CFD/include/solvers/CTurbSSTSolver.hpp +++ b/SU2_CFD/include/solvers/CTurbSSTSolver.hpp @@ -302,5 +302,6 @@ class CTurbSSTSolver final : public CTurbSolver { */ inline su2double GetOmega_Inf(void) const override { return Solution_Inf[1]; } + su2double GetNearest_Neighbor(CGeometry *geometry, unsigned long iPoint,unsigned short iMarker, unsigned long iVertex); }; diff --git a/SU2_CFD/src/drivers/CDriver.cpp b/SU2_CFD/src/drivers/CDriver.cpp index dd7ad5da513b..047650701075 100644 --- a/SU2_CFD/src/drivers/CDriver.cpp +++ b/SU2_CFD/src/drivers/CDriver.cpp @@ -777,12 +777,6 @@ void CDriver::InitializeGeometryFVM(CConfig *config, CGeometry **&geometry) { if (rank == MASTER_NODE) cout << "Searching for the closest normal neighbors to the surfaces." << endl; geometry[MESH_0]->FindNormal_Neighbor(config); - /*--- Identify closest interior neighbor, this is a replacement of the FindNormal_Neighbor implementation ---*/ - - if (rank == MASTER_NODE) cout << "Searching for the closest interior neighbors to the surfaces." << endl; - geometry[MESH_0]->FindNearest_Neighbor(config); - - /*--- Store the global to local mapping. ---*/ if (rank == MASTER_NODE) cout << "Storing a mapping from global to local point index." << endl; @@ -843,9 +837,6 @@ void CDriver::InitializeGeometryFVM(CConfig *config, CGeometry **&geometry) { geometry[iMGlevel]->FindNormal_Neighbor(config); - /*--- Find closest interior neighbor to a surface point (eventual replacement of FindNormal_Neighbor) ---*/ - geometry[iMGlevel]->FindNearest_Neighbor(config); - /*--- Store our multigrid index. ---*/ geometry[iMGlevel]->SetMGLevel(iMGlevel); diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index 33c27733b3e6..a29c3f8b4851 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -259,9 +259,10 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai /*--- Check if the node belongs to the domain (i.e, not a halo node) ---*/ + if (geometry->nodes->GetDomain(iPoint)) { - const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNearest_Neighbor(); - //const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); + + const auto jPoint = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); su2double shearStress = 0.0; for(auto iDim = 0u; iDim < nDim; iDim++) { @@ -270,7 +271,8 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai shearStress = sqrt(shearStress); const su2double FrictionVelocity = sqrt(shearStress/flowNodes->GetDensity(iPoint)); - const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint); + //const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint); + const su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,iMarker,iVertex); const su2double Derivative = flowNodes->GetLaminarViscosity(jPoint) * pow(nodes->GetSolution(jPoint, 0), 0.673) / wall_dist; const su2double turbulence_index = 6.1 * Derivative / pow(FrictionVelocity, 2.346); @@ -460,12 +462,12 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont } else { // smooth wall /*--- distance to closest neighbor ---*/ - //const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); - const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNearest_Neighbor(); + const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + const su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,val_marker, iVertex); - su2double distance2 = GeometryToolbox::SquaredDistance(nDim, - geometry->nodes->GetCoord(iPoint), - geometry->nodes->GetCoord(jPoint)); + //su2double distance2 = GeometryToolbox::SquaredDistance(nDim, + // geometry->nodes->GetCoord(iPoint), + // geometry->nodes->GetCoord(jPoint)); /*--- Set wall values ---*/ su2double density = solver_container[FLOW_SOL]->GetNodes()->GetDensity(jPoint); @@ -474,7 +476,7 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont su2double beta_1 = constants[4]; su2double solution[MAXNVAR]; solution[0] = 0.0; - solution[1] = 60.0*laminar_viscosity/(density*beta_1*distance2); + solution[1] = 60.0*laminar_viscosity/(density*beta_1*wall_dist*wall_dist); /*--- Set the solution values and zero the residual ---*/ nodes->SetSolution_Old(iPoint,solution); @@ -509,8 +511,7 @@ void CTurbSSTSolver::SetTurbVars_WF(CGeometry *geometry, CSolver **solver_contai for (auto iVertex = 0u; iVertex < geometry->nVertex[val_marker]; iVertex++) { const auto iPoint = geometry->vertex[val_marker][iVertex]->GetNode(); - //const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); - const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNearest_Neighbor(); + const auto iPoint_Neighbor = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); if (!geometry->nodes->GetDomain(iPoint_Neighbor)) continue; su2double Y_Plus = solver_container[FLOW_SOL]->GetYPlus(val_marker, iVertex); @@ -1015,8 +1016,7 @@ su2double CTurbSSTSolver::GetInletAtVertex(unsigned short iMarker, unsigned long su2double Normal[MAXNDIM] = {0.0}; geometry->vertex[iMarker][iVertex]->GetNormal(Normal); - return GeometryToolbox::Norm(nDim, Normal); -} + return GeometryToolbox::Norm(nDim, Normal);} void CTurbSSTSolver::SetUniformInlet(const CConfig* config, unsigned short iMarker) { if (config->GetMarker_All_KindBC(iMarker) == INLET_FLOW) { @@ -1027,3 +1027,72 @@ void CTurbSSTSolver::SetUniformInlet(const CConfig* config, unsigned short iMark } } + +/*--- We determine the interior node that is closest to the wall node. If there is no + interior node, we have to take the closest wall node. ---*/ +su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned long iPoint, unsigned short iMarker, unsigned long iVertex) { + su2double dist_min; + su2double distance = 0.0; + unsigned long Point_Normal, jPoint; + unsigned short iNeigh, jNeigh; + unsigned long kPoint; + + const su2double* Coord_i = geometry->nodes->GetCoord(iPoint); + + /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ + Point_Normal = 0; + // we use distance + dist_min = 1.0e10; + for (iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); iNeigh++) { + jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); + const su2double* Coord_j = geometry->nodes->GetCoord(jPoint); + + su2double distance = 0.0; + vector edgeVector(nDim); + for (unsigned short iDim = 0; iDim < nDim; iDim++) { + edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; + // squared distance + distance += edgeVector[iDim] * edgeVector[iDim]; + } + + // Take the interior node that is closest to the wall node. + if ((geometry->nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { + Point_Normal = jPoint; + dist_min = distance; + } + } + + if (jPoint==0) { + su2double Area = 0.0; + su2double TwoVol = 2.0* (geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint)); + for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); ++iNeigh) { + size_t iEdge = geometry->nodes->GetEdge(iPoint, iNeigh); + size_t jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); + + /*--- Determine if edge points inwards or outwards of iPoint. + * If inwards we need to flip the area vector. ---*/ + + su2double dir = (iPoint < jPoint) ? 1.0 : -1.0; + su2double weight = dir * TwoVol; + const su2double* Normal = geometry->edges->GetNormal(iEdge); + Area = GeometryToolbox::Norm(nDim, Normal); + + + //thscale += TwoVol * geometry->edges->GetNormal(iEdge); + dist_min += TwoVol * Area; + } + } + + // old value of yplus + su2double yplus = GetYPlus(iMarker,iVertex); + unsigned long iPointNormal = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); + const su2double *Coord_Normal = geometry->nodes->GetCoord(iPointNormal); + const su2double *Coord = geometry->nodes->GetCoord(iPoint); + + su2double WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); + // new value of y+ + yplus = dist_min * (yplus / WallDistMod); + SetYPlus(yplus,iMarker,iVertex); + + return (dist_min); +} From 47f383952aefdda2499f361a3665b95f901b4991 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Wed, 8 Jan 2025 00:19:05 +0100 Subject: [PATCH 14/49] small update --- Common/include/geometry/dual_grid/CVertex.hpp | 1 - SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 15 +++++---------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/Common/include/geometry/dual_grid/CVertex.hpp b/Common/include/geometry/dual_grid/CVertex.hpp index 9dd4c691386c..26c1c2304079 100644 --- a/Common/include/geometry/dual_grid/CVertex.hpp +++ b/Common/include/geometry/dual_grid/CVertex.hpp @@ -320,5 +320,4 @@ class CVertex : public CDualGrid { * \return Index of the closest neighbor. */ inline unsigned long GetNormal_Neighbor(void) const { return Normal_Neighbor; } - }; diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index a29c3f8b4851..e099c72eb950 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -271,7 +271,7 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai shearStress = sqrt(shearStress); const su2double FrictionVelocity = sqrt(shearStress/flowNodes->GetDensity(iPoint)); - //const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint); + /*const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint);*/ const su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,iMarker,iVertex); const su2double Derivative = flowNodes->GetLaminarViscosity(jPoint) * pow(nodes->GetSolution(jPoint, 0), 0.673) / wall_dist; const su2double turbulence_index = 6.1 * Derivative / pow(FrictionVelocity, 2.346); @@ -1034,8 +1034,7 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon su2double dist_min; su2double distance = 0.0; unsigned long Point_Normal, jPoint; - unsigned short iNeigh, jNeigh; - unsigned long kPoint; + unsigned short jNeigh; const su2double* Coord_i = geometry->nodes->GetCoord(iPoint); @@ -1043,11 +1042,10 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon Point_Normal = 0; // we use distance dist_min = 1.0e10; - for (iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); iNeigh++) { + for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); iNeigh++) { jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); const su2double* Coord_j = geometry->nodes->GetCoord(jPoint); - su2double distance = 0.0; vector edgeVector(nDim); for (unsigned short iDim = 0; iDim < nDim; iDim++) { edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; @@ -1067,7 +1065,6 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon su2double TwoVol = 2.0* (geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint)); for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); ++iNeigh) { size_t iEdge = geometry->nodes->GetEdge(iPoint, iNeigh); - size_t jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); /*--- Determine if edge points inwards or outwards of iPoint. * If inwards we need to flip the area vector. ---*/ @@ -1077,9 +1074,7 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon const su2double* Normal = geometry->edges->GetNormal(iEdge); Area = GeometryToolbox::Norm(nDim, Normal); - - //thscale += TwoVol * geometry->edges->GetNormal(iEdge); - dist_min += TwoVol * Area; + dist_min += weight * Area; } } @@ -1092,7 +1087,7 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon su2double WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); // new value of y+ yplus = dist_min * (yplus / WallDistMod); - SetYPlus(yplus,iMarker,iVertex); + SetYPlus(yplus,iMarker,iVertex); return (dist_min); } From 55d21630822b66255eaac1bf97d1ae768bdb260c Mon Sep 17 00:00:00 2001 From: bigfooted Date: Thu, 9 Jan 2025 07:57:41 +0100 Subject: [PATCH 15/49] update --- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index e099c72eb950..bb55633aa8e0 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -1034,7 +1034,6 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon su2double dist_min; su2double distance = 0.0; unsigned long Point_Normal, jPoint; - unsigned short jNeigh; const su2double* Coord_i = geometry->nodes->GetCoord(iPoint); @@ -1069,12 +1068,13 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon /*--- Determine if edge points inwards or outwards of iPoint. * If inwards we need to flip the area vector. ---*/ - su2double dir = (iPoint < jPoint) ? 1.0 : -1.0; - su2double weight = dir * TwoVol; + //su2double dir = (iPoint < jPoint) ? 1.0 : -1.0; + //su2double weight = dir * TwoVol; const su2double* Normal = geometry->edges->GetNormal(iEdge); Area = GeometryToolbox::Norm(nDim, Normal); - dist_min += weight * Area; + //dist_min += weight * Area; + dist_min += TwoVol * Area; } } From 535c841c5c0355605b802db15c3ca60f2698666e Mon Sep 17 00:00:00 2001 From: bigfooted Date: Fri, 10 Jan 2025 11:00:33 +0100 Subject: [PATCH 16/49] update --- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 65 ++++++++++++++------------ 1 file changed, 36 insertions(+), 29 deletions(-) diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index bb55633aa8e0..f396fd8a419e 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -271,8 +271,12 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai shearStress = sqrt(shearStress); const su2double FrictionVelocity = sqrt(shearStress/flowNodes->GetDensity(iPoint)); - /*const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint);*/ + const su2double wall_dist_old = geometry->nodes->GetWall_Distance(jPoint); + const su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,iMarker,iVertex); + + cout << "************************* wall distance old = " << wall_dist_old << " , wall distance new = " << wall_dist << endl; + const su2double Derivative = flowNodes->GetLaminarViscosity(jPoint) * pow(nodes->GetSolution(jPoint, 0), 0.673) / wall_dist; const su2double turbulence_index = 6.1 * Derivative / pow(FrictionVelocity, 2.346); @@ -462,21 +466,24 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont } else { // smooth wall /*--- distance to closest neighbor ---*/ - const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); - const su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,val_marker, iVertex); + su2double wall_dist = GetNearest_Neighbor(geometry,iPoint,val_marker, iVertex); - //su2double distance2 = GeometryToolbox::SquaredDistance(nDim, - // geometry->nodes->GetCoord(iPoint), - // geometry->nodes->GetCoord(jPoint)); + const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); + su2double distance2 = GeometryToolbox::SquaredDistance(nDim, + geometry->nodes->GetCoord(iPoint), + geometry->nodes->GetCoord(jPoint)); /*--- Set wall values ---*/ + if (wall_dist < 1.0e-12) {cout <<"setting walldist to " << sqrt(distance2) << endl; wall_dist = sqrt(distance2);} + su2double density = solver_container[FLOW_SOL]->GetNodes()->GetDensity(jPoint); su2double laminar_viscosity = solver_container[FLOW_SOL]->GetNodes()->GetLaminarViscosity(jPoint); su2double beta_1 = constants[4]; su2double solution[MAXNVAR]; solution[0] = 0.0; - solution[1] = 60.0*laminar_viscosity/(density*beta_1*wall_dist*wall_dist); + //solution[1] = 60.0*laminar_viscosity/(density*beta_1*wall_dist*wall_dist); + solution[1] = 60.0*laminar_viscosity/(density*beta_1*distance2); /*--- Set the solution values and zero the residual ---*/ nodes->SetSolution_Old(iPoint,solution); @@ -1040,26 +1047,24 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ Point_Normal = 0; // we use distance - dist_min = 1.0e10; + dist_min = 0.0; for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); iNeigh++) { jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); - const su2double* Coord_j = geometry->nodes->GetCoord(jPoint); - - vector edgeVector(nDim); - for (unsigned short iDim = 0; iDim < nDim; iDim++) { - edgeVector[iDim] = Coord_j[iDim] - Coord_i[iDim]; - // squared distance - distance += edgeVector[iDim] * edgeVector[iDim]; - } + su2double distance2 = GeometryToolbox::SquaredDistance(nDim, + geometry->nodes->GetCoord(iPoint), + geometry->nodes->GetCoord(jPoint)); // Take the interior node that is closest to the wall node. if ((geometry->nodes->GetViscousBoundary(jPoint) == false) && (distance < dist_min)) { Point_Normal = jPoint; - dist_min = distance; + dist_min = sqrt(distance2); } } - if (jPoint==0) { + + //if (jPoint==0) { + if (Point_Normal==0) { + cout << "no point found at i = " << iPoint << endl; su2double Area = 0.0; su2double TwoVol = 2.0* (geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint)); for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); ++iNeigh) { @@ -1073,21 +1078,23 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon const su2double* Normal = geometry->edges->GetNormal(iEdge); Area = GeometryToolbox::Norm(nDim, Normal); - //dist_min += weight * Area; - dist_min += TwoVol * Area; + dist_min += TwoVol / Area; + cout << " distmin = " << dist_min << " , vol = "<GetNodes()->GetDensity(jPoint); su2double laminar_viscosity = solver_container[FLOW_SOL]->GetNodes()->GetLaminarViscosity(jPoint); su2double beta_1 = constants[4]; su2double solution[MAXNVAR]; solution[0] = 0.0; - //solution[1] = 60.0*laminar_viscosity/(density*beta_1*wall_dist*wall_dist); - solution[1] = 60.0*laminar_viscosity/(density*beta_1*distance2); + solution[1] = 60.0*laminar_viscosity/(density*beta_1*wall_dist*wall_dist); + //solution[1] = 60.0*laminar_viscosity/(density*beta_1*distance2); /*--- Set the solution values and zero the residual ---*/ nodes->SetSolution_Old(iPoint,solution); @@ -1042,8 +1040,6 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon su2double distance = 0.0; unsigned long Point_Normal, jPoint; - const su2double* Coord_i = geometry->nodes->GetCoord(iPoint); - /*--- Compute closest normal neighbor, note that the normal are oriented inwards ---*/ Point_Normal = 0; // we use distance @@ -1062,19 +1058,13 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon } - //if (jPoint==0) { if (Point_Normal==0) { cout << "no point found at i = " << iPoint << endl; su2double Area = 0.0; su2double TwoVol = 2.0* (geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint)); for (size_t iNeigh = 0; iNeigh < geometry->nodes->GetnPoint(iPoint); ++iNeigh) { size_t iEdge = geometry->nodes->GetEdge(iPoint, iNeigh); - - /*--- Determine if edge points inwards or outwards of iPoint. - * If inwards we need to flip the area vector. ---*/ - - //su2double dir = (iPoint < jPoint) ? 1.0 : -1.0; - //su2double weight = dir * TwoVol; + size_t jPoint = geometry->nodes->GetPoint(iPoint, iNeigh); const su2double* Normal = geometry->edges->GetNormal(iEdge); Area = GeometryToolbox::Norm(nDim, Normal); @@ -1082,19 +1072,7 @@ su2double CTurbSSTSolver::GetNearest_Neighbor(CGeometry *geometry, unsigned lon cout << " distmin = " << dist_min << " , vol = "< Date: Wed, 15 Jan 2025 23:43:39 +0100 Subject: [PATCH 23/49] regression update --- TestCases/hybrid_regression.py | 22 ++++++------- TestCases/hybrid_regression_AD.py | 2 +- TestCases/parallel_regression.py | 50 ++++++++++++++--------------- TestCases/parallel_regression_AD.py | 2 +- TestCases/serial_regression.py | 32 +++++++++--------- TestCases/serial_regression_AD.py | 2 +- TestCases/tutorials.py | 4 +-- TestCases/vandv.py | 6 ++-- 8 files changed, 60 insertions(+), 60 deletions(-) diff --git a/TestCases/hybrid_regression.py b/TestCases/hybrid_regression.py index da3af4f5c9dc..14c6c66b0aa4 100644 --- a/TestCases/hybrid_regression.py +++ b/TestCases/hybrid_regression.py @@ -206,7 +206,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-12.105781, -15.277738, -6.210248, 1.049757, 0.019249, -2.807857, 0] + turb_naca0012_sst.test_vals = [-8.493861, -10.747240, -4.507971, 1.047913, 0.019156, -1.585577, 0.000000] test_list.append(turb_naca0012_sst) # NACA0012 (SST_SUST, FUN3D finest grid results: CL=1.0840, CD=0.01253) @@ -214,7 +214,7 @@ def main(): turb_naca0012_sst_sust.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust.test_iter = 10 - turb_naca0012_sst_sust.test_vals = [-12.082157, -14.827303, -6.061342, 1.000276, 0.019495, -1.762311] + turb_naca0012_sst_sust.test_vals = [-7.985914, -10.322645, -3.314244, 0.995006, 0.019294, -1.538068] test_list.append(turb_naca0012_sst_sust) # NACA0012 (SST, fixed values for turbulence quantities) @@ -222,7 +222,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.192504, -10.035367, -1.617698, 1.022029, 0.040310, -2.381926] + turb_naca0012_sst_fixedvalues.test_vals = [-5.192503, -10.035788, -1.617649, 1.022030, 0.040310, -2.381936] test_list.append(turb_naca0012_sst_fixedvalues) # NACA0012 (SST, explicit Euler for flow and turbulence equations) @@ -250,7 +250,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-12.070954, -7.407644, -8.698118, -4.008751, 0] + axi_rans_air_nozzle_restart.test_vals = [-6.046200, -0.482494, -2.228367, 2.466115, 0.000000] test_list.append(axi_rans_air_nozzle_restart) ################################# @@ -263,7 +263,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 20 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.644702, -7.433663, -1.918163, -0.000003, 0.079111] + turb_naca0012_sst_restart_mg.test_vals = [-7.644626, -7.427011, -0.631753, -0.000007, 0.079118] test_list.append(turb_naca0012_sst_restart_mg) ############################# @@ -275,7 +275,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.976788, 1.141064, 0.246262, -0.116795] + turb_naca0012_1c.test_vals = [-4.976788, 1.141079, 0.246365, -0.116758] turb_naca0012_1c.test_vals_aarch64 = [-4.981105, 1.138873, 0.248013, -0.117248] test_list.append(turb_naca0012_1c) @@ -302,7 +302,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.114413, 1.076465, 0.227286, -0.123574] + turb_naca0012_p1c1.test_vals = [-5.114407, 1.076496, 0.227388, -0.123537] turb_naca0012_p1c1.test_vals_aarch64 = [-5.132358, 1.075658, 0.337268, -0.082827] test_list.append(turb_naca0012_p1c1) @@ -411,7 +411,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.270637, 0.018416, 0.000004, 0.307678] + inc_turb_naca0012_sst_sust.test_vals = [-7.317191, 0.018255, 0.000004, 0.307677] test_list.append(inc_turb_naca0012_sst_sust) # Weakly coupled heat equation @@ -452,7 +452,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-2.560839, -1.173497, 0.061188, 1.399403, 2.220575, 1.399351, 2.218781, 0] + square_cylinder.test_vals = [-2.560839, -1.173496, 0.061335, 1.399403, 2.220575, 1.399351, 2.218781, 0.000000] square_cylinder.test_vals_aarch64 = [-2.557902, -1.173574, 0.058050, 1.399794, 2.220402, 1.399748, 2.218604, 0] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -556,7 +556,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-10.467026, -2.871699, -19.214627, -13.508254, -11.582396, -6.306163, 73273, 73273, 0.019884, 82.491] + Jones_tc_restart.test_vals = [-3.501035, -0.855391, -11.767172, -6.117423, -9.432832, -3.573397, 73273.000000, 73273.000000, 0.019884, 82.491000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -657,7 +657,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.773513, -1.700012] + bars_SST_2D.test_vals = [13.000000, -0.726398, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) diff --git a/TestCases/hybrid_regression_AD.py b/TestCases/hybrid_regression_AD.py index 3cc8adf1a686..1abcbcc9e87d 100644 --- a/TestCases/hybrid_regression_AD.py +++ b/TestCases/hybrid_regression_AD.py @@ -86,7 +86,7 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.234104, -0.198500, 2.763900, -0.039720] + discadj_rans_naca0012_sst.test_vals = [-2.234037, -0.198500, 2.769200, -0.039720] test_list.append(discadj_rans_naca0012_sst) ####################################### diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index 530328b52a64..d9c38c9f095b 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -365,7 +365,7 @@ def main(): rae2822_sst.cfg_dir = "rans/rae2822" rae2822_sst.cfg_file = "turb_SST_RAE2822.cfg" rae2822_sst.test_iter = 20 - rae2822_sst.test_vals = [-0.510369, 4.870643, 0.816647, 0.061833, 0.000000] + rae2822_sst.test_vals = [-0.510369, 4.870657, 0.816646, 0.061832, 0.000000] test_list.append(rae2822_sst) # RAE2822 SST_SUST @@ -373,7 +373,7 @@ def main(): rae2822_sst_sust.cfg_dir = "rans/rae2822" rae2822_sst_sust.cfg_file = "turb_SST_SUST_RAE2822.cfg" rae2822_sst_sust.test_iter = 20 - rae2822_sst_sust.test_vals = [-2.537339, 4.870643, 0.816647, 0.061833] + rae2822_sst_sust.test_vals = [-2.537371, 4.870656, 0.816646, 0.061832] test_list.append(rae2822_sst_sust) # Flat plate @@ -397,7 +397,7 @@ def main(): turb_flatplate_CC_Wilcox.cfg_dir = "rans/flatplate" turb_flatplate_CC_Wilcox.cfg_file = "turb_SST_flatplate_compressibility_Wilcox.cfg" turb_flatplate_CC_Wilcox.test_iter = 20 - turb_flatplate_CC_Wilcox.test_vals = [-1.280875, 1.974212, 1.440458, 5.038402, -4.051125, 8.521136] + turb_flatplate_CC_Wilcox.test_vals = [-1.280875, 1.974212, 1.440454, 5.038401, -4.047412, 11.905193] test_list.append(turb_flatplate_CC_Wilcox) # Flat plate SST compressibility correction Sarkar @@ -405,7 +405,7 @@ def main(): turb_flatplate_CC_Sarkar.cfg_dir = "rans/flatplate" turb_flatplate_CC_Sarkar.cfg_file = "turb_SST_flatplate_compressibility_Sarkar.cfg" turb_flatplate_CC_Sarkar.test_iter = 20 - turb_flatplate_CC_Sarkar.test_vals = [-1.280875, 1.974212, 1.440458, 5.038402, -4.051128, 8.521136] + turb_flatplate_CC_Sarkar.test_vals = [-1.280875, 1.974212, 1.440454, 5.038401, -4.047415, 11.905193] test_list.append(turb_flatplate_CC_Sarkar) # ONERA M6 Wing @@ -450,7 +450,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] + turb_naca0012_sst.test_vals = [-8.515763, -10.746560, -4.508015, 1.047852, 0.019161, -1.928310, 0.000000] turb_naca0012_sst.test_vals_aarch64 = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -460,7 +460,7 @@ def main(): turb_naca0012_sst_sust.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust.test_iter = 10 - turb_naca0012_sst_sust.test_vals = [-12.087234, -14.827336, -6.062338, 1.000276, 0.019495, -1.779654] + turb_naca0012_sst_sust.test_vals = [-8.014970, -10.320396, -3.314234, 0.994867, 0.019306, -1.983851] turb_naca0012_sst_sust.test_vals_aarch64 = [-12.087234, -14.827336, -6.062338, 1.000276, 0.019495, -1.779654] turb_naca0012_sst_sust.timeout = 3200 test_list.append(turb_naca0012_sst_sust) @@ -470,7 +470,7 @@ def main(): turb_naca0012_sst_2003_Vm.cfg_dir = "rans/naca0012" turb_naca0012_sst_2003_Vm.cfg_file = "turb_NACA0012_sst_2003-Vm.cfg" turb_naca0012_sst_2003_Vm.test_iter = 10 - turb_naca0012_sst_2003_Vm.test_vals = [-7.662107, -10.010518, -3.354064, 1.048299, 0.019832, -2.071125] + turb_naca0012_sst_2003_Vm.test_vals = [-7.632098, -10.013971, -3.340316, 1.046165, 0.019728, -2.059096] turb_naca0012_sst_2003_Vm.timeout = 3200 test_list.append(turb_naca0012_sst_2003_Vm) @@ -479,7 +479,7 @@ def main(): turb_naca0012_sst_1994_KLm.cfg_dir = "rans/naca0012" turb_naca0012_sst_1994_KLm.cfg_file = "turb_NACA0012_sst_1994-KLm.cfg" turb_naca0012_sst_1994_KLm.test_iter = 10 - turb_naca0012_sst_1994_KLm.test_vals = [-8.560764, -10.801276, -3.996309, 1.049043, 0.019285, -1.809924] + turb_naca0012_sst_1994_KLm.test_vals = [-8.334601, -10.630535, -3.933399, 1.047158, 0.019197, -1.876800] turb_naca0012_sst_1994_KLm.timeout = 3200 test_list.append(turb_naca0012_sst_1994_KLm) @@ -489,7 +489,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.216625, -10.018477, -1.615201, 1.021842, 0.040325, -3.728658] + turb_naca0012_sst_fixedvalues.test_vals = [-5.216624, -10.018910, -1.615147, 1.021843, 0.040325, -3.728934] turb_naca0012_sst_fixedvalues.timeout = 3200 test_list.append(turb_naca0012_sst_fixedvalues) @@ -530,7 +530,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-12.071395, -7.467871, -8.649076, -3.995810, 0] + axi_rans_air_nozzle_restart.test_vals = [-6.038034, -0.474087, -2.205683, 2.476084, 0.000000] axi_rans_air_nozzle_restart.tol = 0.0001 test_list.append(axi_rans_air_nozzle_restart) @@ -544,7 +544,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 20 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.612353, -7.432347, -1.918249, -0.000013, 0.079110] + turb_naca0012_sst_restart_mg.test_vals = [-7.612218, -7.425695, -0.631759, -0.000022, 0.079116] turb_naca0012_sst_restart_mg.timeout = 3200 turb_naca0012_sst_restart_mg.tol = 0.000001 test_list.append(turb_naca0012_sst_restart_mg) @@ -646,7 +646,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.270578, 0.018403, -0.000001, 0.307688] + inc_turb_naca0012_sst_sust.test_vals = [-7.316933, 0.018242, -0.000001, 0.307687] test_list.append(inc_turb_naca0012_sst_sust) #################### @@ -881,7 +881,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.980989, 1.139850, 0.469677, -0.081426] + turb_naca0012_1c.test_vals = [-4.980989, 1.139860, 0.469698, -0.081433] test_list.append(turb_naca0012_1c) # NACA0012 2c @@ -889,7 +889,7 @@ def main(): turb_naca0012_2c.cfg_dir = "rans_uq/naca0012" turb_naca0012_2c.cfg_file = "turb_NACA0012_uq_2c.cfg" turb_naca0012_2c.test_iter = 10 - turb_naca0012_2c.test_vals = [-5.484979, 0.968118, 0.320621, -0.114603] + turb_naca0012_2c.test_vals = [-5.484979, 0.968141, 0.320681, -0.114600] test_list.append(turb_naca0012_2c) # NACA0012 3c @@ -897,7 +897,7 @@ def main(): turb_naca0012_3c.cfg_dir = "rans_uq/naca0012" turb_naca0012_3c.cfg_file = "turb_NACA0012_uq_3c.cfg" turb_naca0012_3c.test_iter = 10 - turb_naca0012_3c.test_vals = [-5.584315, 0.931258, 0.277047, -0.118255] + turb_naca0012_3c.test_vals = [-5.584315, 0.931289, 0.277094, -0.118251] test_list.append(turb_naca0012_3c) # NACA0012 p1c1 @@ -905,7 +905,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.122398, 1.074022, 0.415368, -0.096185] + turb_naca0012_p1c1.test_vals = [-5.122388, 1.074056, 0.415434, -0.096182] test_list.append(turb_naca0012_p1c1) # NACA0012 p1c2 @@ -913,7 +913,7 @@ def main(): turb_naca0012_p1c2.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c2.cfg_file = "turb_NACA0012_uq_p1c2.cfg" turb_naca0012_p1c2.test_iter = 10 - turb_naca0012_p1c2.test_vals = [-5.549595, 0.945508, 0.287359, -0.117019] + turb_naca0012_p1c2.test_vals = [-5.549596, 0.945538, 0.287381, -0.117021] test_list.append(turb_naca0012_p1c2) ###################################### @@ -974,7 +974,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-1.173495, 0.061186, 1.399404, 2.220578, 1.399352, 2.218783, 0] + square_cylinder.test_vals = [-1.173495, 0.061334, 1.399404, 2.220578, 1.399352, 2.218783, 0.000000] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -1048,7 +1048,7 @@ def main(): coolprop_fluidModel.cfg_dir = "nicf/coolprop" coolprop_fluidModel.cfg_file = "fluidModel.cfg" coolprop_fluidModel.test_iter = 5 - coolprop_fluidModel.test_vals = [-4.424953, -1.582877, 3.442422, 0.000000, 0.000000] + coolprop_fluidModel.test_vals = [-4.424953, -1.582877, 3.720586, 0.000000, 0.000000] coolprop_fluidModel.enabled_on_cpu_arch = ["x86_64"] test_list.append(coolprop_fluidModel) @@ -1057,7 +1057,7 @@ def main(): coolprop_transportModel.cfg_dir = "nicf/coolprop" coolprop_transportModel.cfg_file = "transportModel.cfg" coolprop_transportModel.test_iter = 5 - coolprop_transportModel.test_vals = [-4.428098, -1.314332, 4.630872, 0.000000, 0.000000] + coolprop_transportModel.test_vals = [-4.428098, -1.314332, 4.666153, 0.000000, 0.000000] coolprop_transportModel.enabled_on_cpu_arch = ["x86_64"] test_list.append(coolprop_transportModel) @@ -1086,7 +1086,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-10.467612, -2.871708, -19.345651, -13.625871, -11.582397, -6.306168, 73273, 73273, 0.019884, 82.491] + Jones_tc_restart.test_vals = [-3.501027, -0.855390, -11.767169, -6.117420, -9.432832, -3.573397, 73273.000000, 73273.000000, 0.019884, 82.491000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -1185,7 +1185,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.773513, -1.700012] + bars_SST_2D.test_vals = [13.000000, -0.726399, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) @@ -1337,7 +1337,7 @@ def main(): sp_pinArray_cht_2d_dp_hf.cfg_dir = "incomp_navierstokes/streamwise_periodic/chtPinArray_2d" sp_pinArray_cht_2d_dp_hf.cfg_file = "configMaster.cfg" sp_pinArray_cht_2d_dp_hf.test_iter = 100 - sp_pinArray_cht_2d_dp_hf.test_vals = [0.088580, -0.764276, -1.086940, -0.747450, 208.023676, 344.680000, -0.000000, -0.747450, 0.747450] + sp_pinArray_cht_2d_dp_hf.test_vals = [0.088590, -0.764262, -1.086946, -0.747448, 208.023676, 344.680000, -0.000000, -0.747450, 0.747450] sp_pinArray_cht_2d_dp_hf.multizone = True test_list.append(sp_pinArray_cht_2d_dp_hf) @@ -1346,7 +1346,7 @@ def main(): sp_pinArray_3d_cht_mf_hf_tp.cfg_dir = "incomp_navierstokes/streamwise_periodic/chtPinArray_3d" sp_pinArray_3d_cht_mf_hf_tp.cfg_file = "configMaster.cfg" sp_pinArray_3d_cht_mf_hf_tp.test_iter = 30 - sp_pinArray_3d_cht_mf_hf_tp.test_vals = [-1.627413, -3.083567, -4.577909, -0.009725, 104.632413, 418.370000, 0.000000] + sp_pinArray_3d_cht_mf_hf_tp.test_vals = [-1.612910, -2.837554, -3.507895, -0.009728, 104.631202, 418.360000, 0.000000] sp_pinArray_3d_cht_mf_hf_tp.test_vals_aarch64 = [-1.622914, -3.081114, -4.576282, -0.009725, 104.632412, 418.370000, 0.000000] sp_pinArray_3d_cht_mf_hf_tp.multizone = True test_list.append(sp_pinArray_3d_cht_mf_hf_tp) @@ -1370,7 +1370,7 @@ def main(): pywrapper_turb_naca0012_sst.cfg_dir = "rans/naca0012" pywrapper_turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" pywrapper_turb_naca0012_sst.test_iter = 10 - pywrapper_turb_naca0012_sst.test_vals = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] + pywrapper_turb_naca0012_sst.test_vals = [-8.515763, -10.746560, -4.508015, 1.047852, 0.019161, -1.928310, 0.000000] pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] pywrapper_turb_naca0012_sst.command = TestCase.Command("mpirun -np 2", "SU2_CFD.py", "--parallel -f") pywrapper_turb_naca0012_sst.timeout = 3200 diff --git a/TestCases/parallel_regression_AD.py b/TestCases/parallel_regression_AD.py index f54849610f4a..5366959a50a2 100644 --- a/TestCases/parallel_regression_AD.py +++ b/TestCases/parallel_regression_AD.py @@ -91,7 +91,7 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.274779, -0.278440, -2.255500, -0.003160] + discadj_rans_naca0012_sst.test_vals = [-2.274814, -0.278441, -2.250500, -0.003160] discadj_rans_naca0012_sst.test_vals_aarch64 = [-2.274779, -0.278440, -2.255500, -0.003160] test_list.append(discadj_rans_naca0012_sst) diff --git a/TestCases/serial_regression.py b/TestCases/serial_regression.py index b4b9cd473a9a..9581ea7a3f19 100644 --- a/TestCases/serial_regression.py +++ b/TestCases/serial_regression.py @@ -234,7 +234,7 @@ def main(): rae2822_sst_sust.cfg_dir = "rans/rae2822" rae2822_sst_sust.cfg_file = "turb_SST_SUST_RAE2822.cfg" rae2822_sst_sust.test_iter = 20 - rae2822_sst_sust.test_vals = [-2.536121, 4.873617, 0.816197, 0.060504] + rae2822_sst_sust.test_vals = [-2.536147, 4.873615, 0.816197, 0.060504] test_list.append(rae2822_sst_sust) # Flat plate @@ -294,7 +294,7 @@ def main(): turb_naca0012_sst_2003m.cfg_dir = "rans/naca0012" turb_naca0012_sst_2003m.cfg_file = "turb_NACA0012_sst_2003m.cfg" turb_naca0012_sst_2003m.test_iter = 10 - turb_naca0012_sst_2003m.test_vals = [-7.688139, -10.046053, -3.410061, 1.048970, 0.019798, -2.208236, 0] + turb_naca0012_sst_2003m.test_vals = [-7.660511, -10.053600, -3.394775, 1.046880, 0.019689, -2.170311, 0.000000] turb_naca0012_sst_2003m.timeout = 3200 test_list.append(turb_naca0012_sst_2003m) @@ -303,7 +303,7 @@ def main(): turb_naca0012_sst_sust_restart.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust_restart.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust_restart.test_iter = 10 - turb_naca0012_sst_sust_restart.test_vals = [-12.084326, -14.827365, -6.062398, 1.000276, 0.019495, -2.201517] + turb_naca0012_sst_sust_restart.test_vals = [-7.998513, -10.320508, -3.314994, 0.994965, 0.019301, -1.821039] turb_naca0012_sst_sust_restart.test_vals_aarch64 = [-12.084326, -14.827365, -6.062398, 1.000276, 0.019495, -2.201517] turb_naca0012_sst_sust_restart.timeout = 3200 test_list.append(turb_naca0012_sst_sust_restart) @@ -313,7 +313,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.206694, -10.016428, -1.616043, 1.021479, 0.040333, -3.478142] + turb_naca0012_sst_fixedvalues.test_vals = [-5.206693, -10.016853, -1.615987, 1.021480, 0.040333, -3.478131] turb_naca0012_sst_fixedvalues.timeout = 3200 test_list.append(turb_naca0012_sst_fixedvalues) @@ -335,7 +335,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-12.071702, -7.474599, -8.646498, -3.988633, 0] + axi_rans_air_nozzle_restart.test_vals = [-6.046478, -0.483139, -2.216327, 2.472194, 0.000000] axi_rans_air_nozzle_restart.test_vals_aarch64 = [-12.071702, -7.474599, -8.646498, -3.988633, 0] axi_rans_air_nozzle_restart.tol = 0.0001 test_list.append(axi_rans_air_nozzle_restart) @@ -350,7 +350,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 50 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.639702, -7.441853, -1.895004, 0.000001, 0.079178] + turb_naca0012_sst_restart_mg.test_vals = [-7.639663, -7.464724, -1.665498, -0.000022, 0.079196] turb_naca0012_sst_restart_mg.timeout = 3200 turb_naca0012_sst_restart_mg.tol = 0.000001 test_list.append(turb_naca0012_sst_restart_mg) @@ -449,7 +449,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.270375, 0.018431, 0.000021, 0.307673] + inc_turb_naca0012_sst_sust.test_vals = [-7.316735, 0.018271, 0.000021, 0.307672] test_list.append(inc_turb_naca0012_sst_sust) # FLAT PLATE, WALL FUNCTIONS, INCOMPRESSIBLE SST @@ -677,7 +677,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.992120, 1.134926, 0.356004, -0.089085] + turb_naca0012_1c.test_vals = [-4.992120, 1.134942, 0.356070, -0.089068] test_list.append(turb_naca0012_1c) # NACA0012 2c @@ -685,7 +685,7 @@ def main(): turb_naca0012_2c.cfg_dir = "rans_uq/naca0012" turb_naca0012_2c.cfg_file = "turb_NACA0012_uq_2c.cfg" turb_naca0012_2c.test_iter = 10 - turb_naca0012_2c.test_vals = [-5.485136, 0.968075, 0.273236, -0.110320] + turb_naca0012_2c.test_vals = [-5.485136, 0.968105, 0.273199, -0.110329] test_list.append(turb_naca0012_2c) # NACA0012 3c @@ -693,7 +693,7 @@ def main(): turb_naca0012_3c.cfg_dir = "rans_uq/naca0012" turb_naca0012_3c.cfg_file = "turb_NACA0012_uq_3c.cfg" turb_naca0012_3c.test_iter = 10 - turb_naca0012_3c.test_vals = [-5.584305, 0.931248, 0.250749, -0.113574] + turb_naca0012_3c.test_vals = [-5.584305, 0.931283, 0.250707, -0.113586] test_list.append(turb_naca0012_3c) # NACA0012 p1c1 @@ -701,7 +701,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.120263, 1.074826, 0.294764, -0.109420] + turb_naca0012_p1c1.test_vals = [-5.120250, 1.074873, 0.294822, -0.109404] test_list.append(turb_naca0012_p1c1) # NACA0012 p1c2 @@ -709,7 +709,7 @@ def main(): turb_naca0012_p1c2.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c2.cfg_file = "turb_NACA0012_uq_p1c2.cfg" turb_naca0012_p1c2.test_iter = 10 - turb_naca0012_p1c2.test_vals = [-5.549132, 0.945637, 0.252403, -0.117491] + turb_naca0012_p1c2.test_vals = [-5.549132, 0.945671, 0.252360, -0.117501] test_list.append(turb_naca0012_p1c2) ###################################### @@ -769,7 +769,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-2.560840, -1.173495, 0.061186, 1.399403, 2.220585, 1.399351, 2.218790, 0] + square_cylinder.test_vals = [-2.560840, -1.173495, 0.061334, 1.399403, 2.220585, 1.399351, 2.218790, 0.000000] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -864,7 +864,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-10.466644, -2.871703, -19.193464, -13.487820, -11.582397, -6.306167, 73273, 73273, 0.019884, 82.491] + Jones_tc_restart.test_vals = [-3.501033, -0.855390, -11.767195, -6.117445, -9.432838, -3.573401, 73273.000000, 73273.000000, 0.019884, 82.491000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -972,7 +972,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.773513, -1.700012] + bars_SST_2D.test_vals = [13.000000, -0.726398, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) @@ -1520,7 +1520,7 @@ def main(): pywrapper_turb_naca0012_sst.cfg_dir = "rans/naca0012" pywrapper_turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" pywrapper_turb_naca0012_sst.test_iter = 10 - pywrapper_turb_naca0012_sst.test_vals = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] + pywrapper_turb_naca0012_sst.test_vals = [-8.507630, -10.746643, -4.514387, 1.047906, 0.019158, -1.724758, 0.000000] pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] pywrapper_turb_naca0012_sst.command = TestCase.Command(exec = "SU2_CFD.py", param = "-f") pywrapper_turb_naca0012_sst.timeout = 3200 diff --git a/TestCases/serial_regression_AD.py b/TestCases/serial_regression_AD.py index 620a3b20e8f9..80ae12dc9934 100644 --- a/TestCases/serial_regression_AD.py +++ b/TestCases/serial_regression_AD.py @@ -86,7 +86,7 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.127041, -0.204660, 0.335320, -0.022055] + discadj_rans_naca0012_sst.test_vals = [-2.127004, -0.204660, 0.340440, -0.022055] test_list.append(discadj_rans_naca0012_sst) ####################################### diff --git a/TestCases/tutorials.py b/TestCases/tutorials.py index 1ac1281061ec..c827aef8c31e 100644 --- a/TestCases/tutorials.py +++ b/TestCases/tutorials.py @@ -208,7 +208,7 @@ def main(): tutorial_trans_flatplate_T3A.cfg_dir = "../Tutorials/compressible_flow/Transitional_Flat_Plate/Langtry_and_Menter/T3A" tutorial_trans_flatplate_T3A.cfg_file = "transitional_LM_model_ConfigFile.cfg" tutorial_trans_flatplate_T3A.test_iter = 20 - tutorial_trans_flatplate_T3A.test_vals = [-5.837399, -2.092246, -3.983493, -0.302381, -1.920868, 1.667180, -3.496278, 0.391608] + tutorial_trans_flatplate_T3A.test_vals = [-5.841281, -2.094610, -3.948081, -0.305564, -1.588781, 8.304710, -3.507210, 0.395186] tutorial_trans_flatplate_T3A.test_vals_aarch64 = [-5.837368, -2.092246, -3.984172, -0.302357, -1.928108, 1.667157, -3.496279, 0.391610] tutorial_trans_flatplate_T3A.no_restart = True test_list.append(tutorial_trans_flatplate_T3A) @@ -218,7 +218,7 @@ def main(): tutorial_trans_flatplate_T3Am.cfg_dir = "../Tutorials/compressible_flow/Transitional_Flat_Plate/Langtry_and_Menter/T3A-" tutorial_trans_flatplate_T3Am.cfg_file = "transitional_LM_model_ConfigFile.cfg" tutorial_trans_flatplate_T3Am.test_iter = 20 - tutorial_trans_flatplate_T3Am.test_vals = [-6.063700, -1.945073, -3.946836, -0.549147, -3.863792, 2.664440, -2.517610, 1.112977] + tutorial_trans_flatplate_T3Am.test_vals = [-6.206420, -2.029271, -4.028226, -0.685276, -3.893698, 6.726680, -2.520959, 0.948647] tutorial_trans_flatplate_T3Am.test_vals_aarch64 = [-6.063726, -1.945088, -3.946923, -0.549166, -3.863794, 2.664439, -2.517601, 1.112978] tutorial_trans_flatplate_T3Am.no_restart = True test_list.append(tutorial_trans_flatplate_T3Am) diff --git a/TestCases/vandv.py b/TestCases/vandv.py index f9da69699942..ba3fb0dde688 100644 --- a/TestCases/vandv.py +++ b/TestCases/vandv.py @@ -63,7 +63,7 @@ def main(): bump_sst1994m.cfg_dir = "vandv/rans/bump_in_channel" bump_sst1994m.cfg_file = "turb_bump_sst.cfg" bump_sst1994m.test_iter = 5 - bump_sst1994m.test_vals = [-13.000658, -10.449108, -10.585058, -7.531737, -10.468414, -5.695067, 0.004904] + bump_sst1994m.test_vals = [-5.472393, -2.651543, -2.741047, 0.023512, -1.997863, 15.897007, 0.004899] bump_sst1994m.test_vals_aarch64 = [-13.000658, -10.449108, -10.585058, -7.531737, -10.468414, -5.695067, 0.004904] test_list.append(bump_sst1994m) @@ -82,7 +82,7 @@ def main(): swbli_sst.cfg_dir = "vandv/rans/swbli" swbli_sst.cfg_file = "config_sst.cfg" swbli_sst.test_iter = 5 - swbli_sst.test_vals = [-11.505404, -10.756847, -11.931456, -10.349754, -11.606988, -4.851901, 0.002280, -1.521436, -3.777949, 1.340100] + swbli_sst.test_vals = [-11.500317, -10.752421, -11.508502, -10.331672, -10.300258, 1.562476, 0.002280, -1.324977, -6.297644, 1.000000] test_list.append(swbli_sst) ########################## @@ -94,7 +94,7 @@ def main(): sandiajet_sst.cfg_dir = "vandv/species_transport/sandia_jet" sandiajet_sst.cfg_file = "validation.cfg" sandiajet_sst.test_iter = 5 - sandiajet_sst.test_vals = [-17.169907, -13.518707, -15.442566, -12.021165, -9.660040, -15.289842, 5.000000, -2.746249, 5.000000, -4.836800, 5.000000, -3.966350, 0.000259, 0.000000, 0.000000, 0.000259, 4047.400000, 3946.800000, 49.161000, 51.433000] + sandiajet_sst.test_vals = [-8.502793, -6.169258, -6.699764, -5.115200, 1.068905, -8.492912, 5.000000, -1.727355, 5.000000, -5.233912, 5.000000, -1.959627, 0.000259, 0.000000, 0.000000, 0.000259, 4047.400000, 3946.800000, 49.161000, 51.433000] sandiajet_sst.test_vals_aarch64 = [-17.069026, -13.156800, -15.290567, -11.689831, -9.349978, -14.907311, 5.000000, -2.738947, 5.000000, -4.813747, 5.000000, -3.981740, 0.000259, 0.000000, 0.000000, 0.000259, 4047.400000, 3946.800000, 49.161000, 51.433000] test_list.append(sandiajet_sst) From d7b8ee7e7861bfd7916d811449c5ecf7ee2468af Mon Sep 17 00:00:00 2001 From: bigfooted Date: Thu, 16 Jan 2025 07:55:13 +0100 Subject: [PATCH 24/49] regression update --- TestCases/serial_regression.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/TestCases/serial_regression.py b/TestCases/serial_regression.py index 9581ea7a3f19..30fcd2eef827 100644 --- a/TestCases/serial_regression.py +++ b/TestCases/serial_regression.py @@ -284,7 +284,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] + turb_naca0012_sst.test_vals = [-8.507630, -10.746643, -4.514387, 1.047906, 0.019158, -1.724758, 0.000000] turb_naca0012_sst.test_vals_aarch64 = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -1534,7 +1534,7 @@ def main(): pywrapper_square_cylinder.cfg_dir = "unsteady/square_cylinder" pywrapper_square_cylinder.cfg_file = "turb_square.cfg" pywrapper_square_cylinder.test_iter = 3 - pywrapper_square_cylinder.test_vals = [-2.560840, -1.173495, 0.061186, 1.399403, 2.220585, 1.399351, 2.218790, 0] + pywrapper_square_cylinder.test_vals = [-2.560840, -1.173495, 0.061334, 1.399403, 2.220585, 1.399351, 2.218790, 0.000000] pywrapper_square_cylinder.command = TestCase.Command(exec = "SU2_CFD.py", param = "-f") pywrapper_square_cylinder.timeout = 1600 pywrapper_square_cylinder.tol = 0.00001 From 444008ae13867ec1776f75c5262a03e9d8487149 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Thu, 16 Jan 2025 23:18:08 +0100 Subject: [PATCH 25/49] regression update --- .../streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref b/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref index 2634fca1ff54..861b1bbfada2 100644 --- a/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref +++ b/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref @@ -1,2 +1,2 @@ "VARIABLE" , "AVG_DENSITY[0]", "AVG_ENTHALPY[0]", "AVG_NORMALVEL[0]", "DRAG[0]" , "EFFICIENCY[0]" , "FORCE_X[0]" , "FORCE_Y[0]" , "FORCE_Z[0]" , "LIFT[0]" , "MOMENT_X[0]" , "MOMENT_Y[0]" , "MOMENT_Z[0]" , "SIDEFORCE[0]" , "SURFACE_MACH[0]", "SURFACE_MASSFLOW[0]", "SURFACE_MOM_DISTORTION[0]", "SURFACE_PRESSURE_DROP[0]", "SURFACE_SECONDARY[0]", "SURFACE_SECOND_OVER_UNIFORM[0]", "SURFACE_STATIC_PRESSURE[0]", "SURFACE_STATIC_TEMPERATURE[0]", "SURFACE_TOTAL_PRESSURE[0]", "SURFACE_TOTAL_TEMPERATURE[0]", "SURFACE_UNIFORMITY[0]", "AVG_TEMPERATURE[1]", "MAXIMUM_HEATFLUX[1]", "TOTAL_HEATFLUX[1]", "FINDIFF_STEP" -0 , 0.0 , -300000.0026077032, -3.3306691000000184e-08, 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , -0.01999999887924986, 0.0 , -0.9000000009140585 , 0.0 , 0.9379999998948563 , 1.649999997743734 , 419.99999780273356 , -69.99999868639861 , 358.9999998609983 , -69.99999868639861 , -0.6000000052353016 , -380.0000001774606, 0.0 , -430.00000005122274, 1e-08 +0 , 0.0 , -2300000.0044703484, 6.661338199999911e-08, 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , -2.389999999297121, 6.660999999418455e-08, -18.70800000053352 , 0.0 , 18.32399999929235 , 34.89000000023168 , 14349.999997875784 , -660.0000006073969 , -921.000000175809 , -649.9999926745659 , -34.59999999844143 , -719.9999970453064, 0.0 , -499.99999873762135, 1e-08 From 82658f723d17e8ad9995a6f229a5eee7224750fb Mon Sep 17 00:00:00 2001 From: bigfooted Date: Mon, 20 Jan 2025 16:32:21 +0100 Subject: [PATCH 26/49] remove unused functions --- SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp | 8 -------- SU2_CFD/include/solvers/CFVMFlowSolverBase.inl | 5 ----- SU2_CFD/include/solvers/CSolver.hpp | 8 -------- 3 files changed, 21 deletions(-) diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp b/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp index d5ed37c18487..2aa31880baea 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.hpp @@ -2419,14 +2419,6 @@ class CFVMFlowSolverBase : public CSolver { return YPlus[val_marker][val_vertex]; } - /*! - * \brief Set the y plus. - * \param[in] val_yplus - new value of yplus - */ - inline void SetYPlus(su2double val_yplus, unsigned short val_marker, unsigned long val_vertex) final { - YPlus[val_marker][val_vertex] = val_yplus; - } - /*! * \brief Get the u_tau . * \param[in] val_marker - Surface marker where the coefficient is computed. diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl index 6db04c401113..d859b0742c69 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl @@ -2502,11 +2502,6 @@ void CFVMFlowSolverBase::Friction_Forces(const CGeometry* geometr iPointNormal = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); Coord_Normal = geometry->nodes->GetCoord(iPointNormal); WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); - //nijso: we can modifiy y+ as well now? - - - - YPlus[iMarker][iVertex] = WallDistMod * FrictionVel / (Viscosity / Density); } diff --git a/SU2_CFD/include/solvers/CSolver.hpp b/SU2_CFD/include/solvers/CSolver.hpp index 343c2fec26a1..2ed78a78a9be 100644 --- a/SU2_CFD/include/solvers/CSolver.hpp +++ b/SU2_CFD/include/solvers/CSolver.hpp @@ -2989,14 +2989,6 @@ class CSolver { */ inline virtual su2double GetYPlus(unsigned short val_marker, unsigned long val_vertex) const { return 0; } - /*! - * \brief A virtual member. - * \param[in] val_marker - Surface marker where the coefficient is computed. - * \param[in] val_vertex - Vertex of the marker val_marker where the coefficient is evaluated. - * \return Value of the y plus. - */ - inline virtual void SetYPlus(su2double val_yplus, unsigned short val_marker, unsigned long val_vertex) {}; - /*! * \brief A virtual member. * \param[in] val_marker - Surface marker where the coefficient is computed. From fde5b39e9ea4b52cc4e64ce01cf7fe010f91d249 Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sun, 23 Feb 2025 21:35:35 +0000 Subject: [PATCH 27/49] move to CVertex --- Common/include/geometry/dual_grid/CVertex.hpp | 41 +++++---- Common/src/geometry/CGeometry.cpp | 87 +++++++++++++++---- .../include/solvers/CFVMFlowSolverBase.inl | 8 +- SU2_CFD/include/solvers/CTurbSSTSolver.hpp | 11 --- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 31 +------ 5 files changed, 100 insertions(+), 78 deletions(-) diff --git a/Common/include/geometry/dual_grid/CVertex.hpp b/Common/include/geometry/dual_grid/CVertex.hpp index 6a2f8c4b323c..518a85b6ff65 100644 --- a/Common/include/geometry/dual_grid/CVertex.hpp +++ b/Common/include/geometry/dual_grid/CVertex.hpp @@ -46,6 +46,7 @@ class CVertex : public CDualGrid { bool ActDisk_Perimeter = false; /*!< \brief Identify nodes at the perimeter of the actuator disk */ short Rotation_Type; /*!< \brief Type of rotation associated with the vertex (MPI and periodic) */ unsigned long Normal_Neighbor; /*!< \brief Index of the closest, most normal, neighbor. */ + su2double NearestNeighborDist = 0.0; /*!< \brief Distance to nearest internal neighbor that is not a wall. */ su2double Basis_Function[3] = {0.0}; /*!< \brief Basis function values for interpolation across zones. */ public: @@ -98,7 +99,7 @@ class CVertex : public CDualGrid { * \brief Get the normal to a face of the control volume asociated with a vertex. * \return Dimensional normal vector, the modulus is the area of the face. */ - inline su2double* GetNormal(void) override { return Normal; } + inline su2double* GetNormal() override { return Normal; } /*! * \brief Get the ith component of the normal. @@ -108,7 +109,7 @@ class CVertex : public CDualGrid { /*! * \brief Initialize normal vector. */ - inline void SetZeroValues(void) override { + inline void SetZeroValues() override { for (unsigned short iDim = 0; iDim < nDim; iDim++) Normal[iDim] = 0.0; } @@ -122,7 +123,7 @@ class CVertex : public CDualGrid { * \brief Get the value of an auxiliary variable for gradient computation. * \return Value of the auxiliar variable. */ - inline su2double GetAuxVar(void) const { return Aux_Var; } + inline su2double GetAuxVar() const { return Aux_Var; } /*! * \brief Add the value of an auxiliary variable for gradient computation. @@ -167,7 +168,7 @@ class CVertex : public CDualGrid { * \brief Get the value of the coordinate variation due to a surface modification. * \return Variation of the coordinate. */ - inline su2double* GetVarCoord(void) { return VarCoord; } + inline su2double* GetVarCoord() { return VarCoord; } /*! * \brief Set the value of the cartesian coordinate for the vertex. @@ -181,7 +182,7 @@ class CVertex : public CDualGrid { * \brief Get the value of the cartesian coordinate for the vertex. * \return Value of the cartesian coordinate of the vertex. */ - inline su2double* GetCoord(void) override { return CartCoord; } + inline su2double* GetCoord() override { return CartCoord; } /*! * \brief Get the value of the cartesian coordinate for the vertex. @@ -200,7 +201,7 @@ class CVertex : public CDualGrid { * \brief Get the type of rotation associated to the vertex. * \return Value of the rotation that must be applied to the solution of the vertex */ - inline short GetRotation_Type(void) const { return Rotation_Type; } + inline short GetRotation_Type() const { return Rotation_Type; } /*! * \overload @@ -250,49 +251,49 @@ class CVertex : public CDualGrid { * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetDonorPoint(void) const { return PeriodicPoint[0]; } + inline long GetDonorPoint() const { return PeriodicPoint[0]; } /*! * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetDonorMarker(void) const { return PeriodicPoint[4]; } + inline long GetDonorMarker() const { return PeriodicPoint[4]; } /*! * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetDonorVertex(void) const { return PeriodicPoint[3]; } + inline long GetDonorVertex() const { return PeriodicPoint[3]; } /*! * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetDonorGlobalIndex(void) const { return PeriodicPoint[2]; } + inline long GetDonorGlobalIndex() const { return PeriodicPoint[2]; } /*! * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetGlobalDonorPoint(void) const { return PeriodicPoint[2]; } + inline long GetGlobalDonorPoint() const { return PeriodicPoint[2]; } /*! * \brief Get the value of the periodic point of a vertex. * \return Value of the periodic point of a vertex. */ - inline long GetDonorProcessor(void) const { return PeriodicPoint[1]; } + inline long GetDonorProcessor() const { return PeriodicPoint[1]; } /*! * \brief Get the value of the periodic point of a vertex, and its somain * \return Value of the periodic point of a vertex, and the domain. */ - inline long* GetPeriodicPointDomain(void) { return PeriodicPoint; } + inline long* GetPeriodicPointDomain() { return PeriodicPoint; } /*! * \brief Get the value of the periodic point of a vertex, and its somain * \return Value of the periodic point of a vertex, and the domain. */ - inline bool GetActDisk_Perimeter(void) const { return ActDisk_Perimeter; } + inline bool GetActDisk_Perimeter() const { return ActDisk_Perimeter; } /*! * \brief Set the finite element basis functions needed for interpolation. @@ -318,5 +319,15 @@ class CVertex : public CDualGrid { * \brief Get the value of the closest neighbor. * \return Index of the closest neighbor. */ - inline unsigned long GetNormal_Neighbor(void) const { return Normal_Neighbor; } + inline unsigned long GetNormal_Neighbor() const { return Normal_Neighbor; } + + /*! + * \brief Set the distance of the nearest internal neighbor that is not a wall. + */ + inline void SetNearestNeighborDistance(const su2double& val) { NearestNeighborDist = val; } + + /*! + * \brief Get the distance to the nearest internal neighbor that is not a wall. + */ + inline const su2double& GetNearestNeighborDistance() const { return NearestNeighborDist; } }; diff --git a/Common/src/geometry/CGeometry.cpp b/Common/src/geometry/CGeometry.cpp index e771960b6386..2b1612fcd74b 100644 --- a/Common/src/geometry/CGeometry.cpp +++ b/Common/src/geometry/CGeometry.cpp @@ -3902,6 +3902,36 @@ const CGeometry::CLineletInfo& CGeometry::GetLineletInfo(const CConfig* config) return li; } +namespace { +su2double NearestNeighborDistance(CGeometry* geometry, const CConfig* config, const unsigned long iPoint) { + const su2double max = std::numeric_limits::max(); + su2double distance = max; + for (const auto jPoint : geometry->nodes->GetPoints(iPoint)) { + const su2double dist = geometry->nodes->GetWall_Distance(jPoint); + if (dist > EPS) distance = fmin(distance, dist); + } + if (distance > 0 && distance < max) return distance; + + /*--- The point only has wall neighbors, which all have 0 wall distance. + * Compute an alternative distance based on volume and wall area. ---*/ + + const auto nDim = geometry->GetnDim(); + su2double Normal[3] = {}; + for (auto iMarker = 0u; iMarker < config->GetnMarker_All(); iMarker++) { + if (!config->GetViscous_Wall(iMarker)) continue; + + const auto iVertex = geometry->nodes->GetVertex(iPoint, iMarker); + if (iVertex < 0) continue; + + for (auto iDim = 0u; iDim < nDim; iDim++) { + Normal[iDim] += geometry->vertex[iMarker][iVertex]->GetNormal(iDim); + } + } + const su2double Vol = geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint); + return 2 * Vol / GeometryToolbox::Norm(nDim, Normal); +} +} // namespace + void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeometry**** geometry_container) { int nZone = config_container[ZONE_0]->GetnZone(); bool allEmpty = true; @@ -3946,27 +3976,48 @@ void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeo CGeometry* geometry = geometry_container[iZone][iInst][MESH_0]; geometry->SetWallDistance(0.0); } + continue; } - /*--- Otherwise, set wall roughnesses. ---*/ - if (!allEmpty) { - /*--- Store all wall roughnesses in a common data structure. ---*/ - // [iZone][iMarker] -> roughness, for this rank - auto roughness_f = make_pair(nZone, [config_container, geometry_container, iInst](unsigned long iZone) { - const CConfig* config = config_container[iZone]; - const auto nMarker = geometry_container[iZone][iInst][MESH_0]->GetnMarker(); - - return make_pair(nMarker, [config](unsigned long iMarker) { - return config->GetWallRoughnessProperties(config->GetMarker_All_TagBound(iMarker)).second; - }); + + /*--- Otherwise, set wall roughnesses, storing them in a common data structure. ---*/ + // [iZone][iMarker] -> roughness, for this rank + auto roughness_f = make_pair(nZone, [config_container, geometry_container, iInst](unsigned long iZone) { + const CConfig* config = config_container[iZone]; + const auto nMarker = geometry_container[iZone][iInst][MESH_0]->GetnMarker(); + + return make_pair(nMarker, [config](unsigned long iMarker) { + return config->GetWallRoughnessProperties(config->GetMarker_All_TagBound(iMarker)).second; }); - NdFlattener<2> roughness_local(roughness_f); - // [rank][iZone][iMarker] -> roughness - NdFlattener<3> roughness_global(Nd_MPI_Environment(), roughness_local); - // use it to update roughnesses - for (int jZone = 0; jZone < nZone; jZone++) { - if (wallDistanceNeeded[jZone] && config_container[jZone]->GetnRoughWall() > 0) { - geometry_container[jZone][iInst][MESH_0]->nodes->SetWallRoughness(roughness_global); + }); + NdFlattener<2> roughness_local(roughness_f); + // [rank][iZone][iMarker] -> roughness + NdFlattener<3> roughness_global(Nd_MPI_Environment(), roughness_local); + // use it to update roughnesses + for (int jZone = 0; jZone < nZone; jZone++) { + if (wallDistanceNeeded[jZone] && config_container[jZone]->GetnRoughWall() > 0) { + geometry_container[jZone][iInst][MESH_0]->nodes->SetWallRoughness(roughness_global); + } + } + + for (int iZone = 0; iZone < nZone; iZone++) { + const auto* config = config_container[iZone]; + auto* geometry = geometry_container[iZone][iInst][MESH_0]; + + for (unsigned short iMarker = 0; iMarker < config->GetnMarker_All(); ++iMarker) { + const auto viscous = config->GetViscous_Wall(iMarker); + + SU2_OMP_FOR_STAT(OMP_MIN_SIZE) + for (auto iVertex = 0u; iVertex < geometry->nVertex[iMarker]; iVertex++) { + const auto iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); + su2double dist = 0; + if (viscous && geometry->nodes->GetDomain(iPoint)) { + dist = NearestNeighborDistance(geometry, config, iPoint); + } else { + dist = geometry->nodes->GetWall_Distance(iPoint); + } + geometry->vertex[iMarker][iVertex]->SetNearestNeighborDistance(dist); } + END_SU2_OMP_FOR } } } diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl index d859b0742c69..a3d1dabef87e 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl @@ -2350,7 +2350,7 @@ void CFVMFlowSolverBase::Friction_Forces(const CGeometry* geometr unsigned long iVertex, iPoint, iPointNormal; unsigned short iMarker, iMarker_Monitoring, iDim, jDim; - su2double Viscosity = 0.0, Area, Density = 0.0, WallDistMod, FrictionVel, + su2double Viscosity = 0.0, Area, Density = 0.0, FrictionVel, UnitNormal[3] = {0.0}, TauElem[3] = {0.0}, Tau[3][3] = {{0.0}}, Cp, thermal_conductivity, MaxNorm = 8.0, Grad_Vel[3][3] = {{0.0}}, Grad_Temp[3] = {0.0}, Grad_Temp_ve[3] = {0.0}, AxiFactor; @@ -2497,11 +2497,9 @@ void CFVMFlowSolverBase::Friction_Forces(const CGeometry* geometr FrictionVel = sqrt(fabs(WallShearStress[iMarker][iVertex]) / Density); - if (!wallfunctions && (MGLevel == MESH_0 || geometry->nodes->GetDomain(iPoint))) { + if (!wallfunctions && MGLevel == MESH_0 && geometry->nodes->GetDomain(iPoint)) { // for CMultiGridGeometry, the normal neighbor of halo nodes is not set - iPointNormal = geometry->vertex[iMarker][iVertex]->GetNormal_Neighbor(); - Coord_Normal = geometry->nodes->GetCoord(iPointNormal); - WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); + const su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); YPlus[iMarker][iVertex] = WallDistMod * FrictionVel / (Viscosity / Density); } diff --git a/SU2_CFD/include/solvers/CTurbSSTSolver.hpp b/SU2_CFD/include/solvers/CTurbSSTSolver.hpp index de85079ad93f..0db8bf164b63 100644 --- a/SU2_CFD/include/solvers/CTurbSSTSolver.hpp +++ b/SU2_CFD/include/solvers/CTurbSSTSolver.hpp @@ -53,17 +53,6 @@ class CTurbSSTSolver final : public CTurbSolver { CSolver **solver_container, const CConfig *config, unsigned short val_marker); - - /*! - * \brief Returns the smallest non-zero wall distance over the neighbors of iPoint. - * If this is zero the distance is estimated from volume and area. - * \param[in] geometry - Geometrical definition of the problem. - * \param[in] config - Definition of the particular problem. - * \param[in] iPoint - Index of the wall point. - * \return Distance. - */ - su2double NearestNeighborDistance(CGeometry *geometry, const CConfig *config, unsigned long iPoint) const; - public: /*! * \brief Constructor. diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index e11e6958c64b..400ee1000234 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -271,7 +271,7 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai shearStress = sqrt(shearStress); const su2double FrictionVelocity = sqrt(shearStress/flowNodes->GetDensity(iPoint)); - const su2double wall_dist = NearestNeighborDistance(geometry, config, iPoint); + const su2double wall_dist = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); const su2double Derivative = flowNodes->GetLaminarViscosity(jPoint) * pow(nodes->GetSolution(jPoint, 0), 0.673) / wall_dist; const su2double turbulence_index = 6.1 * Derivative / pow(FrictionVelocity, 2.346); @@ -459,7 +459,7 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont } else { // smooth wall /*--- distance to closest neighbor ---*/ - su2double wall_dist = NearestNeighborDistance(geometry, config, iPoint); + su2double wall_dist = geometry->vertex[val_marker][iVertex]->GetNearestNeighborDistance(); /*--- Set wall values ---*/ const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); @@ -1020,30 +1020,3 @@ void CTurbSSTSolver::SetUniformInlet(const CConfig* config, unsigned short iMark } } - -su2double CTurbSSTSolver::NearestNeighborDistance(CGeometry *geometry, const CConfig *config, - unsigned long iPoint) const { - const su2double max = std::numeric_limits::max(); - su2double distance = max; - for (const auto jPoint : geometry->nodes->GetPoints(iPoint)) { - const su2double dist = geometry->nodes->GetWall_Distance(jPoint); - if (dist > EPS) distance = fmin(distance, dist); - } - if (distance > 0 && distance < max) return distance; - - /*--- The point only has wall neighbors, which all have 0 wall distance. - * Compute an alternative distance based on volume and wall area. ---*/ - - su2double Normal[MAXNDIM] = {}; - for (auto iMarker = 0u; iMarker < config->GetnMarker_All(); iMarker++) { - if (!config->GetViscous_Wall(iMarker)) continue; - - const auto iVertex = geometry->nodes->GetVertex(iPoint, iMarker); - if (iVertex < 0) continue; - - for (auto iDim = 0u; iDim < nDim; iDim++) - Normal[iDim] += geometry->vertex[iMarker][iVertex]->GetNormal(iDim); - } - const su2double Vol = geometry->nodes->GetVolume(iPoint) + geometry->nodes->GetPeriodicVolume(iPoint); - return 2 * Vol / GeometryToolbox::Norm(nDim, Normal); -} From 9020ece0812553f266a1afe9441df2e6d8b90e41 Mon Sep 17 00:00:00 2001 From: nijso beishuizen Date: Mon, 24 Feb 2025 05:25:43 -0800 Subject: [PATCH 28/49] fix DG segfault --- Common/src/geometry/CGeometry.cpp | 34 ++++++++++++++++--------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/Common/src/geometry/CGeometry.cpp b/Common/src/geometry/CGeometry.cpp index 2b1612fcd74b..5276be4ef007 100644 --- a/Common/src/geometry/CGeometry.cpp +++ b/Common/src/geometry/CGeometry.cpp @@ -4000,24 +4000,26 @@ void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeo } for (int iZone = 0; iZone < nZone; iZone++) { - const auto* config = config_container[iZone]; - auto* geometry = geometry_container[iZone][iInst][MESH_0]; - - for (unsigned short iMarker = 0; iMarker < config->GetnMarker_All(); ++iMarker) { - const auto viscous = config->GetViscous_Wall(iMarker); - - SU2_OMP_FOR_STAT(OMP_MIN_SIZE) - for (auto iVertex = 0u; iVertex < geometry->nVertex[iMarker]; iVertex++) { - const auto iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); - su2double dist = 0; - if (viscous && geometry->nodes->GetDomain(iPoint)) { - dist = NearestNeighborDistance(geometry, config, iPoint); - } else { - dist = geometry->nodes->GetWall_Distance(iPoint); + if (wallDistanceNeeded[iZone]) { + const auto* config = config_container[iZone]; + auto* geometry = geometry_container[iZone][iInst][MESH_0]; + + for (unsigned short iMarker = 0; iMarker < config->GetnMarker_All(); ++iMarker) { + const auto viscous = config->GetViscous_Wall(iMarker); + + SU2_OMP_FOR_STAT(OMP_MIN_SIZE) + for (auto iVertex = 0u; iVertex < geometry->nVertex[iMarker]; iVertex++) { + const auto iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); + su2double dist = 0; + if (viscous && geometry->nodes->GetDomain(iPoint)) { + dist = NearestNeighborDistance(geometry, config, iPoint); + } else { + dist = geometry->nodes->GetWall_Distance(iPoint); + } + geometry->vertex[iMarker][iVertex]->SetNearestNeighborDistance(dist); } - geometry->vertex[iMarker][iVertex]->SetNearestNeighborDistance(dist); + END_SU2_OMP_FOR } - END_SU2_OMP_FOR } } } From 1b9dbe196effc333dbb3bdba1377bb01ea063d0f Mon Sep 17 00:00:00 2001 From: nijso beishuizen Date: Mon, 24 Feb 2025 06:01:11 -0800 Subject: [PATCH 29/49] nearest-neighbor distance for wallfunction --- SU2_CFD/src/solvers/CIncNSSolver.cpp | 7 ++----- SU2_CFD/src/solvers/CNSSolver.cpp | 7 ++----- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/SU2_CFD/src/solvers/CIncNSSolver.cpp b/SU2_CFD/src/solvers/CIncNSSolver.cpp index e0a4fda96ef0..365febfad040 100644 --- a/SU2_CFD/src/solvers/CIncNSSolver.cpp +++ b/SU2_CFD/src/solvers/CIncNSSolver.cpp @@ -684,12 +684,9 @@ void CIncNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_containe const su2double VelTangMod = GeometryToolbox::Norm(int(MAXNDIM), VelTang); - /*--- Compute normal distance of the interior point from the wall ---*/ + /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ - su2double WallDist[MAXNDIM] = {0.0}; - GeometryToolbox::Distance(nDim, Coord, Coord_Normal, WallDist); - - su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); + su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); su2double Density_Wall = nodes->GetDensity(iPoint); diff --git a/SU2_CFD/src/solvers/CNSSolver.cpp b/SU2_CFD/src/solvers/CNSSolver.cpp index 50f243c7f0cf..30412de453e1 100644 --- a/SU2_CFD/src/solvers/CNSSolver.cpp +++ b/SU2_CFD/src/solvers/CNSSolver.cpp @@ -863,12 +863,9 @@ void CNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_container, const su2double VelTangMod = GeometryToolbox::Norm(int(MAXNDIM), VelTang); - /*--- Compute normal distance of the interior point from the wall ---*/ + /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ - su2double WallDist[MAXNDIM] = {0.0}; - GeometryToolbox::Distance(nDim, Coord, Coord_Normal, WallDist); - - const su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); + const su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); su2double T_Wall = nodes->GetTemperature(iPoint); const su2double Conductivity_Wall = nodes->GetThermalConductivity(iPoint); From 2cb1465d2dea447fd1e58fb54733bbdba6041193 Mon Sep 17 00:00:00 2001 From: nijso beishuizen Date: Mon, 24 Feb 2025 06:08:59 -0800 Subject: [PATCH 30/49] DG uses different mesh structure --- Common/src/geometry/CGeometry.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Common/src/geometry/CGeometry.cpp b/Common/src/geometry/CGeometry.cpp index 5276be4ef007..f8e569de8dd0 100644 --- a/Common/src/geometry/CGeometry.cpp +++ b/Common/src/geometry/CGeometry.cpp @@ -4000,7 +4000,11 @@ void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeo } for (int iZone = 0; iZone < nZone; iZone++) { - if (wallDistanceNeeded[iZone]) { + + /*--- For the FEM solver, we use a different mesh structure ---*/ + MAIN_SOLVER kindSolver = config_container[iZone]->GetKind_Solver(); + + if ((wallDistanceNeeded[iZone]) && (kindSolver != MAIN_SOLVER::FEM_LES) && (kindSolver != MAIN_SOLVER::FEM_RANS)) { const auto* config = config_container[iZone]; auto* geometry = geometry_container[iZone][iInst][MESH_0]; From b66271c631f39456650db2b1152d4a64a3aa1bc7 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Mon, 24 Feb 2025 22:03:04 +0100 Subject: [PATCH 31/49] fix SA walldist --- SU2_CFD/src/solvers/CTurbSASolver.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SU2_CFD/src/solvers/CTurbSASolver.cpp b/SU2_CFD/src/solvers/CTurbSASolver.cpp index 7d9999d965f0..d29b668edd85 100644 --- a/SU2_CFD/src/solvers/CTurbSASolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSASolver.cpp @@ -275,7 +275,7 @@ void CTurbSASolver::Postprocessing(CGeometry *geometry, CSolver **solver_contain FrictionVelocity = sqrt(flowNodes->GetLaminarViscosity(iPoint)*VorticityMag); } - const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint); + const su2double wall_dist = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); const su2double Derivative = nodes->GetSolution(jPoint, 0) / wall_dist; const su2double turbulence_index = Derivative / (FrictionVelocity * 0.41); @@ -309,7 +309,7 @@ void CTurbSASolver::Source_Residual(CGeometry *geometry, CSolver **solver_contai CNumerics **numerics_container, CConfig *config, unsigned short iMesh) { bool axisymmetric = config->GetAxisymmetric(); - + const bool implicit = (config->GetKind_TimeIntScheme() == EULER_IMPLICIT); const bool harmonic_balance = (config->GetTime_Marching() == TIME_MARCHING::HARMONIC_BALANCE); const bool transition_BC = config->GetSAParsedOptions().bc; @@ -389,7 +389,7 @@ void CTurbSASolver::Source_Residual(CGeometry *geometry, CSolver **solver_contai /*--- Set y coordinate ---*/ numerics->SetCoord(geometry->nodes->GetCoord(iPoint), geometry->nodes->GetCoord(iPoint)); } - + /*--- Compute the source term ---*/ auto residual = numerics->ComputeResidual(config); From 1199125e28dbd0cba12e2ddd4f5a53dbc0ecc6a4 Mon Sep 17 00:00:00 2001 From: ShiheJia <58663453+ShiheJia@users.noreply.github.com> Date: Tue, 25 Feb 2025 15:34:23 +0800 Subject: [PATCH 32/49] Update CTurbSSTSolver.cpp to fix bug on calculating MuT --- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index 02b91c8ab2cf..776174f35654 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -230,7 +230,7 @@ void CTurbSSTSolver::Postprocessing(CGeometry *geometry, CSolver **solver_contai const su2double dist = geometry->nodes->GetWall_Distance(iPoint); const su2double VorticityMag = max(GeometryToolbox::Norm(3, flowNodes->GetVorticity(iPoint)), 1e-12); - const su2double StrainMag = max(nodes->GetStrainMag(iPoint), 1e-12); + const su2double StrainMag = max(flowNodes->GetStrainMag(iPoint), 1e-12); nodes->SetBlendingFunc(iPoint, mu, dist, rho, config->GetKind_Trans_Model()); const su2double F2 = nodes->GetF2blending(iPoint); From ca0b4b65e4d720b59d7344566fe7b45ca40ef5f2 Mon Sep 17 00:00:00 2001 From: Pedro Gomes <38071223+pcarruscag@users.noreply.github.com> Date: Tue, 25 Feb 2025 09:39:35 +0000 Subject: [PATCH 33/49] Apply suggestions from code review --- Common/src/geometry/CGeometry.cpp | 38 +++++++++++++++---------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/Common/src/geometry/CGeometry.cpp b/Common/src/geometry/CGeometry.cpp index f8e569de8dd0..f83e362c6a7c 100644 --- a/Common/src/geometry/CGeometry.cpp +++ b/Common/src/geometry/CGeometry.cpp @@ -4003,27 +4003,27 @@ void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeo /*--- For the FEM solver, we use a different mesh structure ---*/ MAIN_SOLVER kindSolver = config_container[iZone]->GetKind_Solver(); - - if ((wallDistanceNeeded[iZone]) && (kindSolver != MAIN_SOLVER::FEM_LES) && (kindSolver != MAIN_SOLVER::FEM_RANS)) { - const auto* config = config_container[iZone]; - auto* geometry = geometry_container[iZone][iInst][MESH_0]; - - for (unsigned short iMarker = 0; iMarker < config->GetnMarker_All(); ++iMarker) { - const auto viscous = config->GetViscous_Wall(iMarker); - - SU2_OMP_FOR_STAT(OMP_MIN_SIZE) - for (auto iVertex = 0u; iVertex < geometry->nVertex[iMarker]; iVertex++) { - const auto iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); - su2double dist = 0; - if (viscous && geometry->nodes->GetDomain(iPoint)) { - dist = NearestNeighborDistance(geometry, config, iPoint); - } else { - dist = geometry->nodes->GetWall_Distance(iPoint); - } - geometry->vertex[iMarker][iVertex]->SetNearestNeighborDistance(dist); + if (!wallDistanceNeeded[iZone] || kindSolver == MAIN_SOLVER::FEM_LES || kindSolver == MAIN_SOLVER::FEM_RANS) { + continue; + } + const auto* config = config_container[iZone]; + auto* geometry = geometry_container[iZone][iInst][MESH_0]; + + for (unsigned short iMarker = 0; iMarker < config->GetnMarker_All(); ++iMarker) { + const auto viscous = config->GetViscous_Wall(iMarker); + + SU2_OMP_FOR_STAT(OMP_MIN_SIZE) + for (auto iVertex = 0u; iVertex < geometry->nVertex[iMarker]; iVertex++) { + const auto iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); + su2double dist = 0; + if (viscous && geometry->nodes->GetDomain(iPoint)) { + dist = NearestNeighborDistance(geometry, config, iPoint); + } else { + dist = geometry->nodes->GetWall_Distance(iPoint); } - END_SU2_OMP_FOR + geometry->vertex[iMarker][iVertex]->SetNearestNeighborDistance(dist); } + END_SU2_OMP_FOR } } } From cb37bacf6eb6122fc1d91c7bb95cec2377e2a484 Mon Sep 17 00:00:00 2001 From: Pedro Gomes <38071223+pcarruscag@users.noreply.github.com> Date: Tue, 25 Feb 2025 09:39:54 +0000 Subject: [PATCH 34/49] Apply suggestions from code review --- SU2_CFD/include/solvers/CFVMFlowSolverBase.inl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl index a3d1dabef87e..8a99712dc8e0 100644 --- a/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl +++ b/SU2_CFD/include/solvers/CFVMFlowSolverBase.inl @@ -2498,7 +2498,7 @@ void CFVMFlowSolverBase::Friction_Forces(const CGeometry* geometr FrictionVel = sqrt(fabs(WallShearStress[iMarker][iVertex]) / Density); if (!wallfunctions && MGLevel == MESH_0 && geometry->nodes->GetDomain(iPoint)) { - // for CMultiGridGeometry, the normal neighbor of halo nodes is not set + // for CMultiGridGeometry and halos, the nearest neighbor distance is not set const su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); YPlus[iMarker][iVertex] = WallDistMod * FrictionVel / (Viscosity / Density); } From 011589f04eda67ef9ff7e0c779abde3f78e64eed Mon Sep 17 00:00:00 2001 From: Pedro Gomes <38071223+pcarruscag@users.noreply.github.com> Date: Tue, 25 Feb 2025 09:43:50 +0000 Subject: [PATCH 35/49] Update SU2_CFD/src/solvers/CTurbSSTSolver.cpp --- SU2_CFD/src/solvers/CTurbSSTSolver.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp index 400ee1000234..8610fb8c26f4 100644 --- a/SU2_CFD/src/solvers/CTurbSSTSolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSSTSolver.cpp @@ -462,9 +462,8 @@ void CTurbSSTSolver::BC_HeatFlux_Wall(CGeometry *geometry, CSolver **solver_cont su2double wall_dist = geometry->vertex[val_marker][iVertex]->GetNearestNeighborDistance(); /*--- Set wall values ---*/ - const auto jPoint = geometry->vertex[val_marker][iVertex]->GetNormal_Neighbor(); - su2double density = solver_container[FLOW_SOL]->GetNodes()->GetDensity(jPoint); - su2double laminar_viscosity = solver_container[FLOW_SOL]->GetNodes()->GetLaminarViscosity(jPoint); + su2double density = solver_container[FLOW_SOL]->GetNodes()->GetDensity(iPoint); + su2double laminar_viscosity = solver_container[FLOW_SOL]->GetNodes()->GetLaminarViscosity(iPoint); su2double beta_1 = constants[4]; su2double solution[MAXNVAR]; From 3b5493d9b014e940513406ff80f8316e91d87cf2 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Tue, 25 Feb 2025 20:17:51 +0100 Subject: [PATCH 36/49] revert nearestneighbor --- SU2_CFD/src/solvers/CIncNSSolver.cpp | 3 +-- SU2_CFD/src/solvers/CNSSolver.cpp | 3 +-- SU2_CFD/src/solvers/CTurbSASolver.cpp | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/SU2_CFD/src/solvers/CIncNSSolver.cpp b/SU2_CFD/src/solvers/CIncNSSolver.cpp index 365febfad040..8cd20dfeb83a 100644 --- a/SU2_CFD/src/solvers/CIncNSSolver.cpp +++ b/SU2_CFD/src/solvers/CIncNSSolver.cpp @@ -686,8 +686,7 @@ void CIncNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_containe /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ - su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); - + su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); su2double Density_Wall = nodes->GetDensity(iPoint); /*--- Compute the shear stress at the wall in the regular fashion diff --git a/SU2_CFD/src/solvers/CNSSolver.cpp b/SU2_CFD/src/solvers/CNSSolver.cpp index 30412de453e1..6c2f4d4bb129 100644 --- a/SU2_CFD/src/solvers/CNSSolver.cpp +++ b/SU2_CFD/src/solvers/CNSSolver.cpp @@ -865,8 +865,7 @@ void CNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_container, /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ - const su2double WallDistMod = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); - + const su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); su2double T_Wall = nodes->GetTemperature(iPoint); const su2double Conductivity_Wall = nodes->GetThermalConductivity(iPoint); diff --git a/SU2_CFD/src/solvers/CTurbSASolver.cpp b/SU2_CFD/src/solvers/CTurbSASolver.cpp index d29b668edd85..b66eedd4d99a 100644 --- a/SU2_CFD/src/solvers/CTurbSASolver.cpp +++ b/SU2_CFD/src/solvers/CTurbSASolver.cpp @@ -275,7 +275,7 @@ void CTurbSASolver::Postprocessing(CGeometry *geometry, CSolver **solver_contain FrictionVelocity = sqrt(flowNodes->GetLaminarViscosity(iPoint)*VorticityMag); } - const su2double wall_dist = geometry->vertex[iMarker][iVertex]->GetNearestNeighborDistance(); + const su2double wall_dist = geometry->nodes->GetWall_Distance(jPoint); const su2double Derivative = nodes->GetSolution(jPoint, 0) / wall_dist; const su2double turbulence_index = Derivative / (FrictionVelocity * 0.41); From 0bc734e829881cf6a0ac7d620cd2ccf766e5bc5d Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Thu, 27 Feb 2025 09:22:51 +0000 Subject: [PATCH 37/49] remove virtual function --- SU2_CFD/include/variables/CFlowVariable.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SU2_CFD/include/variables/CFlowVariable.hpp b/SU2_CFD/include/variables/CFlowVariable.hpp index 95d59c083ad3..d4d770f0ba8d 100644 --- a/SU2_CFD/include/variables/CFlowVariable.hpp +++ b/SU2_CFD/include/variables/CFlowVariable.hpp @@ -260,7 +260,7 @@ class CFlowVariable : public CVariable { * \param[in] iPoint - Point index. * \return Value of magnitude. */ - inline su2double GetStrainMag(unsigned long iPoint) const final { return StrainMag(iPoint); } + inline su2double GetStrainMag(unsigned long iPoint) const { return StrainMag(iPoint); } /*! * \brief Get the entire vector of the rate of strain magnitude. From 662f0d8e72947aa4311c65894186ec2dd99898ca Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Thu, 27 Feb 2025 09:24:00 +0000 Subject: [PATCH 38/49] format --- Common/src/geometry/CGeometry.cpp | 1 - SU2_CFD/include/variables/CVariable.hpp | 7 ------- 2 files changed, 8 deletions(-) diff --git a/Common/src/geometry/CGeometry.cpp b/Common/src/geometry/CGeometry.cpp index f83e362c6a7c..1301ee6b5a39 100644 --- a/Common/src/geometry/CGeometry.cpp +++ b/Common/src/geometry/CGeometry.cpp @@ -4000,7 +4000,6 @@ void CGeometry::ComputeWallDistance(const CConfig* const* config_container, CGeo } for (int iZone = 0; iZone < nZone; iZone++) { - /*--- For the FEM solver, we use a different mesh structure ---*/ MAIN_SOLVER kindSolver = config_container[iZone]->GetKind_Solver(); if (!wallDistanceNeeded[iZone] || kindSolver == MAIN_SOLVER::FEM_LES || kindSolver == MAIN_SOLVER::FEM_RANS) { diff --git a/SU2_CFD/include/variables/CVariable.hpp b/SU2_CFD/include/variables/CVariable.hpp index bc855bc5dca5..98e8c2538196 100644 --- a/SU2_CFD/include/variables/CVariable.hpp +++ b/SU2_CFD/include/variables/CVariable.hpp @@ -1147,13 +1147,6 @@ class CVariable { inline virtual su2double *GetVorticity(unsigned long iPoint) { return nullptr; } inline virtual const su2double *GetVorticity(unsigned long iPoint) const { return nullptr; } - /*! - * \brief A virtual member. - * \param[in] iPoint - Point index. - * \return Value of the rate of strain magnitude. - */ - inline virtual su2double GetStrainMag(unsigned long iPoint) const { return 0.0; } - /*! * \brief A virtual member. * \param[in] iPoint - Point index. From 131f47f678c68b43335917ef40e956d7b4dde9ad Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sat, 1 Mar 2025 09:57:15 +0000 Subject: [PATCH 39/49] fix reverts --- SU2_CFD/src/solvers/CIncNSSolver.cpp | 4 ++-- SU2_CFD/src/solvers/CNSSolver.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/SU2_CFD/src/solvers/CIncNSSolver.cpp b/SU2_CFD/src/solvers/CIncNSSolver.cpp index 8cd20dfeb83a..f6999d453f4c 100644 --- a/SU2_CFD/src/solvers/CIncNSSolver.cpp +++ b/SU2_CFD/src/solvers/CIncNSSolver.cpp @@ -684,9 +684,9 @@ void CIncNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_containe const su2double VelTangMod = GeometryToolbox::Norm(int(MAXNDIM), VelTang); - /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ + /*--- Compute normal distance of the interior point from the wall ---*/ + const su2double WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); - su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); su2double Density_Wall = nodes->GetDensity(iPoint); /*--- Compute the shear stress at the wall in the regular fashion diff --git a/SU2_CFD/src/solvers/CNSSolver.cpp b/SU2_CFD/src/solvers/CNSSolver.cpp index 6c2f4d4bb129..fef4a352b2a7 100644 --- a/SU2_CFD/src/solvers/CNSSolver.cpp +++ b/SU2_CFD/src/solvers/CNSSolver.cpp @@ -863,9 +863,9 @@ void CNSSolver::SetTau_Wall_WF(CGeometry *geometry, CSolver **solver_container, const su2double VelTangMod = GeometryToolbox::Norm(int(MAXNDIM), VelTang); - /*--- Compute nearest-neighbor distance of the interior point from the wall ---*/ + /*--- Compute normal distance of the interior point from the wall ---*/ + const su2double WallDistMod = GeometryToolbox::Distance(nDim, Coord, Coord_Normal); - const su2double WallDistMod = GeometryToolbox::Norm(int(MAXNDIM), WallDist); su2double T_Wall = nodes->GetTemperature(iPoint); const su2double Conductivity_Wall = nodes->GetThermalConductivity(iPoint); From a27e2461b1cf56787d49acc1e9663cd11d0b693f Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sat, 1 Mar 2025 12:10:01 +0000 Subject: [PATCH 40/49] some updates --- TestCases/hybrid_regression.py | 22 +++++------ TestCases/parallel_regression.py | 68 ++++++++++++++++---------------- TestCases/serial_regression.py | 32 +++++++-------- TestCases/tutorials.py | 6 +-- 4 files changed, 64 insertions(+), 64 deletions(-) diff --git a/TestCases/hybrid_regression.py b/TestCases/hybrid_regression.py index 14c6c66b0aa4..b3b489bcd81e 100644 --- a/TestCases/hybrid_regression.py +++ b/TestCases/hybrid_regression.py @@ -165,7 +165,7 @@ def main(): rae2822_sst.cfg_dir = "rans/rae2822" rae2822_sst.cfg_file = "turb_SST_RAE2822.cfg" rae2822_sst.test_iter = 20 - rae2822_sst.test_vals = [-0.510363, 4.872736, 0.815617, 0.060920, 0] + rae2822_sst.test_vals = [-0.510371, 4.905635, 0.811981, 0.061600, 0.000000] test_list.append(rae2822_sst) # RAE2822 SST_SUST @@ -173,7 +173,7 @@ def main(): rae2822_sst_sust.cfg_dir = "rans/rae2822" rae2822_sst_sust.cfg_file = "turb_SST_SUST_RAE2822.cfg" rae2822_sst_sust.test_iter = 20 - rae2822_sst_sust.test_vals = [-2.535141, 4.872736, 0.815617, 0.060920] + rae2822_sst_sust.test_vals = [-2.569447, 4.905635, 0.811980, 0.061600] test_list.append(rae2822_sst_sust) # Flat plate @@ -230,7 +230,7 @@ def main(): turb_naca0012_sst_expliciteuler.cfg_dir = "rans/naca0012" turb_naca0012_sst_expliciteuler.cfg_file = "turb_NACA0012_sst_expliciteuler.cfg" turb_naca0012_sst_expliciteuler.test_iter = 10 - turb_naca0012_sst_expliciteuler.test_vals = [-3.533827, -3.157766, 3.364024, 1.122856, 0.500771, -float("inf")] + turb_naca0012_sst_expliciteuler.test_vals = [-3.533765, -3.157766, 3.364026, 1.124760, 0.501702, -float("inf")] test_list.append(turb_naca0012_sst_expliciteuler) # PROPELLER @@ -275,7 +275,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.976788, 1.141079, 0.246365, -0.116758] + turb_naca0012_1c.test_vals = [-4.976353, 1.141375, 0.243102, -0.112154] turb_naca0012_1c.test_vals_aarch64 = [-4.981105, 1.138873, 0.248013, -0.117248] test_list.append(turb_naca0012_1c) @@ -284,7 +284,7 @@ def main(): turb_naca0012_2c.cfg_dir = "rans_uq/naca0012" turb_naca0012_2c.cfg_file = "turb_NACA0012_uq_2c.cfg" turb_naca0012_2c.test_iter = 10 - turb_naca0012_2c.test_vals = [-5.485942, 0.967831, 0.236638, -0.119183] + turb_naca0012_2c.test_vals = [-5.485942, 0.968057, 0.233600, -0.114502] turb_naca0012_2c.test_vals_aarch64 = [-5.483345, 0.968720, 0.214914, -0.124932] test_list.append(turb_naca0012_2c) @@ -293,7 +293,7 @@ def main(): turb_naca0012_3c.cfg_dir = "rans_uq/naca0012" turb_naca0012_3c.cfg_file = "turb_NACA0012_uq_3c.cfg" turb_naca0012_3c.test_iter = 10 - turb_naca0012_3c.test_vals = [-5.584306, 0.931276, 0.226035, -0.120956] + turb_naca0012_3c.test_vals = [-5.584306, 0.931465, 0.223394, -0.116130] turb_naca0012_3c.test_vals_aarch64 = [-5.584300, 0.931293, 0.207447, -0.125691] test_list.append(turb_naca0012_3c) @@ -302,7 +302,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.114407, 1.076496, 0.227388, -0.123537] + turb_naca0012_p1c1.test_vals = [-5.114258, 1.076587, 0.224375, -0.118856] turb_naca0012_p1c1.test_vals_aarch64 = [-5.132358, 1.075658, 0.337268, -0.082827] test_list.append(turb_naca0012_p1c1) @@ -411,7 +411,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.317191, 0.018255, 0.000004, 0.307677] + inc_turb_naca0012_sst_sust.test_vals = [-7.291693, 0.132607, 0.000002, 0.312092] test_list.append(inc_turb_naca0012_sst_sust) # Weakly coupled heat equation @@ -452,7 +452,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-2.560839, -1.173496, 0.061335, 1.399403, 2.220575, 1.399351, 2.218781, 0.000000] + square_cylinder.test_vals = [-2.560839, -1.176729, 0.061954, 1.399401, 2.220361, 1.399349, 2.218600, 0.000000] square_cylinder.test_vals_aarch64 = [-2.557902, -1.173574, 0.058050, 1.399794, 2.220402, 1.399748, 2.218604, 0] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -564,7 +564,7 @@ def main(): axial_stage2D.cfg_dir = "turbomachinery/axial_stage_2D" axial_stage2D.cfg_file = "Axial_stage2D.cfg" axial_stage2D.test_iter = 20 - axial_stage2D.test_vals = [0.987667, 1.531950, -2.888460, 2.606789, -2.418222, 3.087180, 106380.000000, 106380.000000, 5.733000, 64.728000] + axial_stage2D.test_vals = [1.108159, 1.561741, -2.895046, 2.607615, -2.479708, 3.063739, 106380.000000, 106380.000000, 5.733600, 64.747000] axial_stage2D.test_vals_aarch64 = [0.983739, 1.534333, -2.888521, 2.606770, -2.418339, 3.087275, 106380, 106380, 5.7325, 64.711] test_list.append(axial_stage2D) @@ -657,7 +657,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.726398, -1.700012] + bars_SST_2D.test_vals = [13.000000, 0.268825, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index d9c38c9f095b..ba81770d5d70 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -365,7 +365,7 @@ def main(): rae2822_sst.cfg_dir = "rans/rae2822" rae2822_sst.cfg_file = "turb_SST_RAE2822.cfg" rae2822_sst.test_iter = 20 - rae2822_sst.test_vals = [-0.510369, 4.870657, 0.816646, 0.061832, 0.000000] + rae2822_sst.test_vals = [-0.510367, 4.902122, 0.813791, 0.062425, 0.000000] test_list.append(rae2822_sst) # RAE2822 SST_SUST @@ -373,7 +373,7 @@ def main(): rae2822_sst_sust.cfg_dir = "rans/rae2822" rae2822_sst_sust.cfg_file = "turb_SST_SUST_RAE2822.cfg" rae2822_sst_sust.test_iter = 20 - rae2822_sst_sust.test_vals = [-2.537371, 4.870656, 0.816646, 0.061832] + rae2822_sst_sust.test_vals = [-2.569628, 4.902122, 0.813791, 0.062425] test_list.append(rae2822_sst_sust) # Flat plate @@ -397,7 +397,7 @@ def main(): turb_flatplate_CC_Wilcox.cfg_dir = "rans/flatplate" turb_flatplate_CC_Wilcox.cfg_file = "turb_SST_flatplate_compressibility_Wilcox.cfg" turb_flatplate_CC_Wilcox.test_iter = 20 - turb_flatplate_CC_Wilcox.test_vals = [-1.280875, 1.974212, 1.440454, 5.038401, -4.047412, 11.905193] + turb_flatplate_CC_Wilcox.test_vals = [-1.280875, 1.974210, 1.440441, 5.038396, -4.052127, 11.904843] test_list.append(turb_flatplate_CC_Wilcox) # Flat plate SST compressibility correction Sarkar @@ -405,7 +405,7 @@ def main(): turb_flatplate_CC_Sarkar.cfg_dir = "rans/flatplate" turb_flatplate_CC_Sarkar.cfg_file = "turb_SST_flatplate_compressibility_Sarkar.cfg" turb_flatplate_CC_Sarkar.test_iter = 20 - turb_flatplate_CC_Sarkar.test_vals = [-1.280875, 1.974212, 1.440454, 5.038401, -4.047415, 11.905193] + turb_flatplate_CC_Sarkar.test_vals = [-1.280875, 1.974210, 1.440441, 5.038396, -4.052131, 11.904843] test_list.append(turb_flatplate_CC_Sarkar) # ONERA M6 Wing @@ -450,7 +450,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-8.515763, -10.746560, -4.508015, 1.047852, 0.019161, -1.928310, 0.000000] + turb_naca0012_sst.test_vals = [-8.515393, -10.746513, -4.384035, 1.047851, 0.019161, -1.928467, 0.000000] turb_naca0012_sst.test_vals_aarch64 = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -460,7 +460,7 @@ def main(): turb_naca0012_sst_sust.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust.test_iter = 10 - turb_naca0012_sst_sust.test_vals = [-8.014970, -10.320396, -3.314234, 0.994867, 0.019306, -1.983851] + turb_naca0012_sst_sust.test_vals = [-8.040159, -10.043114, -3.511447, 0.997716, 0.019035, -1.409880] turb_naca0012_sst_sust.test_vals_aarch64 = [-12.087234, -14.827336, -6.062338, 1.000276, 0.019495, -1.779654] turb_naca0012_sst_sust.timeout = 3200 test_list.append(turb_naca0012_sst_sust) @@ -470,7 +470,7 @@ def main(): turb_naca0012_sst_2003_Vm.cfg_dir = "rans/naca0012" turb_naca0012_sst_2003_Vm.cfg_file = "turb_NACA0012_sst_2003-Vm.cfg" turb_naca0012_sst_2003_Vm.test_iter = 10 - turb_naca0012_sst_2003_Vm.test_vals = [-7.632098, -10.013971, -3.340316, 1.046165, 0.019728, -2.059096] + turb_naca0012_sst_2003_Vm.test_vals = [-8.123539, -10.281917, -3.540665, 1.045725, 0.019271, -1.656078] turb_naca0012_sst_2003_Vm.timeout = 3200 test_list.append(turb_naca0012_sst_2003_Vm) @@ -479,7 +479,7 @@ def main(): turb_naca0012_sst_1994_KLm.cfg_dir = "rans/naca0012" turb_naca0012_sst_1994_KLm.cfg_file = "turb_NACA0012_sst_1994-KLm.cfg" turb_naca0012_sst_1994_KLm.test_iter = 10 - turb_naca0012_sst_1994_KLm.test_vals = [-8.334601, -10.630535, -3.933399, 1.047158, 0.019197, -1.876800] + turb_naca0012_sst_1994_KLm.test_vals = [-8.334419, -10.630544, -3.917441, 1.047157, 0.019197, -1.877042] turb_naca0012_sst_1994_KLm.timeout = 3200 test_list.append(turb_naca0012_sst_1994_KLm) @@ -489,7 +489,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.216624, -10.018910, -1.615147, 1.021843, 0.040325, -3.728934] + turb_naca0012_sst_fixedvalues.test_vals = [-5.216567, -10.242833, -1.565507, 1.022391, 0.040547, -3.738426] turb_naca0012_sst_fixedvalues.timeout = 3200 test_list.append(turb_naca0012_sst_fixedvalues) @@ -498,7 +498,7 @@ def main(): turb_naca0012_sst_expliciteuler.cfg_dir = "rans/naca0012" turb_naca0012_sst_expliciteuler.cfg_file = "turb_NACA0012_sst_expliciteuler.cfg" turb_naca0012_sst_expliciteuler.test_iter = 10 - turb_naca0012_sst_expliciteuler.test_vals = [-3.533827, -3.157766, 3.364024, 1.122856, 0.500771, -float("inf")] + turb_naca0012_sst_expliciteuler.test_vals = [-3.533765, -3.157766, 3.364026, 1.124760, 0.501702, -float("inf")] turb_naca0012_sst_expliciteuler.timeout = 3200 test_list.append(turb_naca0012_sst_expliciteuler) @@ -530,7 +530,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-6.038034, -0.474087, -2.205683, 2.476084, 0.000000] + axi_rans_air_nozzle_restart.test_vals = [-5.503924, 0.122159, -1.251673, 3.349405, 0.000000] axi_rans_air_nozzle_restart.tol = 0.0001 test_list.append(axi_rans_air_nozzle_restart) @@ -544,7 +544,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 20 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.612218, -7.425695, -0.631759, -0.000022, 0.079116] + turb_naca0012_sst_restart_mg.test_vals = [-7.600526, -7.181993, -0.627166, -0.000016, 0.078729] turb_naca0012_sst_restart_mg.timeout = 3200 turb_naca0012_sst_restart_mg.tol = 0.000001 test_list.append(turb_naca0012_sst_restart_mg) @@ -646,7 +646,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.316933, 0.018242, -0.000001, 0.307687] + inc_turb_naca0012_sst_sust.test_vals = [-7.291511, 0.132644, -0.000001, 0.312109] test_list.append(inc_turb_naca0012_sst_sust) #################### @@ -881,7 +881,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.980989, 1.139860, 0.469698, -0.081433] + turb_naca0012_1c.test_vals = [-4.981013, 1.139991, 0.466303, -0.076862] test_list.append(turb_naca0012_1c) # NACA0012 2c @@ -889,7 +889,7 @@ def main(): turb_naca0012_2c.cfg_dir = "rans_uq/naca0012" turb_naca0012_2c.cfg_file = "turb_NACA0012_uq_2c.cfg" turb_naca0012_2c.test_iter = 10 - turb_naca0012_2c.test_vals = [-5.484979, 0.968141, 0.320681, -0.114600] + turb_naca0012_2c.test_vals = [-5.484979, 0.968345, 0.317774, -0.109857] test_list.append(turb_naca0012_2c) # NACA0012 3c @@ -897,7 +897,7 @@ def main(): turb_naca0012_3c.cfg_dir = "rans_uq/naca0012" turb_naca0012_3c.cfg_file = "turb_NACA0012_uq_3c.cfg" turb_naca0012_3c.test_iter = 10 - turb_naca0012_3c.test_vals = [-5.584315, 0.931289, 0.277094, -0.118251] + turb_naca0012_3c.test_vals = [-5.584315, 0.931447, 0.274234, -0.113498] test_list.append(turb_naca0012_3c) # NACA0012 p1c1 @@ -905,7 +905,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.122388, 1.074056, 0.415434, -0.096182] + turb_naca0012_p1c1.test_vals = [-5.122291, 1.074243, 0.412316, -0.091523] test_list.append(turb_naca0012_p1c1) # NACA0012 p1c2 @@ -913,7 +913,7 @@ def main(): turb_naca0012_p1c2.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c2.cfg_file = "turb_NACA0012_uq_p1c2.cfg" turb_naca0012_p1c2.test_iter = 10 - turb_naca0012_p1c2.test_vals = [-5.549596, 0.945538, 0.287381, -0.117021] + turb_naca0012_p1c2.test_vals = [-5.549595, 0.945688, 0.284500, -0.112282] test_list.append(turb_naca0012_p1c2) ###################################### @@ -974,7 +974,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-1.173495, 0.061334, 1.399404, 2.220578, 1.399352, 2.218783, 0.000000] + square_cylinder.test_vals = [-1.176727, 0.061953, 1.399402, 2.220364, 1.399350, 2.218602, 0.000000] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -1048,7 +1048,7 @@ def main(): coolprop_fluidModel.cfg_dir = "nicf/coolprop" coolprop_fluidModel.cfg_file = "fluidModel.cfg" coolprop_fluidModel.test_iter = 5 - coolprop_fluidModel.test_vals = [-4.424953, -1.582877, 3.720586, 0.000000, 0.000000] + coolprop_fluidModel.test_vals = [-4.424952, -1.583033, 3.720621, 0.000000, 0.000000] coolprop_fluidModel.enabled_on_cpu_arch = ["x86_64"] test_list.append(coolprop_fluidModel) @@ -1057,7 +1057,7 @@ def main(): coolprop_transportModel.cfg_dir = "nicf/coolprop" coolprop_transportModel.cfg_file = "transportModel.cfg" coolprop_transportModel.test_iter = 5 - coolprop_transportModel.test_vals = [-4.428098, -1.314332, 4.666153, 0.000000, 0.000000] + coolprop_transportModel.test_vals = [-4.428096, -1.314555, 4.666156, 0.000000, 0.000000] coolprop_transportModel.enabled_on_cpu_arch = ["x86_64"] test_list.append(coolprop_transportModel) @@ -1066,7 +1066,7 @@ def main(): datadriven_fluidModel.cfg_dir = "nicf/datadriven" datadriven_fluidModel.cfg_file = "datadriven_nozzle.cfg" datadriven_fluidModel.test_iter = 50 - datadriven_fluidModel.test_vals = [-2.632817, 0.155922, 4.690917, 0.000000, 0.000000] + datadriven_fluidModel.test_vals = [-2.632720, 0.156604, 4.691528, 0.000000, 0.000000] test_list.append(datadriven_fluidModel) ###################################### @@ -1094,7 +1094,7 @@ def main(): axial_stage2D.cfg_dir = "turbomachinery/axial_stage_2D" axial_stage2D.cfg_file = "Axial_stage2D.cfg" axial_stage2D.test_iter = 20 - axial_stage2D.test_vals = [0.987681, 1.532093, -2.888460, 2.606791, -2.418287, 3.087104, 106380, 106380, 5.7329, 64.728] + axial_stage2D.test_vals = [1.108171, 1.561780, -2.895045, 2.607616, -2.479708, 3.063740, 106380.000000, 106380.000000, 5.733600, 64.747000] test_list.append(axial_stage2D) # 2D transonic stator restart @@ -1185,7 +1185,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.726399, -1.700012] + bars_SST_2D.test_vals = [13.000000, 0.268760, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) @@ -1337,7 +1337,7 @@ def main(): sp_pinArray_cht_2d_dp_hf.cfg_dir = "incomp_navierstokes/streamwise_periodic/chtPinArray_2d" sp_pinArray_cht_2d_dp_hf.cfg_file = "configMaster.cfg" sp_pinArray_cht_2d_dp_hf.test_iter = 100 - sp_pinArray_cht_2d_dp_hf.test_vals = [0.088590, -0.764262, -1.086946, -0.747448, 208.023676, 344.680000, -0.000000, -0.747450, 0.747450] + sp_pinArray_cht_2d_dp_hf.test_vals = [0.548558, -0.379295, -1.007163, -0.732245, 208.023676, 334.010000, -0.000000, -0.732240, 0.732240] sp_pinArray_cht_2d_dp_hf.multizone = True test_list.append(sp_pinArray_cht_2d_dp_hf) @@ -1346,8 +1346,8 @@ def main(): sp_pinArray_3d_cht_mf_hf_tp.cfg_dir = "incomp_navierstokes/streamwise_periodic/chtPinArray_3d" sp_pinArray_3d_cht_mf_hf_tp.cfg_file = "configMaster.cfg" sp_pinArray_3d_cht_mf_hf_tp.test_iter = 30 - sp_pinArray_3d_cht_mf_hf_tp.test_vals = [-1.612910, -2.837554, -3.507895, -0.009728, 104.631202, 418.360000, 0.000000] - sp_pinArray_3d_cht_mf_hf_tp.test_vals_aarch64 = [-1.622914, -3.081114, -4.576282, -0.009725, 104.632412, 418.370000, 0.000000] + sp_pinArray_3d_cht_mf_hf_tp.test_vals = [-1.117102, -1.880628, -2.561816, -0.009804, 104.600540, 418.360000, 0.000000] + sp_pinArray_3d_cht_mf_hf_tp.test_vals_aarch64 = [-1.117102, -1.880628, -2.561816, -0.009804, 104.600540, 418.360000, 0.000000] sp_pinArray_3d_cht_mf_hf_tp.multizone = True test_list.append(sp_pinArray_3d_cht_mf_hf_tp) @@ -1381,7 +1381,7 @@ def main(): pywrapper_square_cylinder.cfg_dir = "unsteady/square_cylinder" pywrapper_square_cylinder.cfg_file = "turb_square.cfg" pywrapper_square_cylinder.test_iter = 10 - pywrapper_square_cylinder.test_vals = [-1.176405, -0.354027, 1.407859, 2.360784, 1.404715, 2.302615, 0] + pywrapper_square_cylinder.test_vals = [-1.181633, -0.354608, 1.401055, 2.358088, 1.401417, 2.301179, 0] pywrapper_square_cylinder.command = TestCase.Command("mpirun -np 2", "SU2_CFD.py", "--parallel -f") pywrapper_square_cylinder.unsteady = True test_list.append(pywrapper_square_cylinder) @@ -1433,7 +1433,7 @@ def main(): pywrapper_unsteadyCHT.cfg_dir = "py_wrapper/flatPlate_unsteady_CHT" pywrapper_unsteadyCHT.cfg_file = "unsteady_CHT_FlatPlate_Conf.cfg" pywrapper_unsteadyCHT.test_iter = 5 - pywrapper_unsteadyCHT.test_vals = [-1.614167, 2.240663, -0.001392, 0.177499] + pywrapper_unsteadyCHT.test_vals = [-1.614167, 2.246133, -0.001388, 0.172996] pywrapper_unsteadyCHT.command = TestCase.Command("mpirun -np 2", "python", "launch_unsteady_CHT_FlatPlate.py --parallel -f") pywrapper_unsteadyCHT.unsteady = True test_list.append(pywrapper_unsteadyCHT) @@ -1443,7 +1443,7 @@ def main(): pywrapper_rigidMotion.cfg_dir = "py_wrapper/flatPlate_rigidMotion" pywrapper_rigidMotion.cfg_file = "flatPlate_rigidMotion_Conf.cfg" pywrapper_rigidMotion.test_iter = 5 - pywrapper_rigidMotion.test_vals = [-1.614165, 2.238591, 0.349970, 0.095593] + pywrapper_rigidMotion.test_vals = [-1.614165, 2.243155, 0.350196, 0.089497] pywrapper_rigidMotion.command = TestCase.Command("mpirun -np 2", "python", "launch_flatPlate_rigidMotion.py --parallel -f") pywrapper_rigidMotion.unsteady = True test_list.append(pywrapper_rigidMotion) @@ -1525,7 +1525,7 @@ def main(): species2_primitiveVenturi_mixingmodel.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi_mixingmodel.cfg_file = "species2_primitiveVenturi_mixingmodel.cfg" species2_primitiveVenturi_mixingmodel.test_iter = 50 - species2_primitiveVenturi_mixingmodel.test_vals = [ -5.407755, -4.557255, -4.635502, -5.642910, -0.059627, -5.546376, 5.000000, -1.879995, 5.000000, -4.898985, 5.000000, -1.169389, 0.000551, 0.000483, 0.000068, 0.000000] + species2_primitiveVenturi_mixingmodel.test_vals = [-5.433571, -4.507202, -4.599966, -5.856697, -0.076061, -5.608935, 5.000000, -1.897907, 5.000000, -4.894972, 5.000000, -1.202673, 0.000538, 0.000476, 0.000062, 0.000000] test_list.append(species2_primitiveVenturi_mixingmodel) # 2 species (1 eq) primitive venturi mixing using mixing model and bounded scalar transport @@ -1533,7 +1533,7 @@ def main(): species2_primitiveVenturi_mixingmodel_boundedscalar.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi_mixingmodel_boundedscalar.cfg_file = "species2_primitiveVenturi_mixingmodel_boundedscalar.cfg" species2_primitiveVenturi_mixingmodel_boundedscalar.test_iter = 50 - species2_primitiveVenturi_mixingmodel_boundedscalar.test_vals = [-5.392378, -4.492373, -4.576491, -5.759780, -0.137797, -5.677531, 5.000000, -1.895013, 5.000000, -4.806816, 5.000000, -1.697769, 0.000275, 0.000275, 0.000000, 0.000000] + species2_primitiveVenturi_mixingmodel_boundedscalar.test_vals = [-5.397959, -4.441556, -4.532005, -6.118886, -0.129272, -5.681345, 5.000000, -1.986039, 5.000000, -4.961054, 5.000000, -1.880403, 0.000297, 0.000297, 0.000000, 0.000000] test_list.append(species2_primitiveVenturi_mixingmodel_boundedscalar) # 2 species (1 eq) primitive venturi mixing using mixing model including viscosity, thermal conductivity and inlet markers for SA turbulence model @@ -1549,7 +1549,7 @@ def main(): species2_primitiveVenturi_mixingmodel_heatcapacity_H2.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi_mixingmodel_heatcapacity_H2.cfg_file = "species2_primitiveVenturi_mixingmodel_heatcapacity_H2.cfg" species2_primitiveVenturi_mixingmodel_heatcapacity_H2.test_iter = 50 - species2_primitiveVenturi_mixingmodel_heatcapacity_H2.test_vals = [-5.688779, -4.556193, -4.513326, -6.563666, 2.298459, -5.423525, 30.000000, -6.903871, 13.000000, -8.224587, 8.000000, -9.119625, 2.078869, 1.000000, 0.600000, 0.478869] + species2_primitiveVenturi_mixingmodel_heatcapacity_H2.test_vals = [-5.704159, -4.581981, -4.519914, -6.960130, 2.304741, -5.429054, 30.000000, -6.864204, 12.000000, -8.228958, 8.000000, -9.215808, 2.079379, 1.000000, 0.600000, 0.479379] test_list.append(species2_primitiveVenturi_mixingmodel_heatcapacity_H2) # 2 species (1 eq) primitive venturi mixing using mixing model including heat capacity and mass diffusivity NonDimensional case @@ -1557,7 +1557,7 @@ def main(): species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.cfg_file = "species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.cfg" species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.test_iter = 50 - species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.test_vals = [-5.287504, -4.852957, -4.798004, -7.501815, 1.991002, -5.023713, 10.000000, -2.696121, 3.000000, -5.182457, 5.000000, -5.561055, 2.078843, 1.000000, 0.600000, 0.478843] + species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND.test_vals = [-5.304586, -4.884409, -4.811332, -7.928962, 1.999898, -5.034484, 10.000000, -2.603534, 3.000000, -5.374631, 5.000000, -5.612314, 2.079522, 1.000000, 0.600000, 0.479522] test_list.append(species2_primitiveVenturi_mixingmodel_heatcapacity_H2_ND) # 2 species (1 eq) primitive venturi mixing diff --git a/TestCases/serial_regression.py b/TestCases/serial_regression.py index 30fcd2eef827..d602c921635a 100644 --- a/TestCases/serial_regression.py +++ b/TestCases/serial_regression.py @@ -226,7 +226,7 @@ def main(): rae2822_sst.cfg_dir = "rans/rae2822" rae2822_sst.cfg_file = "turb_SST_RAE2822.cfg" rae2822_sst.test_iter = 20 - rae2822_sst.test_vals = [-0.510376, 4.873617, 0.816197, 0.060504, 0] + rae2822_sst.test_vals = [-0.510374, 4.906793, 0.812735, 0.061081, 0.000000] test_list.append(rae2822_sst) # RAE2822 SST_SUST @@ -234,7 +234,7 @@ def main(): rae2822_sst_sust.cfg_dir = "rans/rae2822" rae2822_sst_sust.cfg_file = "turb_SST_SUST_RAE2822.cfg" rae2822_sst_sust.test_iter = 20 - rae2822_sst_sust.test_vals = [-2.536147, 4.873615, 0.816197, 0.060504] + rae2822_sst_sust.test_vals = [-2.571683, 4.906792, 0.812735, 0.061081] test_list.append(rae2822_sst_sust) # Flat plate @@ -250,7 +250,7 @@ def main(): turb_wallfunction_flatplate_sst.cfg_dir = "wallfunctions/flatplate/compressible_SST" turb_wallfunction_flatplate_sst.cfg_file = "turb_SST_flatplate.cfg" turb_wallfunction_flatplate_sst.test_iter = 10 - turb_wallfunction_flatplate_sst.test_vals = [-4.394471, -1.877558, -1.960378, 0.983694, -1.255671, 1.566842, 10.000000, -1.763190, 0.034806, 0.002921] + turb_wallfunction_flatplate_sst.test_vals = [-4.541780, -1.933200, -1.940897, 0.941215, -1.609670, 1.488457, 10.000000, -1.747275, 0.034238, 0.002427] test_list.append(turb_wallfunction_flatplate_sst) # FLAT PLATE, WALL FUNCTIONS, COMPRESSIBLE SA @@ -284,7 +284,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-8.507630, -10.746643, -4.514387, 1.047906, 0.019158, -1.724758, 0.000000] + turb_naca0012_sst.test_vals = [-8.507252, -10.746596, -4.388968, 1.047904, 0.019158, -1.724811, 0.000000] turb_naca0012_sst.test_vals_aarch64 = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -457,7 +457,7 @@ def main(): inc_turb_wallfunction_flatplate_sst.cfg_dir = "wallfunctions/flatplate/incompressible_SST" inc_turb_wallfunction_flatplate_sst.cfg_file = "turb_SST_flatplate.cfg" inc_turb_wallfunction_flatplate_sst.test_iter = 10 - inc_turb_wallfunction_flatplate_sst.test_vals = [-6.507362, -5.693894, -6.434063, -4.223774, -7.008049, -1.954102, 10.000000, -3.047554, 0.001081, 0.003644, 0] + inc_turb_wallfunction_flatplate_sst.test_vals = [-6.512787, -5.722412, -6.414362, -4.223877, -7.162308, -2.044027, 10.000000, -3.059125, 0.001126, 0.003161, 0.000000] test_list.append(inc_turb_wallfunction_flatplate_sst) # FLAT PLATE, WALL FUNCTIONS, INCOMPRESSIBLE SA @@ -677,7 +677,7 @@ def main(): turb_naca0012_1c.cfg_dir = "rans_uq/naca0012" turb_naca0012_1c.cfg_file = "turb_NACA0012_uq_1c.cfg" turb_naca0012_1c.test_iter = 10 - turb_naca0012_1c.test_vals = [-4.992120, 1.134942, 0.356070, -0.089068] + turb_naca0012_1c.test_vals = [-4.992596, 1.134903, 0.352867, -0.084425] test_list.append(turb_naca0012_1c) # NACA0012 2c @@ -685,7 +685,7 @@ def main(): turb_naca0012_2c.cfg_dir = "rans_uq/naca0012" turb_naca0012_2c.cfg_file = "turb_NACA0012_uq_2c.cfg" turb_naca0012_2c.test_iter = 10 - turb_naca0012_2c.test_vals = [-5.485136, 0.968105, 0.273199, -0.110329] + turb_naca0012_2c.test_vals = [-5.485136, 0.968303, 0.270450, -0.105529] test_list.append(turb_naca0012_2c) # NACA0012 3c @@ -693,7 +693,7 @@ def main(): turb_naca0012_3c.cfg_dir = "rans_uq/naca0012" turb_naca0012_3c.cfg_file = "turb_NACA0012_uq_3c.cfg" turb_naca0012_3c.test_iter = 10 - turb_naca0012_3c.test_vals = [-5.584305, 0.931283, 0.250707, -0.113586] + turb_naca0012_3c.test_vals = [-5.584305, 0.931441, 0.248013, -0.108776] test_list.append(turb_naca0012_3c) # NACA0012 p1c1 @@ -701,7 +701,7 @@ def main(): turb_naca0012_p1c1.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c1.cfg_file = "turb_NACA0012_uq_p1c1.cfg" turb_naca0012_p1c1.test_iter = 10 - turb_naca0012_p1c1.test_vals = [-5.120250, 1.074873, 0.294822, -0.109404] + turb_naca0012_p1c1.test_vals = [-5.120005, 1.075062, 0.291687, -0.104749] test_list.append(turb_naca0012_p1c1) # NACA0012 p1c2 @@ -709,7 +709,7 @@ def main(): turb_naca0012_p1c2.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c2.cfg_file = "turb_NACA0012_uq_p1c2.cfg" turb_naca0012_p1c2.test_iter = 10 - turb_naca0012_p1c2.test_vals = [-5.549132, 0.945671, 0.252360, -0.117501] + turb_naca0012_p1c2.test_vals = [-5.549133, 0.945821, 0.249565, -0.112728] test_list.append(turb_naca0012_p1c2) ###################################### @@ -769,7 +769,7 @@ def main(): square_cylinder.cfg_dir = "unsteady/square_cylinder" square_cylinder.cfg_file = "turb_square.cfg" square_cylinder.test_iter = 3 - square_cylinder.test_vals = [-2.560840, -1.173495, 0.061334, 1.399403, 2.220585, 1.399351, 2.218790, 0.000000] + square_cylinder.test_vals = [-2.560840, -1.176728, 0.061952, 1.399401, 2.220371, 1.399349, 2.218609, 0.000000] square_cylinder.unsteady = True test_list.append(square_cylinder) @@ -872,7 +872,7 @@ def main(): axial_stage2D.cfg_dir = "turbomachinery/axial_stage_2D" axial_stage2D.cfg_file = "Axial_stage2D.cfg" axial_stage2D.test_iter = 20 - axial_stage2D.test_vals = [0.987679, 1.532118, -2.888457, 2.606793, -2.418303, 3.087091, 106380.000000, 106380.000000, 5.732900, 64.728000] + axial_stage2D.test_vals = [1.108169, 1.561824, -2.895047, 2.607614, -2.479708, 3.063739, 106380.000000, 106380.000000, 5.733600, 64.747000] test_list.append(axial_stage2D) # 2D transonic stator restart @@ -972,7 +972,7 @@ def main(): bars_SST_2D.cfg_dir = "sliding_interface/bars_SST_2D" bars_SST_2D.cfg_file = "bars.cfg" bars_SST_2D.test_iter = 13 - bars_SST_2D.test_vals = [13.000000, -0.726398, -1.700012] + bars_SST_2D.test_vals = [13.000000, 0.268825, -1.700012] bars_SST_2D.multizone = True test_list.append(bars_SST_2D) @@ -1534,7 +1534,7 @@ def main(): pywrapper_square_cylinder.cfg_dir = "unsteady/square_cylinder" pywrapper_square_cylinder.cfg_file = "turb_square.cfg" pywrapper_square_cylinder.test_iter = 3 - pywrapper_square_cylinder.test_vals = [-2.560840, -1.173495, 0.061334, 1.399403, 2.220585, 1.399351, 2.218790, 0.000000] + pywrapper_square_cylinder.test_vals = [-2.560840, -1.176728, 0.061952, 1.399401, 2.220371, 1.399349, 2.218609, 0.000000] pywrapper_square_cylinder.command = TestCase.Command(exec = "SU2_CFD.py", param = "-f") pywrapper_square_cylinder.timeout = 1600 pywrapper_square_cylinder.tol = 0.00001 @@ -1577,7 +1577,7 @@ def main(): pywrapper_unsteadyCHT.cfg_dir = "py_wrapper/flatPlate_unsteady_CHT" pywrapper_unsteadyCHT.cfg_file = "unsteady_CHT_FlatPlate_Conf.cfg" pywrapper_unsteadyCHT.test_iter = 5 - pywrapper_unsteadyCHT.test_vals = [-1.614167, 2.240658, 0.000772, 0.177467] + pywrapper_unsteadyCHT.test_vals = [-1.614167, 2.246123, 0.000771, 0.172998] pywrapper_unsteadyCHT.command = TestCase.Command(exec = "python", param = "launch_unsteady_CHT_FlatPlate.py -f") pywrapper_unsteadyCHT.timeout = 1600 pywrapper_unsteadyCHT.tol = 0.00001 @@ -1591,7 +1591,7 @@ def main(): pywrapper_rigidMotion.cfg_dir = "py_wrapper/flatPlate_rigidMotion" pywrapper_rigidMotion.cfg_file = "flatPlate_rigidMotion_Conf.cfg" pywrapper_rigidMotion.test_iter = 5 - pywrapper_rigidMotion.test_vals = [-1.614165, 2.238592, 0.349984, 0.095593] + pywrapper_rigidMotion.test_vals = [-1.614165, 2.243155, 0.350210, 0.089497] pywrapper_rigidMotion.command = TestCase.Command(exec = "python", param = "launch_flatPlate_rigidMotion.py -f") pywrapper_rigidMotion.timeout = 1600 pywrapper_rigidMotion.tol = 0.00001 diff --git a/TestCases/tutorials.py b/TestCases/tutorials.py index d631eceef135..455a59630cda 100644 --- a/TestCases/tutorials.py +++ b/TestCases/tutorials.py @@ -144,7 +144,7 @@ def main(): kenics_mixer_tutorial.cfg_dir = "../Tutorials/incompressible_flow/Inc_Species_Transport_Composition_Dependent_Model" kenics_mixer_tutorial.cfg_file = "kenics_mixer_tutorial.cfg" kenics_mixer_tutorial.test_iter = 10 - kenics_mixer_tutorial.test_vals = [-7.490002, -6.823162, -6.837602, -5.156401, -7.928720, -3.089782, -7.447883, 5.000000, -1.863052, 4.000000, -5.174773, 3.000000, -6.382946, 0.025471, 0.000000, 0.025471, 0.000000, 64.126000, 8.479400, 48.120000, 7.526800] + kenics_mixer_tutorial.test_vals = [-7.490002, -6.823162, -6.837602, -5.156401, -7.928782, -3.089710, -7.447882, 5.000000, -1.863053, 4.000000, -5.174845, 3.000000, -6.382936, 0.025471, 0.000000, 0.025471, 0.000000, 64.126000, 8.479400, 48.120000, 7.526800] kenics_mixer_tutorial.command = TestCase.Command("mpirun -n 2", "SU2_CFD") test_list.append(kenics_mixer_tutorial) @@ -274,7 +274,7 @@ def main(): tutorial_nicfd_nozzle.cfg_dir = "../Tutorials/compressible_flow/NICFD_nozzle" tutorial_nicfd_nozzle.cfg_file = "NICFD_nozzle.cfg" tutorial_nicfd_nozzle.test_iter = 20 - tutorial_nicfd_nozzle.test_vals = [-2.056675, -2.124123, 3.687857, 0.000000, 0.000000] + tutorial_nicfd_nozzle.test_vals = [-2.056675, -2.124123, 3.687776, 0.000000, 0.000000] tutorial_nicfd_nozzle.no_restart = True test_list.append(tutorial_nicfd_nozzle) @@ -345,7 +345,7 @@ def main(): pass_list = [ test.run_test() for test in test_list ] - # design-FADO: 90 degree pipe bend optimization + # design-FADO: 90 degree pipe bend optimization sudo_design_fado = TestCase('sudo_bend_design_fado') sudo_design_fado.command = TestCase.Command(exec = "python", param = "optimization.py") sudo_design_fado.cfg_dir = "../Tutorials/design/Inc_Turbulent_Bend_Wallfunctions" From 42f80f304b295a2bfa8e519408abc6006f3efcee Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sat, 1 Mar 2025 19:29:36 +0000 Subject: [PATCH 41/49] use new cases branch --- .github/workflows/regression.yml | 6 +++--- TestCases/vandv/rans/swbli/config_sst.cfg | 16 ++++++++-------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/regression.yml b/.github/workflows/regression.yml index 2502204b64c4..77eff8979eb2 100644 --- a/.github/workflows/regression.yml +++ b/.github/workflows/regression.yml @@ -209,7 +209,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} + args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: @@ -255,7 +255,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--tsan" + args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} -a "--tsan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: @@ -300,7 +300,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--asan" + args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} -a "--asan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: diff --git a/TestCases/vandv/rans/swbli/config_sst.cfg b/TestCases/vandv/rans/swbli/config_sst.cfg index efd2de113508..42d3684879fc 100644 --- a/TestCases/vandv/rans/swbli/config_sst.cfg +++ b/TestCases/vandv/rans/swbli/config_sst.cfg @@ -4,7 +4,7 @@ % SOLVER= RANS KIND_TURB_MODEL= SST -SST_OPTIONS= V2003m +SST_OPTIONS= V2003m, COMPRESSIBILITY-WILCOX REF_DIMENSIONALIZATION= FREESTREAM_VEL_EQ_MACH % % ----------------------------- FREESTREAM ------------------------------ % @@ -68,23 +68,23 @@ MUSCL_TURB= NO TIME_DISCRE_FLOW= EULER_IMPLICIT TIME_DISCRE_TURB= EULER_IMPLICIT % -CFL_NUMBER= 1 +CFL_NUMBER= 10 CFL_REDUCTION_TURB= 1 -CFL_ADAPT= YES +CFL_ADAPT= NO CFL_ADAPT_PARAM= ( 1.0, 1.05, 1, 50, 0.8 ) % LINEAR_SOLVER= FGMRES LINEAR_SOLVER_PREC= ILU -LINEAR_SOLVER_ERROR= 0.1 -LINEAR_SOLVER_ITER= 10 +LINEAR_SOLVER_ERROR= 0.01 +LINEAR_SOLVER_ITER= 3 % -NEWTON_KRYLOV= YES -NEWTON_KRYLOV_IPARAM= ( 0, 3, 1 ) % n0, np, ft +NEWTON_KRYLOV= NO +NEWTON_KRYLOV_IPARAM= ( 0, 0, 1 ) % n0, np, ft NEWTON_KRYLOV_DPARAM= ( 0.0, 1e-20, -3, 1e-5 ) % r0, tp, rf, e % % ------------------------ CONVERGENCE CRITERIA ------------------------- % % -ITER= 2000 +ITER= 20000 CONV_RESIDUAL_MINVAL= -11.5 % % --------------------------- INPUT / OUTPUT ---------------------------- % From e7d17f60f8c22dba761f68773a0344ad856d70ea Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sat, 1 Mar 2025 21:30:11 +0000 Subject: [PATCH 42/49] update --- TestCases/vandv.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/TestCases/vandv.py b/TestCases/vandv.py index ba3fb0dde688..e677146972f9 100644 --- a/TestCases/vandv.py +++ b/TestCases/vandv.py @@ -54,8 +54,8 @@ def main(): flatplate_sst1994m.cfg_dir = "vandv/rans/flatplate" flatplate_sst1994m.cfg_file = "turb_flatplate_sst.cfg" flatplate_sst1994m.test_iter = 5 - flatplate_sst1994m.test_vals = [-13.045864, -10.962894, -11.543805, -8.355270, -11.200467, -5.084711, 0.002786] - flatplate_sst1994m.test_vals_aarch64 = [-13.045864, -10.962894, -11.543805, -8.355270, -11.200467, -5.084711, 0.002786] + flatplate_sst1994m.test_vals = [-13.026348, -9.634516, -10.706546, -7.560399, -9.926923, -5.237330, 0.002786] + flatplate_sst1994m.test_vals_aarch64 = [-13.026348, -9.634516, -10.706546, -7.560399, -9.926923, -5.237330, 0.002786] test_list.append(flatplate_sst1994m) # bump in channel - sst-v1994m @@ -63,8 +63,8 @@ def main(): bump_sst1994m.cfg_dir = "vandv/rans/bump_in_channel" bump_sst1994m.cfg_file = "turb_bump_sst.cfg" bump_sst1994m.test_iter = 5 - bump_sst1994m.test_vals = [-5.472393, -2.651543, -2.741047, 0.023512, -1.997863, 15.897007, 0.004899] - bump_sst1994m.test_vals_aarch64 = [-13.000658, -10.449108, -10.585058, -7.531737, -10.468414, -5.695067, 0.004904] + bump_sst1994m.test_vals = [-12.986997, -10.675928, -10.587885, -7.593707, -10.992547, -1.011790, 0.004900] + bump_sst1994m.test_vals_aarch64 = [-12.986997, -10.675928, -10.587885, -7.593707, -10.992547, -1.011790, 0.004900] test_list.append(bump_sst1994m) # SWBLI SA @@ -82,7 +82,7 @@ def main(): swbli_sst.cfg_dir = "vandv/rans/swbli" swbli_sst.cfg_file = "config_sst.cfg" swbli_sst.test_iter = 5 - swbli_sst.test_vals = [-11.500317, -10.752421, -11.508502, -10.331672, -10.300258, 1.562476, 0.002280, -1.324977, -6.297644, 1.000000] + swbli_sst.test_vals = [-11.502406, -10.850464, -11.572206, -10.370605, -11.405558, -4.349068, 0.001794, -1.450380, -3.681252, 10.000000] test_list.append(swbli_sst) ########################## From 5c78bc807cbbaa0932e9497a919d78e42539f8c2 Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sat, 1 Mar 2025 22:55:44 +0000 Subject: [PATCH 43/49] updates --- .github/workflows/regression.yml | 6 +++--- TestCases/vandv.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/regression.yml b/.github/workflows/regression.yml index 77eff8979eb2..59cb44fd8cd0 100644 --- a/.github/workflows/regression.yml +++ b/.github/workflows/regression.yml @@ -209,7 +209,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} + args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: @@ -255,7 +255,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} -a "--tsan" + args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} -a "--tsan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: @@ -300,7 +300,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t develop -c corner_node -s ${{matrix.testscript}} -a "--asan" + args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} -a "--asan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: diff --git a/TestCases/vandv.py b/TestCases/vandv.py index e677146972f9..4be2db6e5aad 100644 --- a/TestCases/vandv.py +++ b/TestCases/vandv.py @@ -94,7 +94,7 @@ def main(): sandiajet_sst.cfg_dir = "vandv/species_transport/sandia_jet" sandiajet_sst.cfg_file = "validation.cfg" sandiajet_sst.test_iter = 5 - sandiajet_sst.test_vals = [-8.502793, -6.169258, -6.699764, -5.115200, 1.068905, -8.492912, 5.000000, -1.727355, 5.000000, -5.233912, 5.000000, -1.959627, 0.000259, 0.000000, 0.000000, 0.000259, 4047.400000, 3946.800000, 49.161000, 51.433000] + sandiajet_sst.test_vals = [-17.198747, -14.117051, -15.599971, -14.054169, -10.364040, -15.739739, 5.000000, -3.100725, 5.000000, -5.353629, 5.000000, -4.200029, 0.000258, 0.000000, 0.000000, 0.000258, 4019.500000, 3918.900000, 49.151000, 51.436000] sandiajet_sst.test_vals_aarch64 = [-17.069026, -13.156800, -15.290567, -11.689831, -9.349978, -14.907311, 5.000000, -2.738947, 5.000000, -4.813747, 5.000000, -3.981740, 0.000259, 0.000000, 0.000000, 0.000259, 4047.400000, 3946.800000, 49.161000, 51.433000] test_list.append(sandiajet_sst) From aa7209ac97458fde7653bf202e20aad7f01e0828 Mon Sep 17 00:00:00 2001 From: Pedro Gomes Date: Sun, 2 Mar 2025 10:05:24 +0000 Subject: [PATCH 44/49] updates --- .../optim.csv.ref | 2 +- TestCases/hybrid_regression.py | 20 ++++++------ TestCases/hybrid_regression_AD.py | 4 +-- TestCases/parallel_regression.py | 32 +++++++++---------- TestCases/parallel_regression_AD.py | 14 ++++---- TestCases/serial_regression.py | 30 ++++++++--------- TestCases/serial_regression_AD.py | 2 +- TestCases/tutorials.py | 6 ++-- 8 files changed, 55 insertions(+), 55 deletions(-) diff --git a/TestCases/Tutorials/design/Inc_Turbulent_Bend_Wallfunctions/optim.csv.ref b/TestCases/Tutorials/design/Inc_Turbulent_Bend_Wallfunctions/optim.csv.ref index 2f0fb6fc2974..fb3d04a9bb49 100644 --- a/TestCases/Tutorials/design/Inc_Turbulent_Bend_Wallfunctions/optim.csv.ref +++ b/TestCases/Tutorials/design/Inc_Turbulent_Bend_Wallfunctions/optim.csv.ref @@ -1,2 +1,2 @@ ITER, avg_dp -1, 89.03358290403737 +1, 63.82289754521027 diff --git a/TestCases/hybrid_regression.py b/TestCases/hybrid_regression.py index b3b489bcd81e..318ba0bdf2f2 100644 --- a/TestCases/hybrid_regression.py +++ b/TestCases/hybrid_regression.py @@ -206,7 +206,7 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-8.493861, -10.747240, -4.507971, 1.047913, 0.019156, -1.585577, 0.000000] + turb_naca0012_sst.test_vals = [-12.232701, -14.434762, -6.411172, 1.047444, 0.019214, -1.652128, 0] test_list.append(turb_naca0012_sst) # NACA0012 (SST_SUST, FUN3D finest grid results: CL=1.0840, CD=0.01253) @@ -214,7 +214,7 @@ def main(): turb_naca0012_sst_sust.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust.test_iter = 10 - turb_naca0012_sst_sust.test_vals = [-7.985914, -10.322645, -3.314244, 0.995006, 0.019294, -1.538068] + turb_naca0012_sst_sust.test_vals = [-12.152274, -14.781420, -6.725224, 1.000270, 0.019123, -1.417716] test_list.append(turb_naca0012_sst_sust) # NACA0012 (SST, fixed values for turbulence quantities) @@ -222,7 +222,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.192503, -10.035788, -1.617649, 1.022030, 0.040310, -2.381936] + turb_naca0012_sst_fixedvalues.test_vals = [-5.192403, -10.256922, -1.568131, 1.022561, 0.040530, -2.382766] test_list.append(turb_naca0012_sst_fixedvalues) # NACA0012 (SST, explicit Euler for flow and turbulence equations) @@ -250,7 +250,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-6.046200, -0.482494, -2.228367, 2.466115, 0.000000] + axi_rans_air_nozzle_restart.test_vals = [-12.065478, -6.838586, -8.839400, -4.103176, 0] test_list.append(axi_rans_air_nozzle_restart) ################################# @@ -263,7 +263,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 20 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.644626, -7.427011, -0.631753, -0.000007, 0.079118] + turb_naca0012_sst_restart_mg.test_vals = [-7.633090, -7.182014, -0.627166, -0.000020, 0.078737] test_list.append(turb_naca0012_sst_restart_mg) ############################# @@ -311,8 +311,8 @@ def main(): turb_naca0012_p1c2.cfg_dir = "rans_uq/naca0012" turb_naca0012_p1c2.cfg_file = "turb_NACA0012_uq_p1c2.cfg" turb_naca0012_p1c2.test_iter = 10 - turb_naca0012_p1c2.test_vals = [-5.548780, 0.945778, 0.213968, -0.126040] - turb_naca0012_p1c2.test_vals_aarch64 = [-5.554425, 0.943683, 0.229293, -0.121125] + turb_naca0012_p1c2.test_vals = [-5.548775, 0.945962, 0.211150, -0.121291] + turb_naca0012_p1c2.test_vals_aarch64 = [-5.548775, 0.945962, 0.211150, -0.121291] test_list.append(turb_naca0012_p1c2) ###################################### @@ -556,7 +556,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-3.501035, -0.855391, -11.767172, -6.117423, -9.432832, -3.573397, 73273.000000, 73273.000000, 0.019884, 82.491000] + Jones_tc_restart.test_vals = [-7.286677, -5.327018, -14.895652, -9.330534, -12.071733, -6.548623, 73291.000000, 73291.000000, 0.020111, 82.896000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -573,8 +573,8 @@ def main(): transonic_stator_restart.cfg_dir = "turbomachinery/transonic_stator_2D" transonic_stator_restart.cfg_file = "transonic_stator_restart.cfg" transonic_stator_restart.test_iter = 20 - transonic_stator_restart.test_vals = [-5.007735, -3.099310, -2.751696, 1.091966, -3.542819, 2.163237, -471630.000000, 94.866000, -0.035738] - transonic_stator_restart.test_vals_aarch64 = [-5.007735, -3.099310, -2.751696, 1.091966, -3.542819, 2.163237, -471630, 94.866, -0.035738] + transonic_stator_restart.test_vals = [-4.357748, -2.480402, -2.075152, 1.737469, -1.440919, 2.727299, -471620.000000, 94.840000, -0.054603] + transonic_stator_restart.test_vals_aarch64 = [-4.357748, -2.480402, -2.075152, 1.737469, -1.440919, 2.727299, -471620.000000, 94.840000, -0.054603] test_list.append(transonic_stator_restart) # Multiple turbomachinery interface restart diff --git a/TestCases/hybrid_regression_AD.py b/TestCases/hybrid_regression_AD.py index 1abcbcc9e87d..f0eebcb6b96d 100644 --- a/TestCases/hybrid_regression_AD.py +++ b/TestCases/hybrid_regression_AD.py @@ -86,7 +86,7 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.234037, -0.198500, 2.769200, -0.039720] + discadj_rans_naca0012_sst.test_vals = [-2.237494, -0.200182, 2.762600, -0.039607] test_list.append(discadj_rans_naca0012_sst) ####################################### @@ -131,7 +131,7 @@ def main(): discadj_incomp_turb_NACA0012_sst.cfg_dir = "disc_adj_incomp_rans/naca0012" discadj_incomp_turb_NACA0012_sst.cfg_file = "turb_naca0012_sst.cfg" discadj_incomp_turb_NACA0012_sst.test_iter = 10 - discadj_incomp_turb_NACA0012_sst.test_vals = [-4.029282, -2.181911, -7.734686, 0.000000, -0.939944] + discadj_incomp_turb_NACA0012_sst.test_vals = [-3.597708, -2.983823, -8.354806, 0.000000, -0.916525] test_list.append(discadj_incomp_turb_NACA0012_sst) ####################################################### diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index ba81770d5d70..d3e7eb0fe5af 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -450,8 +450,8 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-8.515393, -10.746513, -4.384035, 1.047851, 0.019161, -1.928467, 0.000000] - turb_naca0012_sst.test_vals_aarch64 = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] + turb_naca0012_sst.test_vals = [-12.232533, -14.435252, -6.410718, 1.047444, 0.019214, -1.704292, 0.000000] + turb_naca0012_sst.test_vals_aarch64 = [-12.232533, -14.435252, -6.410718, 1.047444, 0.019214, -1.704292, 0.000000] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -460,8 +460,8 @@ def main(): turb_naca0012_sst_sust.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust.test_iter = 10 - turb_naca0012_sst_sust.test_vals = [-8.040159, -10.043114, -3.511447, 0.997716, 0.019035, -1.409880] - turb_naca0012_sst_sust.test_vals_aarch64 = [-12.087234, -14.827336, -6.062338, 1.000276, 0.019495, -1.779654] + turb_naca0012_sst_sust.test_vals = [-12.146206, -14.781894, -6.726031, 1.000270, 0.019123, -1.593340] + turb_naca0012_sst_sust.test_vals_aarch64 = [-12.146206, -14.781894, -6.726031, 1.000270, 0.019123, -1.593340] turb_naca0012_sst_sust.timeout = 3200 test_list.append(turb_naca0012_sst_sust) @@ -470,7 +470,7 @@ def main(): turb_naca0012_sst_2003_Vm.cfg_dir = "rans/naca0012" turb_naca0012_sst_2003_Vm.cfg_file = "turb_NACA0012_sst_2003-Vm.cfg" turb_naca0012_sst_2003_Vm.test_iter = 10 - turb_naca0012_sst_2003_Vm.test_vals = [-8.123539, -10.281917, -3.540665, 1.045725, 0.019271, -1.656078] + turb_naca0012_sst_2003_Vm.test_vals = [-8.263497, -10.306865, -3.563758, 1.045289, 0.019325, -1.551944] turb_naca0012_sst_2003_Vm.timeout = 3200 test_list.append(turb_naca0012_sst_2003_Vm) @@ -479,7 +479,7 @@ def main(): turb_naca0012_sst_1994_KLm.cfg_dir = "rans/naca0012" turb_naca0012_sst_1994_KLm.cfg_file = "turb_NACA0012_sst_1994-KLm.cfg" turb_naca0012_sst_1994_KLm.test_iter = 10 - turb_naca0012_sst_1994_KLm.test_vals = [-8.334419, -10.630544, -3.917441, 1.047157, 0.019197, -1.877042] + turb_naca0012_sst_1994_KLm.test_vals = [-8.563644, -10.803387, -3.994584, 1.046738, 0.019251, -1.806540] turb_naca0012_sst_1994_KLm.timeout = 3200 test_list.append(turb_naca0012_sst_1994_KLm) @@ -530,7 +530,7 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-5.503924, 0.122159, -1.251673, 3.349405, 0.000000] + axi_rans_air_nozzle_restart.test_vals = [-12.067082, -6.839065, -8.740217, -4.045574, 0.000000] axi_rans_air_nozzle_restart.tol = 0.0001 test_list.append(axi_rans_air_nozzle_restart) @@ -1086,7 +1086,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-3.501027, -0.855390, -11.767169, -6.117420, -9.432832, -3.573397, 73273.000000, 73273.000000, 0.019884, 82.491000] + Jones_tc_restart.test_vals = [-7.286677, -5.327030, -14.895645, -9.330524, -12.071730, -6.548621, 73291.000000, 73291.000000, 0.020111, 82.896000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -1102,7 +1102,7 @@ def main(): transonic_stator_restart.cfg_dir = "turbomachinery/transonic_stator_2D" transonic_stator_restart.cfg_file = "transonic_stator_restart.cfg" transonic_stator_restart.test_iter = 20 - transonic_stator_restart.test_vals = [-5.011834, -3.091110, -2.757795, 1.087934, -3.544707, 2.166101, -471630, 94.868, -0.035888] + transonic_stator_restart.test_vals = [-4.354904, -2.473465, -2.076229, 1.740407, -1.440833, 2.730785, -471620.000000, 94.839000, -0.050270] transonic_stator_restart.test_vals_aarch64 = [-5.011834, -3.091110, -2.757795, 1.087934, -3.544707, 2.166101, -471630, 94.868, -0.035888] test_list.append(transonic_stator_restart) @@ -1370,8 +1370,8 @@ def main(): pywrapper_turb_naca0012_sst.cfg_dir = "rans/naca0012" pywrapper_turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" pywrapper_turb_naca0012_sst.test_iter = 10 - pywrapper_turb_naca0012_sst.test_vals = [-8.515763, -10.746560, -4.508015, 1.047852, 0.019161, -1.928310, 0.000000] - pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.107692, -15.277743, -6.210238, 1.049757, 0.019249, -2.357984, 0] + pywrapper_turb_naca0012_sst.test_vals = [-12.232533, -14.435252, -6.410718, 1.047444, 0.019214, -1.704292, 0] + pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.232533, -14.435252, -6.410718, 1.047444, 0.019214, -1.704292, 0] pywrapper_turb_naca0012_sst.command = TestCase.Command("mpirun -np 2", "SU2_CFD.py", "--parallel -f") pywrapper_turb_naca0012_sst.timeout = 3200 test_list.append(pywrapper_turb_naca0012_sst) @@ -1565,7 +1565,7 @@ def main(): species2_primitiveVenturi.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi.cfg_file = "species2_primitiveVenturi.cfg" species2_primitiveVenturi.test_iter = 50 - species2_primitiveVenturi.test_vals = [-5.643794, -4.798953, -4.858719, -5.648947, -1.195985, -5.564607, 5.000000, -0.958960, 5.000000, -2.515334, 5.000000, -0.796944, 0.000210, 0.000206, 0.000004, 0.000000] + species2_primitiveVenturi.test_vals = [-5.383507, -4.591042, -4.618659, -5.371315, -1.048003, -5.321849, 5.000000, -1.011668, 5.000000, -2.540380, 5.000000, -1.220744, 0.000035, 0.000035, 0.000000, 0.000000] test_list.append(species2_primitiveVenturi) # 2 species (1 eq) primitive venturi mixing with bounded scalar transport @@ -1573,7 +1573,7 @@ def main(): species_primitiveVenturi_boundedscalar.cfg_dir = "species_transport/venturi_primitive_3species" species_primitiveVenturi_boundedscalar.cfg_file = "species2_primitiveVenturi_boundedscalar.cfg" species_primitiveVenturi_boundedscalar.test_iter = 50 - species_primitiveVenturi_boundedscalar.test_vals = [-5.283533, -4.417193, -4.478360, -5.669526, -0.952767, -5.618596, 5.000000, -1.996975, 5.000000, -4.017868, 5.000000, -1.747496, 0.000423, 0.000423, 0.000000, 0.000000] + species_primitiveVenturi_boundedscalar.test_vals = [-5.273416, -4.372370, -4.440933, -5.944335, -0.961736, -5.609422, 5.000000, -2.024352, 5.000000, -4.092737, 5.000000, -1.811021, 0.000423, 0.000423, 0.000000, 0.000000] test_list.append(species_primitiveVenturi_boundedscalar) # 2 species (1 eq) primitive venturi mixing using mixing model including inlet markers for turbulent intensity and viscosity ratios @@ -1581,7 +1581,7 @@ def main(): species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.cfg_dir = "species_transport/venturi_primitive_3species" species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.cfg_file = "species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.cfg" species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.test_iter = 50 - species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.test_vals = [-4.105910, -1.680056, -1.599493, -0.672401, 1.441091, -3.759601, 23.000000, -5.201473, 11.000000, -5.312651, 4.000000, -6.525448, 2.000000, 1.000000, 0.000000, 1.000000] + species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS.test_vals = [-4.047742, -1.641280, -1.562848, -0.984640, 1.499898, -3.745901, 23.000000, -5.208811, 12.000000, -5.399205, 3.000000, -5.230072, 2.000000, 1.000000, 0.000000, 1.000000] test_list.append(species2_primitiveVenturi_mixingmodel_TURBULENT_MARKERS) # 3 species (2 eq) primitive venturi mixing with inlet files. @@ -1590,7 +1590,7 @@ def main(): species3_primitiveVenturi_inletFile.cfg_dir = "species_transport/venturi_primitive_3species" species3_primitiveVenturi_inletFile.cfg_file = "species3_primitiveVenturi_inletFile.cfg" species3_primitiveVenturi_inletFile.test_iter = 50 - species3_primitiveVenturi_inletFile.test_vals = [-5.714428, -4.869589, -4.929349, -5.719577, -1.266622, -5.824037, -5.944720, 5.000000, -0.958918, 5.000000, -2.515337, 5.000000, -0.523677] + species3_primitiveVenturi_inletFile.test_vals = [-5.454137, -4.661671, -4.689288, -5.441944, -1.118632, -5.592455, -5.735073, 5.000000, -1.011667, 5.000000, -2.540380, 5.000000, -1.040187] test_list.append(species3_primitiveVenturi_inletFile) # rectangle passive transport validation @@ -1620,7 +1620,7 @@ def main(): cgns_writer.cfg_dir = "cgns_writer" cgns_writer.cfg_file = "config.cfg" cgns_writer.test_iter = 1 - cgns_writer.test_vals = [-2.974473, 0.665204, 5.068846, -7.003873] + cgns_writer.test_vals = [-2.974473, 0.640256, 5.371029, -6.732060] cgns_writer.command = TestCase.Command("mpirun -n 2", "SU2_CFD") cgns_writer.new_output = True test_list.append(cgns_writer) diff --git a/TestCases/parallel_regression_AD.py b/TestCases/parallel_regression_AD.py index 5366959a50a2..c7eb4ee04b7c 100644 --- a/TestCases/parallel_regression_AD.py +++ b/TestCases/parallel_regression_AD.py @@ -91,8 +91,8 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.274814, -0.278441, -2.250500, -0.003160] - discadj_rans_naca0012_sst.test_vals_aarch64 = [-2.274779, -0.278440, -2.255500, -0.003160] + discadj_rans_naca0012_sst.test_vals = [-2.265084, -0.280000, -2.268000, -0.002968] + discadj_rans_naca0012_sst.test_vals_aarch64 = [-2.265084, -0.280000, -2.268000, -0.002968] test_list.append(discadj_rans_naca0012_sst) ####################################### @@ -137,8 +137,8 @@ def main(): discadj_incomp_turb_NACA0012_sst.cfg_dir = "disc_adj_incomp_rans/naca0012" discadj_incomp_turb_NACA0012_sst.cfg_file = "turb_naca0012_sst.cfg" discadj_incomp_turb_NACA0012_sst.test_iter = 10 - discadj_incomp_turb_NACA0012_sst.test_vals = [-4.183391, -2.287284, -7.892044, 0, -1.230919] - discadj_incomp_turb_NACA0012_sst.test_vals_aarch64 = [-4.183391, -2.287284, -7.892044, 0, -1.230919] + discadj_incomp_turb_NACA0012_sst.test_vals = [-3.944706, -2.788179, -7.913889, 0.000000, -0.956513] + discadj_incomp_turb_NACA0012_sst.test_vals_aarch64 = [-3.944706, -2.788179, -7.913889, 0.000000, -0.956513] test_list.append(discadj_incomp_turb_NACA0012_sst) #################################################################### @@ -150,7 +150,7 @@ def main(): discadj_axisymmetric_rans_nozzle.cfg_dir = "axisymmetric_rans/air_nozzle" discadj_axisymmetric_rans_nozzle.cfg_file = "air_nozzle_restart.cfg" discadj_axisymmetric_rans_nozzle.test_iter = 10 - discadj_axisymmetric_rans_nozzle.test_vals = [9.550294, 4.938499, 7.387346, 2.733061] + discadj_axisymmetric_rans_nozzle.test_vals = [9.554393, 4.939337, 7.053413, 2.476067] discadj_axisymmetric_rans_nozzle.no_restart = True test_list.append(discadj_axisymmetric_rans_nozzle) @@ -299,7 +299,7 @@ def main(): da_sp_pinArray_cht_2d_dp_hf.cfg_dir = "incomp_navierstokes/streamwise_periodic/chtPinArray_2d" da_sp_pinArray_cht_2d_dp_hf.cfg_file = "DA_configMaster.cfg" da_sp_pinArray_cht_2d_dp_hf.test_iter = 100 - da_sp_pinArray_cht_2d_dp_hf.test_vals = [-4.706292, -4.062398, -4.137374] + da_sp_pinArray_cht_2d_dp_hf.test_vals = [-4.703416, -4.061963, -4.136826] da_sp_pinArray_cht_2d_dp_hf.multizone = True test_list.append(da_sp_pinArray_cht_2d_dp_hf) @@ -308,7 +308,7 @@ def main(): da_sp_pinArray_cht_2d_mf.cfg_dir = "incomp_navierstokes/streamwise_periodic/dp-adjoint_chtPinArray_2d" da_sp_pinArray_cht_2d_mf.cfg_file = "configMaster.cfg" da_sp_pinArray_cht_2d_mf.test_iter = 100 - da_sp_pinArray_cht_2d_mf.test_vals = [-4.600710, -1.298285, -1.430286, -18.503417, -0.870017, -5.768271, -19.069555, -47.953298] + da_sp_pinArray_cht_2d_mf.test_vals = [-4.508582, -1.198591, -1.394041, -18.498530, -0.810948, -6.006116, -19.074586, -49.841067] da_sp_pinArray_cht_2d_mf.multizone = True test_list.append(da_sp_pinArray_cht_2d_mf) diff --git a/TestCases/serial_regression.py b/TestCases/serial_regression.py index d602c921635a..67325c873f99 100644 --- a/TestCases/serial_regression.py +++ b/TestCases/serial_regression.py @@ -284,8 +284,8 @@ def main(): turb_naca0012_sst.cfg_dir = "rans/naca0012" turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" turb_naca0012_sst.test_iter = 10 - turb_naca0012_sst.test_vals = [-8.507252, -10.746596, -4.388968, 1.047904, 0.019158, -1.724811, 0.000000] - turb_naca0012_sst.test_vals_aarch64 = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] + turb_naca0012_sst.test_vals = [-12.229890, -14.434837, -6.410709, 1.047444, 0.019214, -2.107944, 0.000000] + turb_naca0012_sst.test_vals_aarch64 = [-12.229890, -14.434837, -6.410709, 1.047444, 0.019214, -2.107944, 0.000000] turb_naca0012_sst.timeout = 3200 test_list.append(turb_naca0012_sst) @@ -294,7 +294,7 @@ def main(): turb_naca0012_sst_2003m.cfg_dir = "rans/naca0012" turb_naca0012_sst_2003m.cfg_file = "turb_NACA0012_sst_2003m.cfg" turb_naca0012_sst_2003m.test_iter = 10 - turb_naca0012_sst_2003m.test_vals = [-7.660511, -10.053600, -3.394775, 1.046880, 0.019689, -2.170311, 0.000000] + turb_naca0012_sst_2003m.test_vals = [-8.617054, -10.719389, -3.976617, 1.046417, 0.019227, -1.708430, 0.000000] turb_naca0012_sst_2003m.timeout = 3200 test_list.append(turb_naca0012_sst_2003m) @@ -303,8 +303,8 @@ def main(): turb_naca0012_sst_sust_restart.cfg_dir = "rans/naca0012" turb_naca0012_sst_sust_restart.cfg_file = "turb_NACA0012_sst_sust.cfg" turb_naca0012_sst_sust_restart.test_iter = 10 - turb_naca0012_sst_sust_restart.test_vals = [-7.998513, -10.320508, -3.314994, 0.994965, 0.019301, -1.821039] - turb_naca0012_sst_sust_restart.test_vals_aarch64 = [-12.084326, -14.827365, -6.062398, 1.000276, 0.019495, -2.201517] + turb_naca0012_sst_sust_restart.test_vals = [-12.157374, -14.782027, -6.726462, 1.000270, 0.019123, -1.780624] + turb_naca0012_sst_sust_restart.test_vals_aarch64 = [-12.157374, -14.782027, -6.726462, 1.000270, 0.019123, -1.780624] turb_naca0012_sst_sust_restart.timeout = 3200 test_list.append(turb_naca0012_sst_sust_restart) @@ -313,7 +313,7 @@ def main(): turb_naca0012_sst_fixedvalues.cfg_dir = "rans/naca0012" turb_naca0012_sst_fixedvalues.cfg_file = "turb_NACA0012_sst_fixedvalues.cfg" turb_naca0012_sst_fixedvalues.test_iter = 10 - turb_naca0012_sst_fixedvalues.test_vals = [-5.206693, -10.016853, -1.615987, 1.021480, 0.040333, -3.478131] + turb_naca0012_sst_fixedvalues.test_vals = [-5.206634, -10.239842, -1.566346, 1.022023, 0.040554, -3.477742] turb_naca0012_sst_fixedvalues.timeout = 3200 test_list.append(turb_naca0012_sst_fixedvalues) @@ -335,8 +335,8 @@ def main(): axi_rans_air_nozzle_restart.cfg_dir = "axisymmetric_rans/air_nozzle" axi_rans_air_nozzle_restart.cfg_file = "air_nozzle_restart.cfg" axi_rans_air_nozzle_restart.test_iter = 10 - axi_rans_air_nozzle_restart.test_vals = [-6.046478, -0.483139, -2.216327, 2.472194, 0.000000] - axi_rans_air_nozzle_restart.test_vals_aarch64 = [-12.071702, -7.474599, -8.646498, -3.988633, 0] + axi_rans_air_nozzle_restart.test_vals = [-12.066971, -6.841755, -8.747510, -4.048582, 0.000000] + axi_rans_air_nozzle_restart.test_vals_aarch64 = [-12.066971, -6.841755, -8.747510, -4.048582, 0.000000] axi_rans_air_nozzle_restart.tol = 0.0001 test_list.append(axi_rans_air_nozzle_restart) @@ -350,7 +350,7 @@ def main(): turb_naca0012_sst_restart_mg.cfg_file = "turb_NACA0012_sst_multigrid_restart.cfg" turb_naca0012_sst_restart_mg.test_iter = 50 turb_naca0012_sst_restart_mg.ntest_vals = 5 - turb_naca0012_sst_restart_mg.test_vals = [-7.639663, -7.464724, -1.665498, -0.000022, 0.079196] + turb_naca0012_sst_restart_mg.test_vals = [-7.645511, -7.268262, -1.665682, -0.000027, 0.078643] turb_naca0012_sst_restart_mg.timeout = 3200 turb_naca0012_sst_restart_mg.tol = 0.000001 test_list.append(turb_naca0012_sst_restart_mg) @@ -449,7 +449,7 @@ def main(): inc_turb_naca0012_sst_sust.cfg_dir = "incomp_rans/naca0012" inc_turb_naca0012_sst_sust.cfg_file = "naca0012_SST_SUST.cfg" inc_turb_naca0012_sst_sust.test_iter = 20 - inc_turb_naca0012_sst_sust.test_vals = [-7.316735, 0.018271, 0.000021, 0.307672] + inc_turb_naca0012_sst_sust.test_vals = [-7.291334, 0.132662, 0.000021, 0.312093] test_list.append(inc_turb_naca0012_sst_sust) # FLAT PLATE, WALL FUNCTIONS, INCOMPRESSIBLE SST @@ -864,7 +864,7 @@ def main(): Jones_tc_restart.cfg_dir = "turbomachinery/APU_turbocharger" Jones_tc_restart.cfg_file = "Jones_restart.cfg" Jones_tc_restart.test_iter = 5 - Jones_tc_restart.test_vals = [-3.501033, -0.855390, -11.767195, -6.117445, -9.432838, -3.573401, 73273.000000, 73273.000000, 0.019884, 82.491000] + Jones_tc_restart.test_vals = [-7.286680, -5.327029, -14.895646, -9.330526, -12.071730, -6.548621, 73291.000000, 73291.000000, 0.020111, 82.896000] test_list.append(Jones_tc_restart) # 2D axial stage @@ -880,8 +880,8 @@ def main(): transonic_stator_restart.cfg_dir = "turbomachinery/transonic_stator_2D" transonic_stator_restart.cfg_file = "transonic_stator_restart.cfg" transonic_stator_restart.test_iter = 20 - transonic_stator_restart.test_vals = [-5.008547, -3.102420, -2.752033, 1.091152, -3.543849, 2.169844, -471630.000000, 94.866000, -0.035806] - transonic_stator_restart.test_vals_aarch64 = [-5.008547, -3.102420, -2.752033, 1.091152, -3.543849, 2.169844, -471630, 94.866, -0.035806] + transonic_stator_restart.test_vals = [-4.359318, -2.486927, -2.079507, 1.735899, -1.442225, 2.732961, -471620, 94.840000, -0.055455] + transonic_stator_restart.test_vals_aarch64 = [-4.359318, -2.486927, -2.079507, 1.735899, -1.442225, 2.732961, -471620, 94.840000, -0.055455] test_list.append(transonic_stator_restart) # Multiple turbomachinery interface restart @@ -1520,8 +1520,8 @@ def main(): pywrapper_turb_naca0012_sst.cfg_dir = "rans/naca0012" pywrapper_turb_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" pywrapper_turb_naca0012_sst.test_iter = 10 - pywrapper_turb_naca0012_sst.test_vals = [-8.507630, -10.746643, -4.514387, 1.047906, 0.019158, -1.724758, 0.000000] - pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.107132, -15.277740, -6.210248, 1.049757, 0.019249, -3.173936, 0] + pywrapper_turb_naca0012_sst.test_vals = [-12.229890, -14.434837, -6.410709, 1.047444, 0.019214, -2.107944, 0] + pywrapper_turb_naca0012_sst.test_vals_aarch64 = [-12.229890, -14.434837, -6.410709, 1.047444, 0.019214, -2.107944, 0] pywrapper_turb_naca0012_sst.command = TestCase.Command(exec = "SU2_CFD.py", param = "-f") pywrapper_turb_naca0012_sst.timeout = 3200 pywrapper_turb_naca0012_sst.tol = 0.00001 diff --git a/TestCases/serial_regression_AD.py b/TestCases/serial_regression_AD.py index 80ae12dc9934..9ec8ee3b716b 100644 --- a/TestCases/serial_regression_AD.py +++ b/TestCases/serial_regression_AD.py @@ -86,7 +86,7 @@ def main(): discadj_rans_naca0012_sst.cfg_dir = "disc_adj_rans/naca0012" discadj_rans_naca0012_sst.cfg_file = "turb_NACA0012_sst.cfg" discadj_rans_naca0012_sst.test_iter = 10 - discadj_rans_naca0012_sst.test_vals = [-2.127004, -0.204660, 0.340440, -0.022055] + discadj_rans_naca0012_sst.test_vals = [-2.130129, -0.206396, 0.339910, -0.022046] test_list.append(discadj_rans_naca0012_sst) ####################################### diff --git a/TestCases/tutorials.py b/TestCases/tutorials.py index 455a59630cda..a6b23824d35e 100644 --- a/TestCases/tutorials.py +++ b/TestCases/tutorials.py @@ -96,7 +96,7 @@ def main(): sudo_tutorial.cfg_dir = "../Tutorials/incompressible_flow/Inc_Turbulent_Bend_Wallfunctions" sudo_tutorial.cfg_file = "sudo.cfg" sudo_tutorial.test_iter = 10 - sudo_tutorial.test_vals = [-14.579462, -13.203791, -13.601782, -12.616876, -14.005299, -10.817605, 15.000000, -2.296083] + sudo_tutorial.test_vals = [-14.286992, -12.868418, -13.150195, -11.400439, -13.027783, -9.510980, 15.000000, -2.288151] sudo_tutorial.command = TestCase.Command("mpirun -n 2", "SU2_CFD") test_list.append(sudo_tutorial) @@ -105,7 +105,7 @@ def main(): sudo_design_primal.cfg_dir = "../Tutorials/design/Inc_Turbulent_Bend_Wallfunctions" sudo_design_primal.cfg_file = "sudo_primal.cfg" sudo_design_primal.test_iter = 10 - sudo_design_primal.test_vals = [-13.474698, -12.487574, -12.441102, -11.418111, -12.552674, -9.712569, 89.034000] + sudo_design_primal.test_vals = [-12.064068, -11.348930, -11.059284, -10.029629, -11.437307, -8.258444, 64.545000] sudo_design_primal.command = TestCase.Command("mpirun -n 2", "SU2_CFD") test_list.append(sudo_design_primal) @@ -114,7 +114,7 @@ def main(): sudo_design_adjoint.cfg_dir = "../Tutorials/design/Inc_Turbulent_Bend_Wallfunctions" sudo_design_adjoint.cfg_file = "sudo_adjoint.cfg" sudo_design_adjoint.test_iter = 10 - sudo_design_adjoint.test_vals = [-4.133194, -3.691046, -2.581693, -3.476472, -3.837900, -6.900137] + sudo_design_adjoint.test_vals = [-4.118073, -3.680088, -2.567859, -3.440055, -3.710829, -7.211066] sudo_design_adjoint.command = TestCase.Command("mpirun -n 2", "SU2_CFD_AD") test_list.append(sudo_design_adjoint) From 4c87e81b5f430e097dc9a1d4a5b39a447175c5ef Mon Sep 17 00:00:00 2001 From: bigfooted Date: Mon, 3 Mar 2025 22:39:19 +0100 Subject: [PATCH 45/49] update rotating_cylinder --- TestCases/parallel_regression.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index d3e7eb0fe5af..4bb9f65fb137 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -1233,7 +1233,7 @@ def main(): # For a thin disk with the inner and outer radius of this geometry, from # "Formulas for Stress, Strain, and Structural Matrices", 2nd Edition, figure 19-4, # the maximum stress is 165.6MPa, we get a Von Misses stress very close to that. - rotating_cylinder_fea.test_vals = [-6.861940, -6.835545, -6.895500, 22, -8.313847, 1.6502e+08] + rotating_cylinder_fea.test_vals = [-6.005467, -5.615543, -5.615529, 38.000000, -8.126591, 164570000.000000] test_list.append(rotating_cylinder_fea) # Dynamic beam, 2d From bffddda5bd58982a03ef2226aa6688ac28f8ded9 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Mon, 3 Mar 2025 23:49:07 +0100 Subject: [PATCH 46/49] update species multizone --- TestCases/parallel_regression.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index 4bb9f65fb137..34ec50d914db 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -1607,7 +1607,7 @@ def main(): species3_multizone_restart.cfg_dir = "species_transport/multizone" species3_multizone_restart.cfg_file = "configMaster.cfg" species3_multizone_restart.test_iter = 5 - species3_multizone_restart.test_vals = [-6.111017, -5.720050] + species3_multizone_restart.test_vals = [-2.081789, -1.936012] species3_multizone_restart.multizone = True test_list.append(species3_multizone_restart) From e7626ddb02d21a12244cd38bef313bc8da3b7004 Mon Sep 17 00:00:00 2001 From: bigfooted Date: Tue, 4 Mar 2025 07:41:43 +0100 Subject: [PATCH 47/49] update sp --- .../streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref b/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref index 861b1bbfada2..dece285b96fc 100644 --- a/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref +++ b/TestCases/incomp_navierstokes/streamwise_periodic/chtPinArray_2d/of_grad_findiff.csv.ref @@ -1,2 +1,2 @@ "VARIABLE" , "AVG_DENSITY[0]", "AVG_ENTHALPY[0]", "AVG_NORMALVEL[0]", "DRAG[0]" , "EFFICIENCY[0]" , "FORCE_X[0]" , "FORCE_Y[0]" , "FORCE_Z[0]" , "LIFT[0]" , "MOMENT_X[0]" , "MOMENT_Y[0]" , "MOMENT_Z[0]" , "SIDEFORCE[0]" , "SURFACE_MACH[0]", "SURFACE_MASSFLOW[0]", "SURFACE_MOM_DISTORTION[0]", "SURFACE_PRESSURE_DROP[0]", "SURFACE_SECONDARY[0]", "SURFACE_SECOND_OVER_UNIFORM[0]", "SURFACE_STATIC_PRESSURE[0]", "SURFACE_STATIC_TEMPERATURE[0]", "SURFACE_TOTAL_PRESSURE[0]", "SURFACE_TOTAL_TEMPERATURE[0]", "SURFACE_UNIFORMITY[0]", "AVG_TEMPERATURE[1]", "MAXIMUM_HEATFLUX[1]", "TOTAL_HEATFLUX[1]", "FINDIFF_STEP" -0 , 0.0 , -2300000.0044703484, 6.661338199999911e-08, 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , -2.389999999297121, 6.660999999418455e-08, -18.70800000053352 , 0.0 , 18.32399999929235 , 34.89000000023168 , 14349.999997875784 , -660.0000006073969 , -921.000000175809 , -649.9999926745659 , -34.59999999844143 , -719.9999970453064, 0.0 , -499.99999873762135, 1e-08 +0 , 0.0 , -3800000.0175088644, -3.330699999961374e-08, 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , 0.0 , -1.4500000006245628, -5.5510000002640306e-08, -42.070000000338226 , 0.0 , 43.11999999839777 , 79.95999999899084 , 5740.000000287182 , -1079.9999927257886 , 79.99999951380232 , -1080.0000040944724 , -37.40000000806987 , -729.9999992937956, 0.0 , 790.0000014160469, 1e-08 From 60ac5a6e4db43e52b72dff80dcbd8f2fb1e4305f Mon Sep 17 00:00:00 2001 From: Pedro Gomes <38071223+pcarruscag@users.noreply.github.com> Date: Tue, 4 Mar 2025 09:24:24 +0000 Subject: [PATCH 48/49] Apply suggestions from code review --- .github/workflows/regression.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/regression.yml b/.github/workflows/regression.yml index 59cb44fd8cd0..2502204b64c4 100644 --- a/.github/workflows/regression.yml +++ b/.github/workflows/regression.yml @@ -209,7 +209,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} + args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2:240320-1536 with: @@ -255,7 +255,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} -a "--tsan" + args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--tsan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-tsan:240320-1536 with: @@ -300,7 +300,7 @@ jobs: uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: # -t -c - args: -b ${{github.ref}} -t corner_node -c corner_node -s ${{matrix.testscript}} -a "--asan" + args: -b ${{github.ref}} -t develop -c develop -s ${{matrix.testscript}} -a "--asan" - name: Cleanup uses: docker://ghcr.io/su2code/su2/test-su2-asan:240320-1536 with: From c5527d3fcda4747bdd9bdd719a8bee330f90d8d2 Mon Sep 17 00:00:00 2001 From: Pedro Gomes <38071223+pcarruscag@users.noreply.github.com> Date: Tue, 4 Mar 2025 10:44:36 +0000 Subject: [PATCH 49/49] Update TestCases/parallel_regression.py [skip ci] --- TestCases/parallel_regression.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TestCases/parallel_regression.py b/TestCases/parallel_regression.py index 34ec50d914db..24554725b645 100644 --- a/TestCases/parallel_regression.py +++ b/TestCases/parallel_regression.py @@ -1233,7 +1233,7 @@ def main(): # For a thin disk with the inner and outer radius of this geometry, from # "Formulas for Stress, Strain, and Structural Matrices", 2nd Edition, figure 19-4, # the maximum stress is 165.6MPa, we get a Von Misses stress very close to that. - rotating_cylinder_fea.test_vals = [-6.005467, -5.615543, -5.615529, 38.000000, -8.126591, 164570000.000000] + rotating_cylinder_fea.test_vals = [-6.861940, -6.835550, -6.895497, 22, -8.313847, 1.6502e+08] test_list.append(rotating_cylinder_fea) # Dynamic beam, 2d