Merge pull request #107 from PhasicFlow/develop

Modification in streams and sphereInteraciton
This commit is contained in:
Hamidreza Norouzi 2024-05-05 23:04:33 +03:30 committed by GitHub
commit 6a739e79b8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 15 additions and 7 deletions

View File

@ -130,10 +130,10 @@ public:
csPairContainerType& pwPairs,
bool force = false) override
{
ppTimer().start();
Particles().boundingSphere().updateBoundaries(DataDirection::SlaveToMaster);
ppTimer().start();
const auto& position = Particles().pointPosition().deviceViewAll();
const auto& flags = Particles().dynPointStruct().activePointsMaskDevice();
const auto& diam = Particles().boundingSphere().deviceViewAll();
@ -167,6 +167,7 @@ public:
csPairContainerType& pwPairs,
bool force = false)override
{
Particles().boundingSphere().updateBoundaries(DataDirection::SlaveToMaster);
return csBoundaries_[i].broadSearch(
iter,
t,
@ -176,7 +177,6 @@ public:
force);
}
bool enterBroadSearch(uint32 iter, real t, real dt)const override
{
if(ppwContactSearch_)

View File

@ -166,12 +166,12 @@ bool pFlow::sphereInteraction<cFM,gMM, cLT>::iterate()
bool broadSearch = contactSearch_().enterBroadSearch(iter, t, dt);
/*sphParticles_.diameter().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.diameter().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.velocity().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.rVelocity().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.mass().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.I().updateBoundaries(DataDirection::SlaveToMaster);
sphParticles_.propertyId().updateBoundaries(DataDirection::SlaveToMaster);*/
sphParticles_.propertyId().updateBoundaries(DataDirection::SlaveToMaster);
if(broadSearch)

View File

@ -156,3 +156,9 @@ void pFlow::processorOstream::indent()
checkForPrefix();
Ostream::indent();
}
pFlow::processorOstream &pFlow::processorOstream::setColor(const char *colorCode)
{
Ostream::write(colorCode);
return *this;
}

View File

@ -139,6 +139,8 @@ public:
/// Add indentation characters
void indent() override;
processorOstream& setColor(const char* colorCode);
}; // processorOstream

View File

@ -33,7 +33,7 @@ namespace pFlow
}
#define INFORMATION pFlow::pOutput<<boldChar<<magentaColor<<"> INFO: "<<defaultColor<<magentaColor
#define INFORMATION pFlow::pOutput.setColor(boldChar).setColor(magentaColor)<<"> INFO: "<<defaultColor<<magentaColor
#define END_INFO defaultColor<<pFlow::endl
#define REPORT(n) pFlow::mOutput.space(2*n)