Commit 4f0399a8 authored by Armin Erraji's avatar Armin Erraji

Decreased the number of iterations for the calculation of the aperture point...

Decreased the number of iterations for the calculation of the aperture point to 5 and in CombinatedModelTest, the number of reflections and diffractions are now calculated via the member functions of CPropagationPath
parent 1b5f4a86
......@@ -109,7 +109,7 @@ bool ITAPropagationPathSim::CombinatedModel::Diffraction::ConstructAperturePoint
vpVertexDiff.push_back(make_shared<VistaVector3D>(*v3LastFromVertex - v3SensorPosition));
//Iterative a given number of times to get the exact position of the diffraction apertures
const size_t iNumIterations = 10;
const size_t iNumIterations = 5;
for(size_t iCurrentIteration = 0; iCurrentIteration< iNumIterations; iCurrentIteration++)
{
......
......@@ -89,7 +89,7 @@ int main( int iNumInArgs, char* pcInArgs[] )
sw.start();
pPathEngine->ApplyEmitter(pEmitter,ITAGeo::DIFFRACTION_ORDER_2,ORDER_4,ORDER_6);
pPathEngine->ApplyEmitter(pEmitter,ITAGeo::DIFFRACTION_ORDER_2,ORDER_2,ORDER_3);
cout << "Calculation time applying emitter: " << timeToString(sw.stop()) << endl;
sw.start();
......@@ -113,30 +113,19 @@ int main( int iNumInArgs, char* pcInArgs[] )
for (auto& path : oPathListVisible)
for (auto& oPath : oPathListVisible)
{
long iNumReflections = 0, iNumDiffractions = 0;
for (auto& anchor : path)
{
if (anchor->iAnchorType == ITAGeo::CPropagationAnchor::SPECULAR_REFLECTION)
{
iNumReflections++;
}
else if (anchor->iAnchorType == ITAGeo::CPropagationAnchor::DIFFRACTION_OUTER_APEX)
{
iNumDiffractions++;
}
}
long iNumReflections = (long) oPath.GetNumReflections();
long iNumDiffractions = (long) oPath.GetNumDiffractions();
string sPathName = "Paths_Refl_Order_" + to_string(iNumReflections) + "_Diffr_Order_" + to_string(iNumDiffractions);
oGeoModel.AddPropagationPathVisualization(path, sPathName);
oGeoModel.AddPropagationPathVisualization(oPath, sPathName);
}
oPathListVisible.Store("CombinatedModelTest_" + sInFile + ".json");
oPathListVisible.Store("CombinedModelTest_" + sInFile + ".json");
oGeoModel.Store(sSubFolder +"CombinatedModelTest_"+ sInFile);
oGeoModel.Store(sSubFolder +"CombinedModelTest_"+ sInFile);
return 0;
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment