2024-09-21 13:37:03 +03:30
|
|
|
#include "boundaryIntegrationList.hpp"
|
|
|
|
#include "integration.hpp"
|
|
|
|
|
|
|
|
pFlow::boundaryIntegrationList::boundaryIntegrationList(
|
|
|
|
const pointStructure &pStruct,
|
|
|
|
const word &method,
|
|
|
|
integration &intgrtn
|
|
|
|
)
|
|
|
|
:
|
|
|
|
ListPtr<boundaryIntegration>(6),
|
|
|
|
boundaries_(pStruct.boundaries())
|
|
|
|
{
|
|
|
|
|
|
|
|
for(uint32 i=0; i<6; i++)
|
|
|
|
{
|
|
|
|
this->set(
|
|
|
|
i,
|
|
|
|
boundaryIntegration::create(
|
|
|
|
boundaries_[i],
|
|
|
|
pStruct,
|
|
|
|
method,
|
|
|
|
intgrtn
|
|
|
|
)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
bool pFlow::boundaryIntegrationList::correct(real dt, realx3PointField_D &y, realx3PointField_D &dy)
|
|
|
|
{
|
|
|
|
for(auto& bndry:*this)
|
|
|
|
{
|
|
|
|
if(!bndry->correct(dt, y, dy))
|
|
|
|
{
|
2024-10-18 23:13:20 +03:30
|
|
|
fatalErrorInFunction<<"Error in correcting boundary "<<
|
|
|
|
bndry->boundaryName()<<endl;
|
2024-09-21 13:37:03 +03:30
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
2024-10-18 23:13:20 +03:30
|
|
|
|
|
|
|
bool pFlow::boundaryIntegrationList::correctPStruct(
|
|
|
|
real dt,
|
|
|
|
pointStructure &pStruct,
|
|
|
|
const realx3PointField_D &vel)
|
|
|
|
{
|
|
|
|
for(auto& bndry:*this)
|
|
|
|
{
|
|
|
|
if(!bndry->correctPStruct(dt, vel))
|
|
|
|
{
|
|
|
|
fatalErrorInFunction<<"Error in correcting boundary "<<
|
|
|
|
bndry->boundaryName()<<" in pointStructure."<<endl;
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|