yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #01557
[svn] r1895 - in trunk/pkg/dem: Engine/EngineUnit PreProcessor
Author: eudoxos
Date: 2009-07-28 15:15:09 +0200 (Tue, 28 Jul 2009)
New Revision: 1895
Modified:
trunk/pkg/dem/Engine/EngineUnit/MacroMicroElasticRelationships.cpp
trunk/pkg/dem/PreProcessor/TetraTestGen.cpp
Log:
Fix TetraTestGen crasher (functionally still brokne, though)
Modified: trunk/pkg/dem/Engine/EngineUnit/MacroMicroElasticRelationships.cpp
===================================================================
--- trunk/pkg/dem/Engine/EngineUnit/MacroMicroElasticRelationships.cpp 2009-07-28 09:07:11 UTC (rev 1894)
+++ trunk/pkg/dem/Engine/EngineUnit/MacroMicroElasticRelationships.cpp 2009-07-28 13:15:09 UTC (rev 1895)
@@ -14,6 +14,7 @@
#include<yade/pkg-dem/SDECLinkGeometry.hpp> // FIXME - I can't dispatch by SDECLinkGeometry <-> SpheresContactGeometry !!?
#include<yade/pkg-dem/SDECLinkPhysics.hpp> // FIXME
#include<yade/pkg-dem/BodyMacroParameters.hpp>
+#include<yade/pkg-dem/Tetra.hpp>
#include<yade/core/Omega.hpp>
#include<yade/core/MetaBody.hpp>
@@ -119,6 +120,10 @@
linkPhysics->ks = linkPhysics->initialKs;
linkPhysics->equilibriumDistance = linkPhysics->initialEquilibriumDistance;
}
+ else if(dynamic_cast<TetraBang*>(interaction->interactionGeometry.get()) && !interaction->interactionPhysics){
+ // TetraLaw doesn't use InteractionPhysics anyway, it accesses bodies' parameters directly
+ interaction->interactionPhysics=shared_ptr<InteractionPhysics>(new InteractionPhysics);
+ }
}
};
-YADE_PLUGIN("MacroMicroElasticRelationships");
\ No newline at end of file
+YADE_PLUGIN("MacroMicroElasticRelationships");
Modified: trunk/pkg/dem/PreProcessor/TetraTestGen.cpp
===================================================================
--- trunk/pkg/dem/PreProcessor/TetraTestGen.cpp 2009-07-28 09:07:11 UTC (rev 1894)
+++ trunk/pkg/dem/PreProcessor/TetraTestGen.cpp 2009-07-28 13:15:09 UTC (rev 1895)
@@ -10,10 +10,11 @@
bool TetraTestGen::generate()
{
- //Shop::setDefault("param_pythonRunExpr",string("if S.i%50==0 and S.i<1000 and S.i>500:\n\tprint S.i,len(S.sel),B[1].x, B[1].E"));
+ Shop::setDefault<int>("param_timeStepUpdateInterval",-1);
rootBody=Shop::rootBody();
Shop::rootBodyActors(rootBody);
+ rootBody->dt=1e-5;
#if 0
shared_ptr<MetaBody> oldRootBody=Omega::instance().getRootBody();