yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #11852
[Branch ~yade-pkg/yade/git-trunk] Rev 3593: fix previous commit for case (fusionDetection && hertz model) in capillary law (re-initiate bodie...
------------------------------------------------------------
revno: 3593
committer: Christian Jakob <jakob@xxxxxxxxxxxxxxxxxxx>
timestamp: Fri 2015-02-20 09:52:41 +0100
message:
fix previous commit for case (fusionDetection && hertz model) in capillary law (re-initiate bodiesMenisciiList at first real contact) and add some comments
modified:
pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.cpp
pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.hpp
--
lp:yade
https://code.launchpad.net/~yade-pkg/yade/git-trunk
Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-pkg/yade/git-trunk/+edit-subscription
=== modified file 'pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.cpp'
--- pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.cpp 2015-02-19 12:54:58 +0000
+++ pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.cpp 2015-02-20 08:52:41 +0000
@@ -40,7 +40,7 @@
F = 0;
delta1 = 0;
delta2 = 0;
-};
+}
MeniscusParameters::MeniscusParameters(const MeniscusParameters &source)
{
@@ -66,10 +66,11 @@
if (CapillaryPhys::getClassIndexStatic()==I->phys->getClassIndex()) hertzOn=false;
else if (MindlinCapillaryPhys::getClassIndexStatic()==I->phys->getClassIndex()) hertzOn=true;
else LOG_ERROR("The capillary law is not implemented for interactions using"<<I->phys->getClassName());
+ bodiesMenisciiList.initialized = false;//must be re-initialized after creation of first real contact in the model
+ hertzInitialized = true;
break;
}
}
- hertzInitialized = true;
}
if (fusionDetection && !bodiesMenisciiList.initialized) bodiesMenisciiList.prepare(scene,hertzOn);
@@ -156,7 +157,7 @@
if ((fusionDetection) || (hertzOn ? mindlinContactPhysics->isBroken : cundallContactPhysics->isBroken)) bodiesMenisciiList.remove(interaction);
if (D>0) scene->interactions->requestErase(interaction);
else if ((Pinterpol > 0) && (showError)) {
- LOG_ERROR("No meniscus found at a contact. capillaryPressure may be too large wrt. the loaded data files.") // V=0 at a contact reveals a problem if and only if uc* > 0
+ LOG_ERROR("No meniscus found at a contact. capillaryPressure may be too large wrt. the loaded data files."); // V=0 at a contact reveals a problem if and only if uc* > 0
showError = false;//show error message once / avoid console spam
}
}
@@ -510,12 +511,15 @@
return os;
}
+//what is this function for? it is never called...
+//TODO: remove?
BodiesMenisciiList::BodiesMenisciiList(Scene * scene, bool hertzOn)
{
initialized=false;
prepare(scene, hertzOn);
}
+
bool BodiesMenisciiList::prepare(Scene * scene, bool hertzOn)
{
//cerr << "preparing bodiesInteractionsList" << endl;
=== modified file 'pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.hpp'
--- pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.hpp 2015-02-19 13:02:02 +0000
+++ pkg/dem/Law2_ScGeom_CapillaryPhys_Capillarity.hpp 2015-02-20 08:52:41 +0000
@@ -61,7 +61,7 @@
public:
BodiesMenisciiList();
- BodiesMenisciiList(Scene*,bool);
+ BodiesMenisciiList(Scene*,bool);//TODO: remove?
bool prepare(Scene*,bool);
bool insert(const shared_ptr<Interaction>&);
bool remove(const shared_ptr<Interaction>&);