yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #13031
[Branch ~yade-pkg/yade/git-trunk] Rev 4019: small fix in getConstriction() + a typo
------------------------------------------------------------
revno: 4019
committer: bchareyre <bruno.chareyre@xxxxxxxxxxxxxxx>
timestamp: Wed 2017-03-08 18:35:20 +0100
message:
small fix in getConstriction() + a typo
modified:
lib/triangulation/FlowBoundingSphere.ipp
pkg/pfv/DummyFlowEngine.cpp
--
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 'lib/triangulation/FlowBoundingSphere.ipp'
--- lib/triangulation/FlowBoundingSphere.ipp 2017-03-08 10:33:22 +0000
+++ lib/triangulation/FlowBoundingSphere.ipp 2017-03-08 17:35:20 +0000
@@ -663,9 +663,9 @@
RTriangulation& Tri = T[currentTes].Triangulation();
vector<double> constrictions;
for (FiniteFacetsIterator f_it=Tri.finite_facets_begin(); f_it != Tri.finite_facets_end();f_it++){
- //in the periodic case, we retain only the facets incident to at least one non-ghost cell
- if ( (f_it->first->neighbor(f_it->second)->info().isGhost && f_it->first->info().isGhost)
- || f_it->first->info().index == 0 || f_it->first->neighbor(f_it->second)->info().index == 0) continue;
+ // in the periodic case, we retain only the facets incident to at least one non-ghost cell
+ // plus if one cell is ghost it must be facet->first (else they would appear twice)
+ if ( f_it->first->info().isGhost || f_it->first->info().index == 0 || f_it->first->neighbor(f_it->second)->info().index == 0) continue;
constrictions.push_back(computeEffectiveRadius(f_it->first, f_it->second));
}
return constrictions;
@@ -678,8 +678,7 @@
vector<Constriction> constrictions;
for (FiniteFacetsIterator f_it=Tri.finite_facets_begin(); f_it != Tri.finite_facets_end();f_it++){
//in the periodic case, we retain only the facets incident to at least one non-ghost cell
- if ( (f_it->first->neighbor(f_it->second)->info().isGhost && f_it->first->info().isGhost)
- || f_it->first->info().index == 0 || f_it->first->neighbor(f_it->second)->info().index == 0) continue;
+ if ( f_it->first->info().isGhost || f_it->first->info().index == 0 || f_it->first->neighbor(f_it->second)->info().index == 0) continue;
vector<double> rn;
const CVector& normal = f_it->first->info().facetSurfaces[f_it->second];
if (!normal[0] && !normal[1] && !normal[2]) continue;
=== modified file 'pkg/pfv/DummyFlowEngine.cpp'
--- pkg/pfv/DummyFlowEngine.cpp 2014-11-17 14:04:32 +0000
+++ pkg/pfv/DummyFlowEngine.cpp 2017-03-08 17:35:20 +0000
@@ -9,7 +9,7 @@
// This is an example of how to derive a new FlowEngine with additional data and possibly completely new behaviour.
// Every functions of the base engine can be overloaded, and new functions can be added
-//keep this #ifdef as long as you don't really want to realize a final version publicly, it will save compilation time for everyone else
+//keep this #ifdef as long as you don't really want to release a final version publicly, it will save compilation time for everyone else
//when you want it compiled, you can pass -DDUMMYFLOW to cmake, or just uncomment the following line
// #define DUMMYFLOW
#ifdef DUMMYFLOW