|
[Sponsors] |
iPoint, iMarker, and iVertex; and problem with MPI |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 4, 2021, 01:51 |
iPoint, iMarker, and iVertex; and problem with MPI
|
#1 |
Member
Zhen ZHANG
Join Date: Jun 2018
Location: Beijing, China
Posts: 56
Rep Power: 8 |
Hi all,
I got a problem when setting values at the boundary to the volume data container. I created a VectorType member sens_inlet in the CEulerSolver class and resized it to nPoint. I then registered the Tt of all vertices at the inlet boundary. After extracting the sensitivity, I set them to the sens_inlet using the following codes: Code:
for(unsigned short iMarker=0; iMarker < config->GetnMarker_All(); iMarker++) { for (unsigned long iVertex = 0; iVertex < geometry->GetnVertex(iMarker); iVertex++) { unsigned long iPoint = geometry->nodes->GetGlobalIndex(geometry->vertex[iMarker][iVertex]->GetNode()); nodes->SetSens_Inlet_T(iPoint,SU2_TYPE::GetDerivative(Inlet_Ttotal[iMarker][iVertex]))}} However, in the result file, the non-zero values of the sens_inlet do not appear at the inlet boundary (see the attached figure). If running with MPI, it returns an error "Assertion `i>=0 && i<m_rows' failed". Could anybody give me some clues why this problem happen? Thanks in advance! |
|
August 4, 2021, 03:10 |
|
#2 |
Member
Zhen ZHANG
Join Date: Jun 2018
Location: Beijing, China
Posts: 56
Rep Power: 8 |
Well, I changed the iPoint calculation to
Code:
unsigned long iPoint = geometry->vertex[iMarker][iVertex]->GetNode(); What is the difference between these two calculations? Thanks, Zhen |
|
|
|