Class reference (yade.wrapper module)

Bodies

Body

class yade.wrapper.Body(inherits Serializable)

A particle, basic element of simulation; interacts with other bodies.

aspherical(=false)

Whether this body has different inertia along principal axes; NewtonIntegrator makes use of this flag to call rotation integration routine for aspherical bodies, which is more expensive.

bound(=uninitalized)

Bound, approximating volume for the purposes of collision detection.

bounded(=true)

Whether this body should have Body.bound created. Note that bodies without a bound do not participate in collision detection. (In c++, use Body::isBounded/Body::setBounded)

clumpId

Id of clump this body makes part of; invalid number if not part of clump; see Body::isStandalone, Body::isClump, Body::isClumpMember properties.

This property is not meant to be modified directly from Python, use O.bodies.appendClumped instead.

dynamic(=true)

Whether this body will be moved by forces. (In c++, use Body::isDynamic/Body::setDynamic)

flags(=FLAG_DYNAMIC|FLAG_BOUNDED)

Bits of various body-related flags. Do not access directly. In c++, use isDynamic/setDynamic, isBounded/setBounded. In python, use Body.dynamic and Body.bounded.

groupMask(=1)

Bitmask for determining interactions.

id(=Body::ID_NONE)

Unique id of this body.

isClump

True if this body is clump itself, false otherwise.

isClumpMember

True if this body is clump member, false otherwise.

isStandalone

True if this body is neither clump, nor clump member; false otherwise.

mask

Shorthand for Body::groupMask

mat

Shorthand for Body::material

material(=uninitalized)

Material instance associated with this body.

shape(=uninitalized)

Geometrical Shape.

state(=new State)

Physical state.

Shape

digraph Shape {
        rankdir=RL;
        margin=.2;
        "Shape" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Shape"];
        "Box" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Box"];
        "Box" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Facet" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Facet"];
        "Facet" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Cylinder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Cylinder"];
        "Cylinder" -> "Sphere" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ChainedCylinder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ChainedCylinder"];
        "ChainedCylinder" -> "Cylinder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Sphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Sphere"];
        "Sphere" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Wall" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Wall"];
        "Wall" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Tetra" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Tetra"];
        "Tetra" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Clump" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Clump"];
        "Clump" -> "Shape" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.Shape(inherits Serializable)

Geometry of a body

color(=Vector3r(1, 1, 1))

Color for rendering (normalized RGB).

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

highlight(=false)

Whether this Shape will be highlighted when rendered.

wire(=false)

Whether this Shape is rendered using color surfaces, or only wireframe (can still be overridden by global config of the renderer).

class yade.wrapper.Box(inherits ShapeSerializable)

Box (cuboid) particle geometry. (Avoid using in new code, prefer Facet instead.

extents(=uninitalized)

Half-size of the cuboid

class yade.wrapper.ChainedCylinder(inherits CylinderSphereShapeSerializable)

Geometry of a deformable chained cylinder, using geometry MinkCylinder.

chainedOrientation(=Quaternionr::Identity())

Deviation of node1 orientation from node-to-node vector

initLength(=0)

tensile-free length, used as reference for tensile strain

class yade.wrapper.Clump(inherits ShapeSerializable)

Rigid aggregate of bodies

class yade.wrapper.Cylinder(inherits SphereShapeSerializable)

Geometry of a cylinder, as Minkowski sum of line and sphere.

length(=NaN)

Length [m]

segment(=Vector3r::Zero())

Length vector

class yade.wrapper.Facet(inherits ShapeSerializable)

Facet (triangular particle) geometry.

edgeAdjHalfAngle(=vector<Real>(3, 0))

half angle between normals of this facet and the adjacent facet [experimental]

edgeAdjIds(=vector<Body::id_t>(3, Body::ID_NONE))

Facet id’s that are adjacent to respective edges [experimental]

vertices(=vector<Vector3r>(3))

Vertex positions in local coordinates.

class yade.wrapper.Sphere(inherits ShapeSerializable)

Geometry of spherical particle.

radius(=NaN)

Radius [m]

class yade.wrapper.Tetra(inherits ShapeSerializable)

Tetrahedron geometry.

v(=std::vector<Vector3r>(4))

Tetrahedron vertices in global coordinate system.

class yade.wrapper.Wall(inherits ShapeSerializable)

Object representing infinite plane aligned with the coordinate system (axis-aligned wall).

axis(=0)

Axis of the normal; can be 0,1,2 for +x, +y, +z respectively (Body’s orientation is disregarded for walls)

sense(=0)

Which side of the wall interacts: -1 for negative only, 0 for both, +1 for positive only

State

digraph State {
        rankdir=RL;
        margin=.2;
        "State" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.State"];
        "CFpmState" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CFpmState"];
        "CFpmState" -> "State" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "RpmState" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.RpmState"];
        "RpmState" -> "State" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ChainedState" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ChainedState"];
        "ChainedState" -> "State" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CpmState" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CpmState"];
        "CpmState" -> "State" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.State(inherits Serializable)

State of a body (spatial configuration, internal variables).

accel(=Vector3r::Zero())

Current acceleration.

angAccel(=Vector3r::Zero())

Current angular acceleration

angMom(=Vector3r::Zero())

Current angular momentum

angVel(=Vector3r::Zero())

Current angular velocity

blockedDOFs

Degress of freedom where linear/angular velocity will be always constant (equal to zero, or to an user-defined value), regardless of applied force/torque. List of any combination of ‘x’,’y’,’z’,’rx’,’ry’,’rz’.

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

inertia(=Vector3r::Zero())

Inertia of associated body, in local coordinate system.

mass(=0)

Mass of this body

ori

Current orientation.

pos

Current position.

refOri(=Quaternionr::Identity())

Reference orientation

refPos(=Vector3r::Zero())

Reference position

se3(=Se3r(Vector3r::Zero(), Quaternionr::Identity()))

Position and orientation as one object.

vel(=Vector3r::Zero())

Current linear velocity.

class yade.wrapper.CFpmState(inherits StateSerializable)

CFpm state information about each body.

None of that is used for computation (at least not now), only for post-processing.

numBrokenCohesive(=0)

Number of broken cohesive links. [-]

class yade.wrapper.ChainedState(inherits StateSerializable)

State of a chained bodies, containing information on connectivity in order to track contacts jumping over contiguous elements. Chains are 1D lists from which id of chained bodies are retrieved via :yref:rank<ChainedState::rank>` and :yref:chainNumber<ChainedState::chainNumber>`.

addToChain((int)bodyId) → None

Add body to current active chain

chainNumber(=0)

chain id

rank(=0)

rank in the chain

class yade.wrapper.CpmState(inherits StateSerializable)

State information about body use by cpm-model.

None of that is used for computation (at least not now), only for post-processing.

epsPlBroken(=0)

Plastic strain on contacts already deleted (bogus values)

epsVolumetric(=0)

Volumetric strain around this body (unused for now)

normDmg(=0)

Average damage including already deleted contacts (it is really not damage, but 1-relResidualStrength now)

normEpsPl(=0)

Sum of plastic strains normalized by number of contacts (bogus values)

numBrokenCohesive(=0)

Number of (cohesive) contacts that damaged completely

numContacts(=0)

Number of contacts with this body

sigma(=Vector3r::Zero())

Normal stresses on the particle

tau(=Vector3r::Zero())

Shear stresses on the particle.

class yade.wrapper.RpmState(inherits StateSerializable)

State information about Rpm body.

specimenMass(=0)

Indicates the mass of the whole stone, which owns the particle.

specimenMaxDiam(=0)

Indicates the maximal diametr of the specimen.

specimenNumber(=0)

The variable is used for particle size distribution analyze. Indicates, to which part of specimen belongs para of particles.

specimenVol(=0)

Indicates the mass of the whole stone, which owns the particle.

Material

digraph Material {
        rankdir=RL;
        margin=.2;
        "Material" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Material"];
        "RpmMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.RpmMat"];
        "RpmMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "FrictMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FrictMat"];
        "FrictMat" -> "ElastMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "MomentMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.MomentMat"];
        "MomentMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CpmMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CpmMat"];
        "CpmMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CFpmMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CFpmMat"];
        "CFpmMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NormalInelasticMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NormalInelasticMat"];
        "NormalInelasticMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ElastMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ElastMat"];
        "ElastMat" -> "Material" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CohFrictMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CohFrictMat"];
        "CohFrictMat" -> "FrictMat" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ViscElMat" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ViscElMat"];
        "ViscElMat" -> "Material" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.Material(inherits Serializable)

Material properties of a body.

density(=1000)

Density of the material [kg/m³]

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

id(=-1, not shared)

Numeric id of this material; is non-negative only if this Material is shared (i.e. in O.materials), -1 otherwise. This value is set automatically when the material is inserted to the simulation via O.materials.append. (This id was necessary since before boost::serialization was used, shared pointers were not tracked properly; it might disappear in the future)

label(=uninitalized)

Textual identifier for this material; can be used for shared materials lookup in MaterialContainer.

newAssocState() → State

Return new State instance, which is associated with this Material. Some materials have special requirement on Body::state type and calling this function when the body is created will ensure that they match. (This is done automatically if you use utils.sphere, … functions from python).

class yade.wrapper.CFpmMat(inherits FrictMatElastMatMaterialSerializable)

cohesive frictional material, for use with other CFpm classes

type(=0)

Type of the particle. If particles of two different types interact, it will be with friction only (no cohesion).[-]

class yade.wrapper.CohFrictMat(inherits FrictMatElastMatMaterialSerializable)
isBroken(=true)

isCohesive(=true)

momentRotationLaw(=false)

Use bending/twisting moment at contact. The contact will have moments only if both bodies have this flag true. See CohFrictPhys::cohesionDisablesFriction for details.

normalCohesion(=10000000)

shearCohesion(=10000000)

class yade.wrapper.CpmMat(inherits FrictMatElastMatMaterialSerializable)

Concrete material, for use with other Cpm classes.

Note

Density is initialized to 4800 kgm⁻³automatically, which gives approximate 2800 kgm⁻³ on 0.5 density packing.

The model is contained in externally defined macro CPM_MATERIAL_MODEL, which features damage in tension, plasticity in shear and compression and rate-dependence. For commercial reasons, rate-dependence and compression-plasticity is not present in reduced version of the model, used when CPM_MATERIAL_MODEL is not defined. The full model will be described in detail in my (Václav Šmilauer) thesis along with calibration procedures (rigidity, poisson’s ratio, compressive/tensile strength ratio, fracture energy, behavior under confinement, rate-dependent behavior).

Even the public model is useful enough to run simulation on concrete samples, such as uniaxial tension-compression test.

G_over_E(=NaN)

Ratio of normal/shear stiffness at interaction level [-]

dmgRateExp(=0)

Exponent for normal viscosity function. [-]

dmgTau(=-1, deactivated if negative)

Characteristic time for normal viscosity. [s]

epsCrackOnset(=NaN)

Limit elastic strain [-]

isoPrestress(=0)

Isotropic prestress of the whole specimen. [Pa]

neverDamage(=false)

If true, no damage will occur (for testing only).

plRateExp(=0)

Exponent for visco-plasticity function. [-]

plTau(=-1, deactivated if negative)

Characteristic time for visco-plasticity. [s]

relDuctility(=NaN)

Relative ductility, for damage evolution law peak right-tangent. [-]

sigmaT(=NaN)

Initial cohesion [Pa]

class yade.wrapper.ElastMat(inherits MaterialSerializable)

Purely elastic material.

poisson(=.25)

Poisson’s ratio [-]

young(=1e9)

Young’s modulus [Pa]

class yade.wrapper.FrictMat(inherits ElastMatMaterialSerializable)

Material with internal friction.

frictionAngle(=.5)

Internal friction angle (in radians) [-]

class yade.wrapper.MomentMat(inherits FrictMatElastMatMaterialSerializable)

Material for constitutive law of (Plassiard & al., 2009); see Law2_SCG_MomentPhys_CohesionlessMomentRotation for details.

Users can input eta (constant for plastic moment) to Spheres and Boxes. For more complicated cases, users can modify TriaxialStressController to use different eta values during isotropic compaction.

eta(=0)

(has to be stored in this class and not by ContactLaw, because users may want to change its values before/after isotropic compaction.)

class yade.wrapper.NormalInelasticMat(inherits FrictMatElastMatMaterialSerializable)

Material class for particles whose contact obey to a normal inelasticity (governed by this coeff_dech).

coeff_dech(=1.0)

=kn(unload) / kn(load)

class yade.wrapper.RpmMat(inherits FrictMatElastMatMaterialSerializable)

Rock material, for use with other Rpm classes.

Brittleness(=0)

One of destruction parameters. [-] //(Needs to be reworked)

G_over_E(=1)

Ratio of normal/shear stiffness at interaction level. [-]

exampleNumber(=0)

Number of the specimen. This value is equal for all particles of one specimen. [-]

initCohesive(=false)

The flag shows, whether particles of this material can be cohesive. [-]

stressCompressMax(=0)

Maximal strength for compression. The main destruction parameter. [Pa] //(Needs to be reworked)

class yade.wrapper.ViscElMat(inherits MaterialSerializable)

Material for simple viscoelastic model of contact.

Note

Shop::getViscoelasticFromSpheresInteraction (and utils.getViscoelasticFromSpheresInteraction in python) compute kn, cn, ks, cs from analytical solution of a pair spheres interaction problem.

cn(=NaN)

Normal viscous constant

cs(=NaN)

Shear viscous constant

frictionAngle(=NaN)

Friction angle [rad]

kn(=NaN)

Normal elastic stiffness

ks(=NaN)

Shear elastic stiffness

Bound

digraph Bound {
        rankdir=RL;
        margin=.2;
        "Bound" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bound"];
        "Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Aabb"];
        "Aabb" -> "Bound" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.Bound(inherits Serializable)

Object bounding part of space taken by associated body; might be larger, used to optimalize collision detection

color(=Vector3r(1, 1, 1))

Color for rendering this object

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

max(=Vector3r(NaN, NaN, NaN))

Lower corner of box containing this bound (and the Body as well)

min(=Vector3r(NaN, NaN, NaN))

Lower corner of box containing this bound (and the Body as well)

class yade.wrapper.Aabb(inherits BoundSerializable)

Axis-aligned bounding box, for use with InsertionSortCollider. (This class is quasi-redundant since min,max are already contained in Bound itself. That might change at some point, though.)

Interactions

Interaction

class yade.wrapper.Interaction(inherits Serializable)

Interaction between pair of bodies.

cellDist

Distance of bodies in cell size units, if using periodic boundary conditions; id2 is shifted by this number of cells from its State::pos coordinates for this interaction to exist. Assigned by the collider.

Warning

(internal) cellDist must survive Interaction::reset(), it is only initialized in ctor. Interaction that was cancelled by the constitutive law, was reset() and became only potential must have the priod information if the geometric functor again makes it real. Good to know after few days of debugging that :-)

geom(=uninitalized)

Geometry part of the interaction.

id1(=0)

Id of the first body in this interaction.

id2(=0)

Id of the first body in this interaction.

isReal

True if this interaction has both geom and phys; False otherwise.

iterMadeReal(=-1)

Step number at which the interaction was fully (in the sense of geom and phys) created. (Should be touched only by IPhysDispatcher and InteractionLoop, therefore they are made friends of Interaction

phys(=uninitalized)

Physical (material) part of the interaction.

IGeom

digraph IGeom {
        rankdir=RL;
        margin=.2;
        "IGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.IGeom"];
        "Dem3DofGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Dem3DofGeom"];
        "Dem3DofGeom" -> "GenericSpheresContact" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Dem3DofGeom_SphereSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Dem3DofGeom_SphereSphere"];
        "Dem3DofGeom_SphereSphere" -> "Dem3DofGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Dem3DofGeom_FacetSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Dem3DofGeom_FacetSphere"];
        "Dem3DofGeom_FacetSphere" -> "Dem3DofGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TTetraGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TTetraGeom"];
        "TTetraGeom" -> "IGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ScGeom6D" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ScGeom6D"];
        "ScGeom6D" -> "ScGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Dem3DofGeom_WallSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Dem3DofGeom_WallSphere"];
        "Dem3DofGeom_WallSphere" -> "Dem3DofGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "GenericSpheresContact" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GenericSpheresContact"];
        "GenericSpheresContact" -> "IGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ScGeom"];
        "ScGeom" -> "GenericSpheresContact" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CylScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CylScGeom"];
        "CylScGeom" -> "ScGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "L3Geom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.L3Geom"];
        "L3Geom" -> "GenericSpheresContact" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.IGeom(inherits Serializable)

Geometrical configuration of interaction

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

class yade.wrapper.CylScGeom(inherits ScGeomGenericSpheresContactIGeomSerializable)

Geometry of a cylinder-sphere contact.

end(=Vector3r::Zero())

position of 2nd node (auto-updated)

id3(=0)

id of next chained cylinder (auto-updated)

onNode(=false)

contact on node?

relPos(=0)

position of the contact on the cylinder (0: node-, 1:node+) (auto-updated)

start(=Vector3r::Zero())

position of 1st node (auto-updated)

class yade.wrapper.Dem3DofGeom(inherits GenericSpheresContactIGeomSerializable)

Abstract base class for representing contact geometry of 2 elements that has 3 degrees of freedom: normal (1 component) and shear (Vector3r, but in plane perpendicular to the normal).

displacementN() → float
displacementT() → Vector3
logCompression(=false)

make strain go to -∞ for length going to zero (false by default).

refLength(=uninitalized)

some length used to convert displacements to strains. (auto-computed)

se31(=uninitalized)

Copy of body #1 se3 (needed to compute torque from the contact, strains etc). (auto-updated)

se32(=uninitalized)

Copy of body #2 se3. (auto-updated)

slipToDisplacementTMax((float)arg2) → float
slipToStrainTMax((float)arg2) → float
strainN() → float
strainT() → Vector3
class yade.wrapper.Dem3DofGeom_FacetSphere(inherits Dem3DofGeomGenericSpheresContactIGeomSerializable)

Class representing facet+sphere in contact which computes 3 degrees of freedom (normal and shear deformation).

cp1pt(=uninitalized)

Reference contact point on the facet in facet-local coords.

cp2rel(=uninitalized)

Orientation between +x and the reference contact point (on the sphere) in sphere-local coords

effR2(=uninitalized)

Effective radius of sphere

localFacetNormal(=uninitalized)

Unit normal of the facet plane in facet-local coordinates

class yade.wrapper.Dem3DofGeom_SphereSphere(inherits Dem3DofGeomGenericSpheresContactIGeomSerializable)

Class representing 2 spheres in contact which computes 3 degrees of freedom (normal and shear deformation).

cp1rel(=uninitalized)

Sphere’s #1 relative orientation of the contact point with regards to sphere-local +x axis (quasi-constant)

cp2rel(=uninitalized)

Same as cp1rel, but for sphere #2.

effR1(=uninitalized)

Effective radius of sphere #1; can be smaller/larger than refR1 (the actual radius), but quasi-constant throughout interaction life

effR2(=uninitalized)

Same as effR1, but for sphere #2.

class yade.wrapper.Dem3DofGeom_WallSphere(inherits Dem3DofGeomGenericSpheresContactIGeomSerializable)

Representation of contact between wall and sphere, based on Dem3DofGeom.

cp1pt(=uninitalized)

initial contact point on the wall, relative to the current contact point

cp2rel(=uninitalized)

orientation between +x and the reference contact point (on the sphere) in sphere-local coords

effR2(=uninitalized)

effective radius of sphere

class yade.wrapper.GenericSpheresContact(inherits IGeomSerializable)

Class uniting ScGeom and Dem3DofGeom, for the purposes of GlobalStiffnessTimeStepper. (It might be removed inthe future). Do not use this class directly.

contactPoint(=uninitalized)

some reference point for the interaction (usually in the middle). (auto-computed)

normal(=uninitalized)

Unit vector oriented along the interaction. (auto-updated)

refR1(=uninitalized)

Reference radius of particle #1. (auto-computed)

refR2(=uninitalized)

Reference radius of particle #2. (auto-computed)

class yade.wrapper.L3Geom(inherits GenericSpheresContactIGeomSerializable)

Geometry of contact given in local coordinates with 3 degress of freedom: normal and two in shear plane. [experimental]

trsf(=Matrix3r::Identity())

Transformation (rotation) from global to local coordinates. (the translation part is in GenericSpheresContact.contactPoint)

u(=Vector3r::Zero())

Displacement components, in local coordinates. (auto-updated)

u0

Zero displacement value; u0 should be always subtracted from the geometrical displacement u computed by appropriate IGeomFunctor, resulting in u. This value can be changed for instance

  1. by IGeomFunctor, e.g. to take in account large shear displacement value unrepresentable by underlying geomeric algorithm based on quaternions)
  2. by LawFunctor, to account for normal equilibrium position different from zero geometric overlap (set once, just after the interaction is created)
  3. by LawFunctor to account for plastic slip.

Note

Never set an absolute value of u0, only increment, since both IGeomFunctor and LawFunctor use it. If you need to keep track of plastic deformation, store it in IPhys isntead (this might be changed: have u0 for LawFunctor exclusively, and a separate value stored (when that is needed) inside classes deriving from L3Geom.

class yade.wrapper.ScGeom(inherits GenericSpheresContactIGeomSerializable)

Class representing geometry of two bodies in contact. The contact has 3 DOFs (normal and 2×shear) and uses incremental algorithm for updating shear. (For shear formulated in total displacements and rotations, see Dem3DofGeom and related classes).

We use symbols \vec{x}, \vec{v}, \vec{\omega} respectively for position, linear and angular velocities (all in global coordinates) and r for particles radii; subscripted with 1 or 2 to distinguish 2 spheres in contact. Then we compute unit contact normal

\vec{n}=\frac{\vec{x}_2-\vec{x}_1}{||\vec{x}_2-\vec{x}_1||}

Relative velocity of spheres is then

\vec{v}_{12}=(\vec{v}_2+\vec{\omega}_2\times(-r_2\vec{n}))-(\vec{v}_1+\vec{\omega}_1\times(r_1\vec{n}))

and its shear component

\Delta\vec{v}_{12}^s=\vec{v}_{12}-(\vec{n}\cdot\vec{v}_{12})\vec{n}.

Tangential displacement increment over last step then reads

\vec{x}_{12}^s=\Delta t \vec{v}_{12}^s.

incidentVel((Interaction)i[, (bool)avoidGranularRatcheting=True]) → Vector3

Return incident velocity of the interaction.

penetrationDepth(=NaN)

Penetration distance of spheres (positive if overlapping)

shearInc(=Vector3r::Zero())

Shear displacement increment in the last step

class yade.wrapper.ScGeom6D(inherits ScGeomGenericSpheresContactIGeomSerializable)

Class representing geometry of two bodies in contact. The contact has 6 DOFs (normal, 2×shear, twist, 2xbending) and uses ScGeom incremental algorithm for updating shear.

bending(=Vector3r::Zero())

Bending at contact as a vector defining axis of rotation and angle (angle=norm).

currentContactOrientation(=Quaternionr(1.0, 0.0, 0.0, 0.0))

initialContactOrientation(=Quaternionr(1.0, 0.0, 0.0, 0.0))

initialOrientation1(=Quaternionr(1.0, 0.0, 0.0, 0.0))

initialOrientation2(=Quaternionr(1.0, 0.0, 0.0, 0.0))

orientationToContact1(=Quaternionr(1.0, 0.0, 0.0, 0.0))

orientationToContact2(=Quaternionr(1.0, 0.0, 0.0, 0.0))

twist(=0)

Elastic twist angle of the contact.

twistCreep(=Quaternionr(1.0, 0.0, 0.0, 0.0))

class yade.wrapper.TTetraGeom(inherits IGeomSerializable)

Geometry of interaction between 2 tetrahedra, including volumetric characteristics

contactPoint(=uninitalized)

Contact point (global coords)

equivalentCrossSection(=NaN)

Cross-section of the overlap (perpendicular to the axis of least inertia

equivalentPenetrationDepth(=NaN)

??

maxPenetrationDepthA(=NaN)

??

maxPenetrationDepthB(=NaN)

??

normal(=uninitalized)

Normal of the interaction, directed in the sense of least inertia of the overlap volume

penetrationVolume(=NaN)

Volume of overlap [m³]

IPhys

digraph IPhys {
        rankdir=RL;
        margin=.2;
        "IPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.IPhys"];
        "FrictPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FrictPhys"];
        "FrictPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CohFrictPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CohFrictPhys"];
        "CohFrictPhys" -> "FrictPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "RpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.RpmPhys"];
        "RpmPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CapillaryPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CapillaryPhys"];
        "CapillaryPhys" -> "FrictPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CSPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CSPhys"];
        "CSPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ViscElPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ViscElPhys"];
        "ViscElPhys" -> "FrictPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CpmPhys"];
        "CpmPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "MomentPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.MomentPhys"];
        "MomentPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NormalInelasticityPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NormalInelasticityPhys"];
        "NormalInelasticityPhys" -> "FrictPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NormPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NormPhys"];
        "NormPhys" -> "IPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NormShearPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NormShearPhys"];
        "NormShearPhys" -> "NormPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CFpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CFpmPhys"];
        "CFpmPhys" -> "NormShearPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "MindlinPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.MindlinPhys"];
        "MindlinPhys" -> "FrictPhys" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.IPhys(inherits Serializable)

Physical (material) properties of interaction.

dispHierarchy([(bool)names=True]) → list

Return list of dispatch classes (from down upwards), starting with the class instance itself, top-level indexable at last. If names is true (default), return class names rather than numerical indices.

dispIndex

Return class index of this instance.

class yade.wrapper.CFpmPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Representation of a single interaction of the CFpm type, storage for relevant parameters

FnMax(=0)

Defines the maximum admissible normal force in traction FnMax=tensileStrength*crossSection, with crossSection=pi*Rmin^2. [Pa]

FsMax(=0)

Defines the maximum admissible tangential force in shear FsMax=cohesion*FnMax, with crossSection=pi*Rmin^2. [Pa]

cumulativeRotation(=0)

Cumulated rotation... [-]

frictionAngle(=0)

defines Coulomb friction. [deg]

initD(=0)

equilibrium distance for particles. Computed as the initial interparticular distance when bonded particle interact. initD=0 for non cohesive interactions.

initialOrientation1(=Quaternionr(1.0, 0.0, 0.0, 0.0))

Used for moment computation.

initialOrientation2(=Quaternionr(1.0, 0.0, 0.0, 0.0))

Used for moment computation.

isCohesive(=false)

If false, particles interact in a frictional way. If true, particles are bonded regarding the given cohesion and tensileStrength.

kr(=0)

Defines the stiffness to compute the resistive moment in rotation. [-]

maxBend(=0)

Defines the maximum admissible resistive moment in rotation Mtmax=maxBend*Fn, maxBend=eta*meanRadius. [m]

moment_bending(=Vector3r::Zero())

[N.m]

moment_twist(=Vector3r::Zero())

[N.m]

prevNormal(=Vector3r::Zero())

Normal to the contact at previous time step.

strengthSoftening(=0)

Defines the softening when Dtensile is reached to avoid explosion. Typically, when D > Dtensile, Fn=FnMax - (kn/strengthSoftening)*(Dtensile-D). [-]

tanFrictionAngle(=0)

Tangent of frictionAngle. [-]

class yade.wrapper.CSPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Physical properties for Cundall&Strack constitutive law, created by Ip2_2xFrictMat_CSPhys.

frictionAngle(=NaN)

Friction angle of the interaction. (auto-computed)

tanFrictionAngle(=NaN)

Precomputed tangent of CSPhys::frictionAngle. (auto-computed)

class yade.wrapper.CapillaryPhys(inherits FrictPhysNormShearPhysNormPhysIPhysSerializable)

Physics (of interaction) for Law2_ScGeom_CapillaryPhys_Capillarity. Rk: deprecated -> needs some work to be conform with the new formalism!

CapillaryPressure(=0.)

Value of the capillary pressure Uc defines as Ugas-Uliquid

Delta1(=0.)

Defines the surface area wetted by the meniscus on the smallest grains of radius R1 (R1<R2)

Delta2(=0.)

Defines the surface area wetted by the meniscus on the biggest grains of radius R2 (R1<R2)

Fcap(=Vector3r::Zero())

Capillary Force produces by the presence of the meniscus

Vmeniscus(=0.)

Volume of the menicus

fusionNumber(=0.)

Indicates the number of meniscii that overlap with this one

meniscus(=false)

Presence of a meniscus if true

class yade.wrapper.CohFrictPhys(inherits FrictPhysNormShearPhysNormPhysIPhysSerializable)
cohesionBroken(=true)

is cohesion active? will be set false when a fragile contact is broken

cohesionDisablesFriction(=false)

is shear strength the sum of friction and adhesion or only adhesion?

creep_viscosity(=-1)

creep viscosity [Pa.s/m].

fragile(=true)

do cohesion disapear when contact strength is exceeded?

kr(=0)

rotational stiffness [N.m/rad]

momentRotationLaw(=false)

use bending/twisting moment at contacts. See CohFrictPhys::cohesionDisablesFriction for details.

moment_bending(=Vector3r(0, 0, 0))

Bending moment

moment_twist(=Vector3r(0, 0, 0))

Twist moment

normalAdhesion(=0)

tensile strength

shearAdhesion(=0)

cohesive part of the shear strength (a frictional term might be added depending on Law2_ScGeom_CohFrictPhys_CohesionMoment::always_use_moment_law)

class yade.wrapper.CpmPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Representation of a single interaction of the Cpm type: storage for relevant parameters.

Evolution of the contact is governed by Law2_Dem3DofGeom_CpmPhys_Cpm, that includes damage effects and chages of parameters inside CpmPhys. See cpm-model for details.

E(=NaN)

normal modulus (stiffness / crossSection) [Pa]

Fn

Magnitude of normal force.

Fs

Magnitude of shear force

G(=NaN)

shear modulus [Pa]

crossSection(=NaN)

equivalent cross-section associated with this contact [m²]

dmgOverstress(=0)

damage viscous overstress (at previous step or at current step)

dmgRateExp(=0)

exponent in the rate-dependent damage evolution

dmgStrain(=0)

damage strain (at previous or current step)

dmgTau(=-1)

characteristic time for damage (if non-positive, the law without rate-dependence is used)

epsCrackOnset(=NaN)

strain at which the material starts to behave non-linearly

epsFracture(=NaN)

strain where the damage-evolution law tangent from the top (epsCrackOnset) touches the axis; since the softening law is exponential, this doesn’t mean that the contact is fully damaged at this point, that happens only asymptotically

epsN

Current normal strain

epsNPl(=0)

normal plastic strain (initially zero)

epsPlSum(=0)

cummulative shear plastic strain measure (scalar) on this contact

epsT(=Vector3r::Zero())

Total shear strain (either computed from increments with ScGeom or simple copied with Dem3DofGeom) (auto-updated)

epsTrans(=0)

Transversal strain (perpendicular to the contact axis)

isCohesive(=false)

if not cohesive, interaction is deleted when distance is greater than zero.

isoPrestress(=0)

“prestress” of this link (used to simulate isotropic stress)

kappaD(=0)

Up to now maximum normal strain (semi-norm), non-decreasing in time.

neverDamage(=false)

the damage evolution function will always return virgin state

omega

Damage internal variable

plRateExp(=0)

exponent in the rate-dependent viscoplasticity

plTau(=-1)

characteristic time for viscoplasticity (if non-positive, no rate-dependence for shear)

relResidualStrength

Relative residual strength

sigmaN

Current normal stress

sigmaT

Current shear stress

tanFrictionAngle(=NaN)

tangens of internal friction angle [-]

undamagedCohesion(=NaN)

virgin material cohesion [Pa]

class yade.wrapper.FrictPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Interaction with friction

prevNormal(=Vector3r::Zero())

unit normal of the contact plane in previous step

tangensOfFrictionAngle(=NaN)

tan of angle of friction

class yade.wrapper.MindlinPhys(inherits FrictPhysNormShearPhysNormPhysIPhysSerializable)

Representation of an interaction of the Hertz-Mindlin type.

adhesionForce(=0.0)

Force of adhesion as predicted by DMT

betan(=0.0)

Fraction of the viscous damping coefficient (normal direction) equal to \frac{c_{n}}{C_{n,crit}}.

betas(=0.0)

Fraction of the viscous damping coefficient (shear direction) equal to \frac{c_{s}}{C_{s,crit}}.

isAdhesive(=false)

bool to identify if the contact is adhesive, that is to say if the contact force is attractive

kno(=0.0)

Constant value in the formulation of the normal stiffness

kso(=0.0)

Constant value in the formulation of the tangential stiffness

normalViscous(=Vector3r::Zero())

Normal viscous component

radius(=NaN)

Contact radius (only computed with Law2_ScGeom_MindlinPhys_Mindlin::calcEnergy)

shearElastic(=Vector3r::Zero())

Total elastic shear force

shearViscous(=Vector3r::Zero())

Shear viscous component

usElastic(=Vector3r::Zero())

Total elastic shear displacement (only elastic part)

usTotal(=Vector3r::Zero())

Total elastic shear displacement (elastic+plastic part)

class yade.wrapper.MomentPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Physical interaction properties for use with Law2_SCG_MomentPhys_CohesionlessMomentRotation, created by Ip2_MomentMat_MomentMat_MomentPhys.

Eta(=0)

??

cumulativeRotation(=0)

??

frictionAngle(=0)

Friction angle [rad]

initialOrientation1(=Quaternionr::Identity())

??

initialOrientation2(=Quaternionr::Identity())

??

kr(=0)

rolling stiffness

moment_bending(=Vector3r::Zero())

??

moment_twist(=Vector3r::Zero())

??

prevNormal(=Vector3r::Zero())

Normal in the previous step.

shear(=Vector3r::Zero())

??

tanFrictionAngle(=0)

Tangent of friction angle

class yade.wrapper.NormPhys(inherits IPhysSerializable)

Abstract class for interactions that have normal stiffness.

kn(=NaN)

Normal stiffness

normalForce(=Vector3r::Zero())

Normal force after previous step (in global coordinates).

class yade.wrapper.NormShearPhys(inherits NormPhysIPhysSerializable)

Abstract class for interactions that have shear stiffnesses, in addition to normal stiffness. This class is used in the PFC3d-style stiffness timestepper.

ks(=NaN)

Shear stiffness

shearForce(=Vector3r::Zero())

Shear force after previous step (in global coordinates).

class yade.wrapper.NormalInelasticityPhys(inherits FrictPhysNormShearPhysNormPhysIPhysSerializable)

Physics (of interaction) for using Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity : with inelastic unloadings

forMaxMoment(=1.0)

parameter stored for each interaction, and allowing to compute the maximum value of the exchanged torque : TorqueMax= forMaxMoment * NormalForce

knLower(=0.0)

the stifness corresponding to a virgin load for example

kr(=0.0)

the rolling stiffness of the interaction

moment_bending(=Vector3r(0, 0, 0))

Bending moment. Defined here, being initialized as it should be, to be used in Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity

moment_twist(=Vector3r(0, 0, 0))

Twist moment. Defined here, being initialized as it should be, to be used in Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity

previousFn(=0.0)

the value of the normal force at the last time step

previousun(=0.0)

the value of this un at the last time step

unMax(=0.0)

the maximum value of penetration depth of the history of this interaction

class yade.wrapper.RpmPhys(inherits NormShearPhysNormPhysIPhysSerializable)

Representation of a single interaction of the Cpm type: storage for relevant parameters.

Evolution of the contact is governed by Law2_Dem3DofGeom_CpmPhys_Cpm, that includes damage effects and chages of parameters inside CpmPhys

E(=NaN)

normal modulus (stiffness / crossSection) [Pa]

G(=NaN)

shear modulus [Pa]

crossSection(=0)

equivalent cross-section associated with this contact [m²]

isCohesive(=false)

if not cohesive, interaction is deleted when distance is greater than lengthMaxTension or less than lengthMaxCompression.

lengthMaxCompression(=0)

Maximal penetration of particles during compression. If it is more, the interaction is deleted [m]

lengthMaxTension(=0)

Maximal distance between particles during tension. If it is more, the interaction is deleted [m]

tanFrictionAngle(=NaN)

tangens of internal friction angle [-]

class yade.wrapper.ViscElPhys(inherits FrictPhysNormShearPhysNormPhysIPhysSerializable)

IPhys created from ViscElMat, for use with Law2_ScGeom_ViscElPhys_Basic.

cn(=NaN)

Normal viscous constant

cs(=NaN)

Shear viscous constant

Global engines

GlobalEngine

digraph GlobalEngine {
        rankdir=RL;
        margin=.2;
        "GlobalEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlobalEngine"];
        "Collider" [shape="box",fontsize=8,style="setlinewidth(0.5),filled,dashed",fillcolor=grey,height=0.2,URL="yade.wrapper.html#yade.wrapper.Collider"];
        "Collider" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "PeriodicEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PeriodicEngine"];
        "PeriodicEngine" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "BoundaryController" [shape="box",fontsize=8,style="setlinewidth(0.5),filled,dashed",fillcolor=grey,height=0.2,URL="yade.wrapper.html#yade.wrapper.BoundaryController"];
        "BoundaryController" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CapillaryStressRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CapillaryStressRecorder"];
        "CapillaryStressRecorder" -> "Recorder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ParticleSizeDistrbutionRPMRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ParticleSizeDistrbutionRPMRecorder"];
        "ParticleSizeDistrbutionRPMRecorder" -> "Recorder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Recorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Recorder"];
        "Recorder" -> "PeriodicEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ForceRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ForceRecorder"];
        "ForceRecorder" -> "Recorder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "DomainLimiter" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.DomainLimiter"];
        "DomainLimiter" -> "PeriodicEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "GlobalStiffnessTimeStepper" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlobalStiffnessTimeStepper"];
        "GlobalStiffnessTimeStepper" -> "TimeStepper" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "FacetTopologyAnalyzer" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FacetTopologyAnalyzer"];
        "FacetTopologyAnalyzer" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CpmStateUpdater" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CpmStateUpdater"];
        "CpmStateUpdater" -> "PeriodicEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "FieldApplier" [shape="box",fontsize=8,style="setlinewidth(0.5),filled,dashed",fillcolor=grey,height=0.2,URL="yade.wrapper.html#yade.wrapper.FieldApplier"];
        "FieldApplier" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CohesiveFrictionalContactLaw" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CohesiveFrictionalContactLaw"];
        "CohesiveFrictionalContactLaw" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NewtonIntegrator" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NewtonIntegrator"];
        "NewtonIntegrator" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TriaxialStateRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TriaxialStateRecorder"];
        "TriaxialStateRecorder" -> "Recorder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_CapillaryPhys_Capillarity" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_CapillaryPhys_Capillarity"];
        "Law2_ScGeom_CapillaryPhys_Capillarity" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ForceResetter" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ForceResetter"];
        "ForceResetter" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "NozzleFactory" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.NozzleFactory"];
        "NozzleFactory" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CohesiveStateRPMRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CohesiveStateRPMRecorder"];
        "CohesiveStateRPMRecorder" -> "Recorder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TimeStepper" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TimeStepper"];
        "TimeStepper" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TetraVolumetricLaw" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TetraVolumetricLaw"];
        "TetraVolumetricLaw" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "PyRunner" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PyRunner"];
        "PyRunner" -> "PeriodicEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ResetRandomPosition" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ResetRandomPosition"];
        "ResetRandomPosition" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "VTKRecorder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.VTKRecorder"];
        "VTKRecorder" -> "PeriodicEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ElasticContactLaw" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ElasticContactLaw"];
        "ElasticContactLaw" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "DragForceApplier" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.DragForceApplier"];
        "DragForceApplier" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "InteractionLoop" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.InteractionLoop"];
        "InteractionLoop" -> "GlobalEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.GlobalEngine(inherits EngineSerializable)

Engine that will generally affect the whole simulation (contrary to PartialEngine).

class yade.wrapper.CapillaryStressRecorder(inherits RecorderPeriodicEngineGlobalEngineEngineSerializable)

Records information from capillary meniscii on samples submitted to triaxial compressions. -> New formalism needs to be tested!!!

class yade.wrapper.CohesiveFrictionalContactLaw(inherits GlobalEngineEngineSerializable)

[DEPRECATED] Loop over interactions applying Law2_ScGeom_CohFrictPhys_CohesionMoment on all interactions.

Note

Use InteractionLoop and Law2_ScGeom_CohFrictPhys_CohesionMoment instead of this class for performance reasons.

always_use_moment_law(=false)

If true, use bending/twisting moments at all contacts. If false, compute moments only for cohesive contacts.

creep_viscosity(=false)

creep viscosity [Pa.s/m]. probably should be moved to Ip2_2xCohFrictMat_CohFrictPhys...

neverErase(=false)

Keep interactions even if particles go away from each other (only in case another constitutive law is in the scene, e.g. Law2_ScGeom_CapillaryPhys_Capillarity)

shear_creep(=false)

activate creep on the shear force, using CohesiveFrictionalContactLaw::creep_viscosity.

twist_creep(=false)

activate creep on the twisting moment, using CohesiveFrictionalContactLaw::creep_viscosity.

class yade.wrapper.CohesiveStateRPMRecorder(inherits RecorderPeriodicEngineGlobalEngineEngineSerializable)

Store number of cohesive contacts in RPM model to file.

numberCohesiveContacts(=0)

Number of cohesive contacts found at last run. [-]

class yade.wrapper.CpmStateUpdater(inherits PeriodicEngineGlobalEngineEngineSerializable)

Update CpmState of bodies based on state variables in CpmPhys of interactions with this bod. In particular, bodies’ colors and CpmState::normDmg depending on average damage of their interactions and number of interactions that were already fully broken and have disappeared is updated. This engine contains its own loop (2 loops, more precisely) over all bodies and should be run periodically to update colors during the simulation, if desired.

avgRelResidual(=NaN)

Average residual strength at last run.

maxOmega(=NaN)

Globally maximum damage parameter at last run.

class yade.wrapper.DomainLimiter(inherits PeriodicEngineGlobalEngineEngineSerializable)

Delete particles that are out of axis-aligned box given by lo and hi.

hi(=Vector3r(0, 0, 0))

Upper corner of the domain.

lo(=Vector3r(0, 0, 0))

Lower corner of the domain.

nDeleted(=0)

Cummulative number of particles deleted.

class yade.wrapper.DragForceApplier(inherits GlobalEngineEngineSerializable)

Apply drag force on particles, decelerating them proportionally to their linear velocities. The applied force reads

F_{d}=-\frac{\vec{v}}{|\vec{v}|}\frac{1}{2}\rho|\vec{v}|^2 C_d A

where \rho is the medium density (density), v is particle’s velocity, A is particle projected area (disc), C_d is the drag coefficient (0.47 for Sphere),

Note

Drag force is only applied to spherical particles.

density(=0)

Density of the medium.

class yade.wrapper.ElasticContactLaw(inherits GlobalEngineEngineSerializable)

[DEPRECATED] Loop over interactions applying Law2_ScGeom_FrictPhys_CundallStrack on all interactions.

Note

Use InteractionLoop and Law2_ScGeom_FrictPhys_CundallStrack instead of this class for performance reasons.

neverErase(=false)

Keep interactions even if particles go away from each other (only in case another constitutive law is in the scene, e.g. Law2_ScGeom_CapillaryPhys_Capillarity)

class yade.wrapper.FacetTopologyAnalyzer(inherits GlobalEngineEngineSerializable)

Initializer for filling adjacency geometry data for facets.

Common vertices and common edges are identified and mutual angle between facet faces is written to Facet instances. If facets don’t move with respect to each other, this must be done only at the beginng.

commonEdgesFound(=0)

how many common edges were identified during last run. (auto-updated)

commonVerticesFound(=0)

how many common vertices were identified during last run. (auto-updated)

projectionAxis(=Vector3r::UnitX())

Axis along which to do the initial vertex sort

relTolerance(=1e-4)

maximum distance of ‘identical’ vertices, relative to minimum facet size

class yade.wrapper.ForceRecorder(inherits RecorderPeriodicEngineGlobalEngineEngineSerializable)

Engine saves the resulting force affecting to Subscribed bodies. For instance, can be useful for defining the forces, which affect to _buldozer_ during its work.

ids(=uninitalized)

Lists of bodies whose state will be measured

class yade.wrapper.ForceResetter(inherits GlobalEngineEngineSerializable)

Reset all forces stored in Scene::forces (O.forces in python). Typically, this is the first engine to be run at every step. In addition, reset those energies that should be reset, if energy tracing is enabled.

class yade.wrapper.GlobalStiffnessTimeStepper(inherits TimeStepperGlobalEngineEngineSerializable)

An engine assigning the time-step as a fraction of the minimum eigen-period in the problem

defaultDt(=1)

used as default AND as max value of the timestep

previousDt(=1)

last computed dt (auto-updated)

timestepSafetyCoefficient(=0.8)

safety factor between the minimum eigen-period and the final assigned dt (less than 1))

class yade.wrapper.InteractionLoop(inherits GlobalEngineEngineSerializable)

Unified dispatcher for handling interaction loop at every step, for parallel performance reasons.

Special constructor

Constructs from 3 lists of Ig2, Ip2, Law functors respectively; they will be passed to interal dispatchers, which you might retrieve. (NOT YET DONE: Optionally, list of IntrCallbacks can be provided as fourth argument.)

callbacks(=uninitalized)

Callbacks which will be called for every Interaction, if activated.

geomDispatcher(=new IGeomDispatcher)

IGeomDispatcher object that is used for dispatch.

lawDispatcher(=new LawDispatcher)

LawDispatcher object used for dispatch.

physDispatcher(=new IPhysDispatcher)

IPhysDispatcher object used for dispatch.

class yade.wrapper.Law2_ScGeom_CapillaryPhys_Capillarity(inherits GlobalEngineEngineSerializable)

This law allows one to take into account capillary forces/effects between spheres coming from the presence of interparticular liquid bridges (menisci).

refs:
  1. in french [Scholtes2009d] (lot of documentation)
  2. in english [Scholtes2009b] (less documentation), pg. 64-75.

The law needs ascii files M(r=i) with i=R1/R2 to work (see https://yade-dem.org/index.php/CapillaryTriaxialTest). These ASCII files contain a set of results from the resolution of the Laplace-Young equation for different configurations of the interacting geometry.

The control parameter is the capillary pressure (or suction) Uc = ugas - Uliquid. Liquid bridges properties (volume V, extent over interacting grains delta1 and delta2) are computed as a result of the defined capillary pressure and of the interacting geometry (spheres radii and interparticular distance).

CapillaryPressure(=0.)

Value of the capillary pressure Uc defines as Uc=Ugas-Uliquid

binaryFusion(=true)

If true, capillary forces are set to zero as soon as, at least, 1 overlap (menisci fusion) is detected

fusionDetection(=false)

If true potential menisci overlaps are checked

class yade.wrapper.NewtonIntegrator(inherits GlobalEngineEngineSerializable)

Engine integrating newtonian motion equations.

callbacks(=uninitalized)

List (std::vector in c++) of BodyCallbacks which will be called for each body as it is being processed.

damping(=0.2)

damping coefficient for Cundall’s non viscous damping (see [Chareyre2005]) [-]

exactAsphericalRot(=true)

Enable more exact body rotation integrator for aspherical bodies only, using formulation from [Allen1989], pg. 89.

maxVelocitySq(=NaN)

store square of max. velocity, for informative purposes; computed again at every step. (auto-updated)

prevVelGrad(=Matrix3r::Zero())

Store previous velocity gradient (Cell::velGrad) to track acceleration. (auto-updated)

warnNoForceReset(=true)

Warn when forces were not resetted in this step by ForceResetter; this mostly points to ForceResetter being forgotten incidentally and should be disabled only with a good reason.

class yade.wrapper.NozzleFactory(inherits GlobalEngineEngineSerializable)

Engine for spitting spheres based on mass flow rate, particle size distribution etc. The area where spehres are generated should be circular, given by radius, center and normal. For now, axis-aligned cube-shape corresponding is used instead, centered at center and with size \frac{2\sqrt{3}}{3}. Initial velocity of particles is given by vMin, vMax, the massFlowRate determines how many particles to generate at each step. When goalMass is attained or positive maxParticles is reached, the engine does not produce particles anymore.

A sample script for this engine is in scripts/shots.py.

center(=Vector3r(NaN, NaN, NaN))

Center of the nozzle

goalMass(=0)

Total mass that should be attained at the end of the current step. (auto-updated)

massFlowRate(=NaN)

Mass flow rate [kg/s]

materialId(=-1)

Shared material id to use for newly created spheres (can be negative to count from the end)

maxAttempt(=5000)

Maximum number of attempts to position a new sphere randomly.

maxParticles(=100)

The number of particles at which to stop generating new ones (regardless of massFlowRate

normal(=Vector3r(NaN, NaN, NaN))

Spitting direction, i.e. normal of the circle where spheres are generated.

numParticles(=0)

Cummulative number of particles produces so far (auto-updated)

rMax(=NaN)

Maximum radius of generated spheres (uniform distribution)

rMin(=NaN)

Minimum radius of generated spheres (uniform distribution)

radius(=NaN)

Radius of the nozzle

totalMass(=0)

Mass of spheres that was produced so far. (auto-updated)

vAngle(=NaN)

Maximum angle by which the initial sphere velocity deviates from the nozzle normal.

vMax(=NaN)

Maximum velocity norm of generated spheres (uniform distribution)

vMin(=NaN)

Minimum velocity norm of generated spheres (uniform distribution)

class yade.wrapper.ParticleSizeDistrbutionRPMRecorder(inherits RecorderPeriodicEngineGlobalEngineEngineSerializable)

Store number of PSD in RPM model to file.

numberCohesiveContacts(=0)

Number of cohesive contacts found at last run. [-]

class yade.wrapper.PeriodicEngine(inherits GlobalEngineEngineSerializable)

Run Engine::action with given fixed periodicity real time (=wall clock time, computation time), virtual time (simulation time), iteration number), by setting any of those criteria (virtPeriod, realPeriod, iterPeriod) to a positive value. They are all negative (inactive) by default.

The number of times this engine is activated can be limited by setting nDo>0. If the number of activations will have been already reached, no action will be called even if an active period has elapsed.

If initRun is set (false by default), the engine will run when called for the first time; otherwise it will only start counting period (realLast etc interal variables) from that point, but without actually running, and will run only once a period has elapsed since the initial run.

This class should be used directly; rather, derive your own engine which you want to be run periodically.

Derived engines should override Engine::action(), which will be called periodically. If the derived Engine overrides also Engine::isActivated, it should also take in account return value from PeriodicEngine::isActivated, since otherwise the periodicity will not be functional.

Example with PyRunner, which derives from PeriodicEngine; likely to be encountered in python scripts):

PyRunner(realPeriod=5,iterPeriod=10000,command='print O.iter')  

will print iteration number every 10000 iterations or every 5 seconds of wall clock time, whiever comes first since it was last run.

initRun(=false)

Run the first time we are called as well.

iterLast(=0)

Tracks step number of last run (auto-updated).

iterPeriod(=0, deactivated)

Periodicity criterion using step number (deactivated if <= 0)

nDo(=-1, deactivated)

Limit number of executions by this number (deactivated if negative)

nDone(=0)

Track number of executions (cummulative) (auto-updated).

realLast(=0)

Tracks real time of last run (auto-updated).

realPeriod(=0, deactivated)

Periodicity criterion using real (wall clock, computation, human) time (deactivated if <=0)

virtLast(=0)

Tracks virtual time of last run (auto-updated).

virtPeriod(=0, deactivated)

Periodicity criterion using virtual (simulation) time (deactivated if <= 0)

class yade.wrapper.PyRunner(inherits PeriodicEngineGlobalEngineEngineSerializable)

Execute a python command periodically, with defined (and adjustable) periodicity. See PeriodicEngine documentation for details.

command(="")

Command to be run by python interpreter. Not run if empty.

class yade.wrapper.Recorder(inherits PeriodicEngineGlobalEngineEngineSerializable)

Engine periodically storing some data to (one) external file. In addition PeriodicEngine, it handles opening the file as needed. See PeriodicEngine for controlling periodicity.

addIterNum(=false)

Adds an iteration number to the file name, when the file was created. Useful for creating new files at each call (false by default)

file(=uninitalized)

Name of file to save to; must not be empty.

truncate(=false)

Whether to delete current file contents, if any, when opening (false by default)

class yade.wrapper.ResetRandomPosition(inherits GlobalEngineEngineSerializable)

Creates spheres during simulation, placing them at random positions. Every time called, one new sphere will be created and inserted in the simulation.

angularVelocity(=Vector3r::Zero())

Mean angularVelocity of spheres.

angularVelocityRange(=Vector3r::Zero())

Half size of a angularVelocity distribution interval. New sphere will have random angularVelocity within the range angularVelocity±angularVelocityRange.

factoryFacets(=uninitalized)

The geometry of the section where spheres will be placed; they will be placed on facets or in volume between them depending on volumeSection flag.

maxAttempts(=20)

Max attempts to place sphere. If placing the sphere in certain random position would cause an overlap with any other physical body in the model, SpheresFactory will try to find another position.

normal(=Vector3r(0, 1, 0))

??

point(=Vector3r::Zero())

??

subscribedBodies(=uninitalized)

Affected bodies.

velocity(=Vector3r::Zero())

Mean velocity of spheres.

velocityRange(=Vector3r::Zero())

Half size of a velocities distribution interval. New sphere will have random velocity within the range velocity±velocityRange.

volumeSection(=false, define factory by facets.)

Create new spheres inside factory volume rather than on its surface.

class yade.wrapper.TetraVolumetricLaw(inherits GlobalEngineEngineSerializable)

Calculate physical response of 2 tetrahedra in interaction, based on penetration configuration given by TTetraGeom.

class yade.wrapper.TimeStepper(inherits GlobalEngineEngineSerializable)

Engine defining time-step (fundamental class)

active(=true)

is the engine active?

timeStepUpdateInterval(=1)

dt update interval

class yade.wrapper.TriaxialStateRecorder(inherits RecorderPeriodicEngineGlobalEngineEngineSerializable)

Engine recording triaxial variables (see the variables list in the first line of the output file). This recorder needs TriaxialCompressionEngine or ThreeDTriaxialEngine present in the simulation).

porosity(=1)

porosity of the packing [-]

class yade.wrapper.VTKRecorder(inherits PeriodicEngineGlobalEngineEngineSerializable)

Engine recording snapshots of simulation into series of *.vtu files, readable by VTK-based postprocessing programs such as Paraview. Both bodies (spheres and facets) and interactions can be recorded, with various vector/scalar quantities that are defined on them.

PeriodicEngine.initRun is initialized to True automatically.

ascii(=false)

Store data as readable text in the XML file (sets vtkXMLWriter data mode to vtkXMLWriter::Ascii, while the default is Appended

compress(=false)

Compress output XML files [experimental].

fileName(="")

Base file name; it will be appended with {spheres,intrs,facets}-243100.vtu (unless multiblock is True) depending on active recorders and step number (243100 in this case). It can contain slashes, but the directory must exist already.

mask(=0)

If mask defined, only bodies with corresponding groupMask will be exported. If 0, all bodies will be exported.

recorders

List of active recorders (as strings). all (the default value) enables all base and generic recorders.

Base recorders

Base recorders save the geometry (unstructured grids) on which other data is defined. They are implicitly activated by many of the other recorders. Each of them creates a new file (or a block, if multiblock is set).

spheres
Saves positions and radii (radii) of spherical particles.
facets
Save facets positions (vertices).
intr
Store interactions as lines between nodes at respective particles positions. Additionally stores magnitude of normal (forceN) and shear (absForceT) forces on interactions (the geom).

Generic recorders

Generic recorders do not depend on specific model being used and save commonly useful data.

id
Saves id’s (field id) of spheres; active only if spheres is active.
clumpId
Saves id’s of clumps to which each sphere belongs (field clumpId); active only if spheres is active.
colors
Saves colors of spheres and of facets (field color); only active if spheres or facets are activated.
mask
Saves groupMasks of spheres and of facets (field mask); only active if spheres or facets are activated.
materialId
Saves materialID of spheres and of facets; only active if spheres or facets are activated.
velocity
Saves linear and angular velocities of spherical particles as Vector3 and length(fields linVelVec, linVelLen and angVelVec, angVelLen respectively``); only effective with spheres.
stress
Saves stresses of spheres and of facets as Vector3 and length; only active if spheres or facets are activated.

Specific recorders

The following should only be activated in appropriate cases, otherwise crashes can occur due to violation of type presuppositions.

cpm
Saves data pertaining to the concrete model: cpmDamage (normalized residual strength averaged on particle), cpmSigma (stress on particle, normal components), cpmTau (shear components of stress on particle), cpmSigmaM (mean stress around particle); intr is activated automatically by cpm
rpm
Saves data pertaining to the rock particle model: rpmSpecNum shows different pieces of separated stones, only ids. rpmSpecMass shows masses of separated stones.

skipFacetIntr(=true)

Skip interactions with facets, when saving interactions

skipNondynamic(=false)

Skip non-dynamic spheres (but not facets).

BoundaryController

digraph BoundaryController {
        rankdir=RL;
        margin=.2;
        "BoundaryController" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.BoundaryController"];
        "Disp2DPropLoadEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Disp2DPropLoadEngine"];
        "Disp2DPropLoadEngine" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Peri3dController" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Peri3dController"];
        "Peri3dController" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "PeriIsoCompressor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PeriIsoCompressor"];
        "PeriIsoCompressor" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "KinemCTDEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.KinemCTDEngine"];
        "KinemCTDEngine" -> "KinemSimpleShearBox" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "KinemCNSEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.KinemCNSEngine"];
        "KinemCNSEngine" -> "KinemSimpleShearBox" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TriaxialCompressionEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TriaxialCompressionEngine"];
        "TriaxialCompressionEngine" -> "TriaxialStressController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "KinemCNLEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.KinemCNLEngine"];
        "KinemCNLEngine" -> "KinemSimpleShearBox" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "UniaxialStrainer" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.UniaxialStrainer"];
        "UniaxialStrainer" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ThreeDTriaxialEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ThreeDTriaxialEngine"];
        "ThreeDTriaxialEngine" -> "TriaxialStressController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "PeriTriaxController" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PeriTriaxController"];
        "PeriTriaxController" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TriaxialStressController" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TriaxialStressController"];
        "TriaxialStressController" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "KinemCNDEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.KinemCNDEngine"];
        "KinemCNDEngine" -> "KinemSimpleShearBox" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "KinemSimpleShearBox" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.KinemSimpleShearBox"];
        "KinemSimpleShearBox" -> "BoundaryController" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "SampleCapillaryPressureEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.SampleCapillaryPressureEngine"];
        "SampleCapillaryPressureEngine" -> "TriaxialStressController" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.BoundaryController(inherits GlobalEngineEngineSerializable)

Base for engines controlling boundary conditions of simulations. Not to be used directly.

class yade.wrapper.Disp2DPropLoadEngine(inherits BoundaryControllerGlobalEngineEngineSerializable)

Disturbs a simple shear sample in a given displacement direction

This engine allows one to apply, on a simple shear sample, a loading controlled by du/dgamma = cste, which is equivalent to du + cste’ * dgamma = 0 (proportionnal path loadings). To do so, the upper plate of the simple shear box is moved in a given direction (corresponding to a given du/dgamma), whereas lateral plates are moved so that the box remains closed. This engine can easily be used to perform directionnal probes, with a python script launching successivly the same .xml which contains this engine, after having modified the direction of loading (see theta attribute). That’s why this Engine contains a saveData procedure which can save data on the state of the sample at the end of the loading (in case of successive loadings - for successive directions - through a python script, each line would correspond to one direction of loading).

Key(="")

string to add at the names of the saved files, and of the output file filled by saveData

LOG(=false)

boolean controling the output of messages on the screen

id_boxback(=4)

the id of the wall at the back of the sample

id_boxbas(=1)

the id of the lower wall

id_boxfront(=5)

the id of the wall in front of the sample

id_boxleft(=0)

the id of the left wall

id_boxright(=2)

the id of the right wall

id_topbox(=3)

the id of the upper wall

nbre_iter(=0)

the number of iterations of loading to perform

theta(=0.0)

the angle, in a (gamma,h=-u) plane from the gamma - axis to the perturbation vector (trigo wise) [degrees]

v(=0.0)

the speed at which the perturbation is imposed. In case of samples which are more sensitive to normal loadings than tangential ones, one possibility is to take v = V_shear - | (V_shear-V_comp)*sin(theta) | => v=V_shear in shear; V_comp in compression [m/s]

class yade.wrapper.KinemCNDEngine(inherits KinemSimpleShearBoxBoundaryControllerGlobalEngineEngineSerializable)

To apply a Constant Normal Displacement (CND) shear for a parallelogram box

This engine, designed for simulations implying a simple shear box (SimpleShear Preprocessor or scripts/simpleShear.py), allows one to perform a constant normal displacement shear, by translating horizontally the upper plate, while the lateral ones rotate so that they always keep contact with the lower and upper walls.

gamma(=0.0)

the current value of the tangential displacement

gamma_save(=uninitalized)

vector with the values of gamma at which a save of the simulation is performed [m]

gammalim(=0.0)

the value of the tangential displacement at wich the displacement is stopped [m]

shearSpeed(=0.0)

the speed at which the shear is performed : speed of the upper plate [m/s]

class yade.wrapper.KinemCNLEngine(inherits KinemSimpleShearBoxBoundaryControllerGlobalEngineEngineSerializable)

To apply a constant normal stress shear (i.e. Constant Normal Load : CNL) for a parallelogram box (simple shear box : SimpleShear Preprocessor or scripts/simpleShear.py)

This engine allows one to translate horizontally the upper plate while the lateral ones rotate so that they always keep contact with the lower and upper walls.

In fact the upper plate can move not only horizontally but also vertically, so that the normal stress acting on it remains constant (this constant value is not chosen by the user but is the one that exists at the beginning of the simulation)

The right vertical displacements which will be allowed are computed from the rigidity Kn of the sample over the wall (so to cancel a deltaSigma, a normal dplt deltaSigma*S/(Kn) is set)

The movement is moreover controlled by the user via a shearSpeed which will be the speed of the upper wall, and by a maximum value of horizontal displacement gammalim, after which the shear stops.

Note

Not only the positions of walls are updated but also their speeds, which is all but useless considering the fact that in the contact laws these velocities of bodies are used to compute values of tangential relative displacements.

Warning

Because of this last point, if you want to use later saves of simulations executed with this Engine, but without that stopMovement was executed, your boxes will keep their speeds => you will have to cancel them ‘by hand’ in the .xml.

gamma(=0.0)

current value of tangential displacement [m]

gamma_save(=uninitalized)

vector with the values of gamma at which a save of the simulation is performed [m]

gammalim(=0.0)

the value of tangential displacement (of upper plate) at wich the shearing is stopped [m]

shearSpeed(=0.0)

the speed at wich the shearing is performed : speed of the upper plate [m/s]

class yade.wrapper.KinemCNSEngine(inherits KinemSimpleShearBoxBoundaryControllerGlobalEngineEngineSerializable)

To apply a Constant Normal Stifness (CNS) shear for a parallelogram box (simple shear)

This engine, useable in simulations implying one deformable parallelepipedic box, allows one to translate horizontally the upper plate while the lateral ones rotate so that they always keep contact with the lower and upper walls. The upper plate can move not only horizontally but also vertically, so that the normal rigidity defined by DeltaF(upper plate)/DeltaU(upper plate) = constant (= KnC defined by the user).

The movement is moreover controlled by the user via a shearSpeed which is the horizontal speed of the upper wall, and by a maximum value of horizontal displacement gammalim (of the upper plate), after which the shear stops.

Note

not only the positions of walls are updated but also their speeds, which is all but useless considering the fact that in the contact laws these velocities of bodies are used to compute values of tangential relative displacements.

Warning

But, because of this last point, if you want to use later saves of simulations executed with this Engine, but without that stopMovement was executed, your boxes will keep their speeds => you will have to cancel them by hand in the .xml

KnC(=10.0e6)

the normal rigidity chosen by the user [MPa/mm] - the conversion in Pa/m will be made

gamma(=0.0)

current value of tangential displacement [m]

gammalim(=0.0)

the value of tangential displacement (of upper plate) at wich the shearing is stopped [m]

shearSpeed(=0.0)

the speed at wich the shearing is performed : speed of the upper plate [m/s]

class yade.wrapper.KinemCTDEngine(inherits KinemSimpleShearBoxBoundaryControllerGlobalEngineEngineSerializable)

To compress a simple shear sample by moving the upper box in a vertical way only, so that the tangential displacement (defined by the horizontal gap between the upper and lower boxes) remains constant (thus, the CTD = Constant Tangential Displacement). The lateral boxes move also to keep always contact. All that until this box is submitted to a given stress (=*targetSigma*). Moreover saves are executed at each value of stresses stored in the vector sigma_save, and at targetSigma

compSpeed(=0.0)

(vertical) speed of the upper box : >0 for real compression, <0 for unloading [m/s]

sigma_save(=uninitalized)

vector with the values of sigma at which a save of the simulation should be performed [kPa]

targetSigma(=0.0)

the value of sigma at which the compression should stop [kPa]

class yade.wrapper.KinemSimpleShearBox(inherits BoundaryControllerGlobalEngineEngineSerializable)

This class is supposed to be a mother class for all Engines performing loadings on the simple shear box of SimpleShear. It is not intended to be used by itself, but its declaration and implentation will thus contain all what is useful for all these Engines. The script simpleShear.py illustrates the use of the various corresponding Engines.

Key(="")

string to add at the names of the saved files

LOG(=false)

boolean controling the output of messages on the screen

alpha(=Mathr::PI/2.0)

the angle from the lower box to the left box (trigo wise). Measured by this Engine, not to be changed by the user.

f0(=0.0)

the (vertical) force acting on the upper plate on the very first time step (determined by the Engine). Controls of the loadings in case of KinemCNSEngine or KinemCNLEngine will be done according to this initial value [N]. Not to be changed by the user.]

firstRun(=true)

boolean set to false as soon as the engine has done its job one time : useful to know if initial height of, and normal force sustained by, the upper box are known or not (and thus if they have to be initialized). Not to be changed by the user.

id_boxback(=4)

the id of the wall at the back of the sample

id_boxbas(=1)

the id of the lower wall

id_boxfront(=5)

the id of the wall in front of the sample

id_boxleft(=0)

the id of the left wall

id_boxright(=2)

the id of the right wall

id_topbox(=3)

the id of the upper wall

max_vel(=1.0)

to limit the speed of the vertical displacements done to control \sigma (CNL or CNS cases) [m/s]

temoin_save(=uninitalized)

vector (same length as ‘gamma_save’ for ex), with 0 or 1 depending whether the save for the corresponding value of gamma has been done (1) or not (0). Not to be changed by the user.

wallDamping(=0.2)

the vertical displacements done to to control \sigma (CNL or CNS cases) are in fact damped, through this wallDamping

y0(=0.0)

the height of the upper plate at the very first time step : the engine finds its value [m]. Not to be changed by the user.

class yade.wrapper.Peri3dController(inherits BoundaryControllerGlobalEngineEngineSerializable)

Class for controlling independently all 6 components of “engineering” stress and strain of periodic :yref:``Cell`. goal are the goal values, while stressMask determines which components prescribe stress and which prescribe strain.

If the strain is prescribed, appropeiate strain rate is directly applied. If the stress is prescribed, the strain predictor is used: from stress values in two previous steps the value of strain rate is prescribed so as the value of stress in the next step is as close as possible to the ideal one. Current algorithm is extremly simple and probably will be changed in future, but is roboust enough and mostly works fine.

Stress error (difference between actual and ideal stress) is evaluated in current and previous steps (\mathrm{d}\sigma_i,\mathrm{d}\sigma_{i-1}. Linear extrapolation is used to estimate error in the next step

\mathrm{d}\sigma_{i+1}=2\mathrm{d}\sigma_i - \mathrm{d}\sigma_{i-1}

According to this error, the strain rate is modified by mod parameter

\mathrm{d}\sigma_{i+1}\left\{\begin{array}{c} >0 \rightarrow \dot{\varepsilon}_{i+1} = \dot{\varepsilon}_i - \max(\mathrm{abs}(\dot{\boldsymbol{\varepsilon}}_i))\cdot\mathrm{mod} \\ <0 \rightarrow \dot{\varepsilon}_{i+1} = \dot{\varepsilon}_i + \max(\mathrm{abs}(\dot{\boldsymbol{\varepsilon}}_i))\cdot\mathrm{mod} \end{array}\right.

According to this fact, the prescribed stress will (almost) never have exact prescribed value, but the difference would be very small (and decreasing for increasing nSteps. This approach works good if one of the dominant strain rates is prescribed. If all stresses are prescribed or if all goal strains is prescribed as zero, a good estimation is needed for the first step, therefore the compliance matrix is estimated (from user defined estimations of macroscopic material parameters youngEstimation and poissonEstimation) and respective strain rates is computed form prescribed stress rates and compliance matrix (the estimation of compliance matrix could be computed autamatically avoiding user inputs of this kind).

The simulation on rotated periodic cell is also supported. Firstly, the polar decomposition is performed on cell’s transformation matrix trsf \mathcal{T}=\mat{U}\mat{P}, where \mat{U} is orthogonal (unitary) matrix representing rotation and \mat{P} is a positive semi-definite Hermitian matrix representing strain. A logarithm of \mat{P} should be used to obtain realistic values at higher strain values (not implemented yet). A prescribed strain increment in global coordinates \mathrm{d}t\cdot\dot{\boldsymbol{\varepsilon}} is properly rotated to cell’s local coordinates and added to \mat{P}

\mat{P}_{i+1}=\mat{P}+\mat{U}^{\mathsf{T}}\mathrm{d}t\cdot\dot{\boldsymbol{\varepsilon}}\mat{U}

The new value of trsf is computed at \mat{T}_{i+1}=\mat{UP}_{i+1}. From current and next trsf the cell’s velocity gradient velGrad is computed (according to its definition) as

\mat{V} = (\mat{T}_{i+1}\mat{T}^{-1}-\mat{I})/\mathrm{d}t

Current implementation allow user to define independent loading “path” for each prescribed component. i.e. define the prescribed value as a function of time (or progress or steps). See Paths.

Examples scripts/test/peri3dController_example1 and scripts/test/peri3dController_triaxialCompression explain usage and inputs of Peri3dController, scripts/test/peri3dController_shear is an example of using shear components and also simulation on rotatd cell.

doneHook(=uninitalized)

Python command (as string) to run when nSteps is achieved. If empty, the engine will be set dead.

goal(=Vector6r::Zero())

Goal state; only the upper triangular matrix is considered; each component is either prescribed stress or strain, depending on stressMask.

maxStrain(=1e6)

Maximal asolute value of strain allowed in the simulation. If reached, the simulation is considered as finished

maxStrainRate(=1e3)

Maximal absolute value of strain rate (both normal and shear components of strain)

mod(=.1)

Predictor modificator, by trail-and-error analysis the value 0.1 was found as the best.

nSteps(=1000)

Number of steps of the simulation.

poissonEstimation(=.25)

Estimation of macroscopic Poisson’s ratio, used used for the first simulation step

progress(=0.)

Actual progress of the simulation with Controller.

strain(=Vector6r::Zero())

Current strain (deformation) vector (\varepsilon_x,\varepsilon_y,\varepsilon_z,\gamma_{yz},\gamma_{zx},\gamma_{xy}) (auto-updated).

strainRate(=Vector6r::Zero())

Current strain rate vector.

stress(=Vector6r::Zero())

Current stress vector (\sigma_x,\sigma_y,\sigma_z,\tau_{yz},\tau_{zx},\tau_{xy})|yupdate|.

stressIdeal(=Vector6r::Zero())

Ideal stress vector at current time step.

stressMask(=0, all strains)

mask determining whether components of goal are strain (0) or stress (1). The order is 00,11,22,12,02,01 from the least significant bit. (e.g. 0b000011 is stress 00 and stress 11).

stressRate(=Vector6r::Zero())

Current stress rate vector (that is prescribed, the actual one slightly differ).

xxPath

“Time function” (piecewise linear) for xx direction. Sequence of couples of numbers. First number is time, second number desired value of respective quantity (stress or strain). The last couple is considered as final state (equal to (nSteps, goal)), other values are relative to this state.

Example: nSteps=1000, goal[0]=300, xxPath=((2,3),(4,1),(5,2))

at step 400 (=5*1000/2) the value is 450 (=3*300/2),

at step 800 (=4*1000/5) the value is 150 (=1*300/2),

at step 1000 (=5*1000/5=nSteps) the value is 300 (=2*300/2=goal[0]).

See example scripts/test/peri3dController_example1 for illusration.

xyPath(=vector<Vector2r>(1, Vector2r::Ones()))

Time function for xy direction, see xxPath

youngEstimation(=1e20)

Estimation of macroscopic Young’s modulus, used for the first simulation step

yyPath(=vector<Vector2r>(1, Vector2r::Ones()))

Time function for yy direction, see xxPath

yzPath(=vector<Vector2r>(1, Vector2r::Ones()))

Time function for yz direction, see xxPath

zxPath(=vector<Vector2r>(1, Vector2r::Ones()))

Time function for zx direction, see xxPath

zzPath(=vector<Vector2r>(1, Vector2r::Ones()))

Time function for zz direction, see xxPath

class yade.wrapper.PeriIsoCompressor(inherits BoundaryControllerGlobalEngineEngineSerializable)

Compress/decompress cloud of spheres by controlling periodic cell size until it reaches prescribed average stress, then moving to next stress value in given stress series.

charLen(=-1.)

Characteristic length, should be something like mean particle diameter (default -1=invalid value))

currUnbalanced

Current value of unbalanced force

doneHook(="")

Python command to be run when reaching the last specified stress

globalUpdateInt(=20)

how often to recompute average stress, stiffness and unbalanced force

keepProportions(=true)

Exactly keep proportions of the cell (stress is controlled based on average, not its components

maxSpan(=-1.)

Maximum body span in terms of bbox, to prevent periodic cell getting too small. (auto-computed)

maxUnbalanced(=1e-4)

if actual unbalanced force is smaller than this number, the packing is considered stable,

sigma

Current stress value

state(=0)

Where are we at in the stress series

stresses(=uninitalized)

Stresses that should be reached, one after another

class yade.wrapper.PeriTriaxController(inherits BoundaryControllerGlobalEngineEngineSerializable)

Engine for independently controlling stress or strain in periodic simulations.

strainStress contains absolute values for the controlled quantity, and stressMask determines meaning of those values (0 for strain, 1 for stress): e.g. ( 1<<0 | 1<<2 ) = 1 | 4 = 5 means that strainStress[0] and strainStress[2] are stress values, and strainStress[1] is strain.

See scripts/test/periodic-triax.py for a simple example.

absStressTol(=1e3)

Absolute stress tolerance

currUnbalanced(=NaN)

current unbalanced force (updated every globUpdate) (auto-updated)

doneHook(=uninitalized)

python command to be run when the desired state is reached

dynCell(=false)

Imposed stress can be controlled using the packing stiffness or by applying the laws of dynamic (dynCell=true). Don’t forget to assign a mass to the cell (PeriTriaxController->mass).

externalWork(=0)

Work input from boundary controller.

globUpdate(=5)

How often to recompute average stress, stiffness and unbalaced force.

goal

Desired stress or strain values (depending on stressMask), strains defined as strain(i)=log(Fii).

Warning

Strains are relative to the O.cell.refSize (reference cell size), not the current one (e.g. at the moment when the new strain value is set).

growDamping(=.25)

Damping of cell resizing (0=perfect control, 1=no control at all); see also wallDamping in TriaxialStressController.

mass(=NaN)

mass of the cell (user set)

maxBodySpan(=Vector3r::Zero())

maximum body dimension (auto-computed)

maxStrainRate(=Vector3r(1, 1, 1))

Maximum strain rate of the periodic cell.

maxUnbalanced(=1e-4)

maximum unbalanced force.

prevGrow(=Vector3r::Zero())

previous cell grow

relStressTol(=3e-5)

Relative stress tolerance

reversedForces(=false)

For broken constitutive laws, normalForce and shearForce on interactions are in the reverse sense. see bugreport

stiff(=Vector3r::Zero())

average stiffness (only every globUpdate steps recomputed from interactions) (auto-updated)

strain(=Vector3r::Zero())

cell strain (auto-updated)

strainRate(=Vector3r::Zero())

cell strain rate (auto-updated)

stress(=Vector3r::Zero())

diagonal terms of the stress tensor

stressMask(=0, all strains)

mask determining strain/stress (0/1) meaning for goal components

stressTensor(=Matrix3r::Zero())

average stresses, updated at every step (only every globUpdate steps recomputed from interactions if !dynCell)

class yade.wrapper.SampleCapillaryPressureEngine(inherits TriaxialStressControllerBoundaryControllerGlobalEngineEngineSerializable)

Rk: this engine has to be tested withthe new formalism. It produces the isotropic compaction of an assembly and allows one to controlled the capillary pressure inside (uses Law2_ScGeom_CapillaryPhys_Capillarity).

Pressure(=0)

Value of the capillary pressure Uc=Ugas-Uliquid (see Law2_ScGeom_CapillaryPhys_Capillarity). [Pa]

PressureVariation(=0)

Variation of the capillary pressure (each iteration). [Pa]

SigmaPrecision(=0.001)

tolerance in terms of mean stress to consider the packing as stable

StabilityCriterion(=0.01)

tolerance in terms of :yref:’TriaxialCompressionEngine::UnbalancedForce’ to consider the packing as stable

UnbalancedForce(=1)

mean resultant forces divided by mean contact force

binaryFusion(=1)

If yes, capillary force are set to 0 when, at least, 1 overlap is detected for a meniscus. If no, capillary force is divided by the number of overlaps.

fusionDetection(=1)

Is the detection of menisci overlapping activated?

pressureVariationActivated(=1)

Is the capillary pressure varying?

class yade.wrapper.ThreeDTriaxialEngine(inherits TriaxialStressControllerBoundaryControllerGlobalEngineEngineSerializable)

The engine perform a triaxial compression with a control in direction ‘i’ in stress (if stressControl_i) else in strain.

For a stress control the imposed stress is specified by ‘sigma_i’ with a ‘max_veli’ depending on ‘strainRatei’. To obtain the same strain rate in stress control than in strain control you need to set ‘wallDamping = 0.8’. For a strain control the imposed strain is specified by ‘strainRatei’. With this engine you can also perform internal compaction by growing the size of particles by using TriaxialStressController::controlInternalStress. For that, just switch on ‘internalCompaction=1’ and fix sigma_iso=value of mean pressure that you want at the end of the internal compaction.

Key(="")

A string appended at the end of all files, use it to name simulations.

UnbalancedForce(=1)

mean resultant forces divided by mean contact force

currentStrainRate1(=0)

current strain rate in direction 1 - converging to :yref:’ThreeDTriaxialEngine::strainRate1’ (./s)

currentStrainRate2(=0)

current strain rate in direction 2 - converging to :yref:’ThreeDTriaxialEngine::strainRate2’ (./s)

currentStrainRate3(=0)

current strain rate in direction 3 - converging to :yref:’ThreeDTriaxialEngine::strainRate3’ (./s)

frictionAngleDegree(=-1)

Value of friction used in the simulation if (updateFrictionAngle)

setContactProperties((float)arg2) → None

Assign a new friction angle (degrees) to dynamic bodies and relative interactions

strainRate1(=0)

target strain rate in direction 1 (./s)

strainRate2(=0)

target strain rate in direction 2 (./s)

strainRate3(=0)

target strain rate in direction 3 (./s)

stressControl_1(=true)

Switch to choose a stress or a strain control in directions 1

stressControl_2(=true)

Switch to choose a stress or a strain control in directions 2

stressControl_3(=true)

Switch to choose a stress or a strain control in directions 3

updateFrictionAngle(=false)

Switch to activate the update of the intergranular frictionto the value :yref:’ThreeDTriaxialEngine::frictionAngleDegree

class yade.wrapper.TriaxialCompressionEngine(inherits TriaxialStressControllerBoundaryControllerGlobalEngineEngineSerializable)

The engine is a state machine with the following states; transitions my be automatic, see below.

  1. STATE_ISO_COMPACTION: isotropic compaction (compression) until the prescribed mean pressue sigmaIsoCompaction is reached and the packing is stable. The compaction happens either by straining the walls (!internalCompaction) or by growing size of grains (internalCompaction).

  2. STATE_ISO_UNLOADING: isotropic unloading from the previously reached state, until the mean pressure sigmaLateralConfinement is reached (and stabilizes).

    Note

    this state will be skipped if sigmaLateralConfinement == sigmaIsoCompaction.

  3. STATE_TRIAX_LOADING: confined uniaxial compression: constant sigmaLateralConfinement is kept at lateral walls (left, right, front, back), while top and bottom walls load the packing in their axis (by straining), until the value of epsilonMax (deformation along the loading axis) is reached. At this point, the simulation is stopped.

  4. STATE_FIXED_POROSITY_COMPACTION: isotropic compaction (compression) until a chosen porosity value (parameter:fixedPorosity). The six walls move with a chosen translation speed (parameter StrainRate).

  5. STATE_TRIAX_LIMBO: currently unused, since simulation is hard-stopped in the previous state.

Transition from COMPACTION to UNLOADING is done automatically if autoUnload==true;

Transition from (UNLOADING to LOADING) or from (COMPACTION to LOADING: if UNLOADING is skipped) is done automatically if autoCompressionActivation=true; Both autoUnload and autoCompressionActivation are true by default.

Note

This engine handles many different manipulations, including some save/reload with attributes modified manually in between. Please don’t modify the algorithms, even if they look strange (especially test sequences) without notifying me and getting explicit approval. A typical situation is somebody generates a sample with !autoCompressionActivation and run : he wants a saved simulation at the end. He then reload the saved state, modify some parameters, set autoCompressionActivation=true, and run. He should get the compression test done.

Key(="")

A string appended at the end of all files, use it to name simulations.

StabilityCriterion(=0.001)

tolerance in terms of TriaxialCompressionEngine::UnbalancedForce to consider the packing is stable

UnbalancedForce(=1)

mean resultant forces divided by mean contact force

autoCompressionActivation(=true)

Auto-switch from isotropic compaction (or unloading state if sigmaLateralConfinement<sigmaIsoCompaction) to deviatoric loading

autoStopSimulation(=true)

Stop the simulation when the sample reach STATE_LIMBO, or keep running

autoUnload(=true)

Auto-switch from isotropic compaction to unloading

currentState(=1)

There are 5 possible states in which TriaxialCompressionEngine can be. See above wrapper.TriaxialCompressionEngine

currentStrainRate(=0)

current strain rate - converging to TriaxialCompressionEngine::strainRate (./s)

epsilonMax(=0.5)

Value of axial deformation for which the loading must stop

fixedPoroCompaction(=false)

A special type of compaction with imposed final porosity TriaxialCompressionEngine::fixedPorosity (WARNING : can give unrealistic results!)

fixedPorosity(=0)

Value of porosity chosen by the user

frictionAngleDegree(=-1)

Value of friction assigned just before the deviatoric loading

maxStress(=0)

Max value of stress during the simulation (for post-processing)

noFiles(=false)

If true, no files will be generated (*.xml, *.spheres,...)

previousSigmaIso(=1)

Previous value of inherited sigma_iso (used to detect manual changes of the confining pressure)

previousState(=1)

Previous state (used to detect manual changes of the state in .xml)

setContactProperties((float)arg2) → None

Assign a new friction angle (degrees) to dynamic bodies and relative interactions

sigmaIsoCompaction(=1)

Prescribed isotropic pressure during the compaction phase

sigmaLateralConfinement(=1)

Prescribed confining pressure in the deviatoric loading; might be different from TriaxialCompressionEngine::sigmaIsoCompaction

strainRate(=0)

target strain rate (./s)

testEquilibriumInterval(=20)

interval of checks for transition between phases, higher than 1 saves computation time.

translationAxis(=TriaxialStressController::normal[wall_bottom_id])

compression axis

uniaxialEpsilonCurr(=1)

Current value of axial deformation during confined loading (is reference to strain[1])

class yade.wrapper.TriaxialStressController(inherits BoundaryControllerGlobalEngineEngineSerializable)

An engine maintaining constant stresses on some boundaries of a parallepipedic packing.

boxVolume

Total packing volume.

computeStressStrainInterval(=10)

depth(=0)

depth0(=0)

externalWork(=0)

Energy provided by boundaries.

finalMaxMultiplier(=1.00001)

max multiplier of diameters during internal compaction (secondary precise adjustment - TriaxialStressController::maxMultiplier is used in the initial stage)

height(=0)

height0(=0)

internalCompaction(=true)

Switch between ‘external’ (walls) and ‘internal’ (growth of particles) compaction.

isAxisymetric(=true)

if true, sigma_iso is assigned to sigma1, 2 and 3 (applies at each iteration and overrides user-set values of s1,2,3)

maxMultiplier(=1.001)

max multiplier of diameters during internal compaction (initial fast increase - TriaxialStressController::finalMaxMultiplier is used in a second stage)

max_vel(=0.001)

Maximum allowed walls velocity [m/s]. This value superseeds the one assigned by the stress controller if the later is higher. max_vel can be set to infinity in many cases, but sometimes helps stabilizing packings. Based on this value, different maxima are computed for each axis based on the dimensions of the sample, so that if each boundary moves at its maximum velocity, the strain rate will be isotropic (see e.g. TriaxialStressController::max_vel1).

max_vel1

see TriaxialStressController::max_vel (auto-computed)

max_vel2

see TriaxialStressController::max_vel (auto-computed)

max_vel3

see TriaxialStressController::max_vel (auto-computed)

meanStress(=0)

Mean stress in the packing.

porosity

Porosity of the packing.

previousMultiplier(=1)

previousStress(=0)

radiusControlInterval(=10)

sigma1(=0)

prescribed stress on axis 1 (see TriaxialStressController::isAxisymetric)

sigma2(=0)

prescribed stress on axis 2 (see TriaxialStressController::isAxisymetric)

sigma3(=0)

prescribed stress on axis 3 (see TriaxialStressController::isAxisymetric)

sigma_iso(=0)

prescribed confining stress (see TriaxialStressController::isAxisymetric)

spheresVolume

Total volume pf spheres.

stiffnessUpdateInterval(=10)

target strain rate (./s)

strain

Current strain (logarithmic).

stress((int)id) → Vector3

Return the mean stress vector acting on boundary ‘id’, with ‘id’ between 0 and 5.

thickness(=-1)

volumetricStrain(=0)

Volumetric strain (see TriaxialStressController::strain).

wallDamping(=0.25)

wallDamping coefficient - wallDamping=0 implies a (theoretical) perfect control, wallDamping=1 means no movement

wall_back_activated(=true)

wall_back_id(=0)

id of boundary ; coordinate 2-

wall_bottom_activated(=true)

wall_bottom_id(=0)

id of boundary ; coordinate 1-

wall_front_activated(=true)

wall_front_id(=0)

id of boundary ; coordinate 2+

wall_left_activated(=true)

wall_left_id(=0)

id of boundary ; coordinate 0-

wall_right_activated(=true)

wall_right_id(=0)

id of boundary ; coordinate 0+

wall_top_activated(=true)

wall_top_id(=0)

id of boundary ; coordinate 1+

width(=0)

width0(=0)

class yade.wrapper.UniaxialStrainer(inherits BoundaryControllerGlobalEngineEngineSerializable)

Axial displacing two groups of bodies in the opposite direction with given strain rate.

absSpeed(=NaN)

alternatively, absolute speed of boundary motion can be specified; this is effective only at the beginning and if strainRate is not set; changing absSpeed directly during simulation wil have no effect. [ms⁻¹]

active(=true)

Whether this engine is activated

asymmetry(=0, symmetric)

If 0, straining is symmetric for negIds and posIds; for 1 (or -1), only posIds are strained and negIds don’t move (or vice versa)

avgStress(=0)

Current average stress (auto-updated) [Pa]

axis(=2)

The axis which is strained (0,1,2 for x,y,z)

blockDisplacements(=false)

Whether displacement of boundary bodies perpendicular to the strained axis are blocked of are free

blockRotations(=false)

Whether rotations of boundary bodies are blocked.

crossSectionArea(=NaN)

crossSection perpendicular to he strained axis; must be given explicitly [m²]

currentStrainRate(=NaN)

Current strain rate (update automatically). (auto-updated)

idleIterations(=0)

Number of iterations that will pass without straining activity after stopStrain has been reached

initAccelTime(=-200)

Time for strain reaching the requested value (linear interpolation). If negative, the time is dt*(-initAccelTime), where dt is the timestep at the first iteration. [s]

limitStrain(=0, disabled)

Invert the sense of straining (sharply, without transition) one this value of strain is reached. Not effective if 0.

negIds(=uninitalized)

Bodies on which strain will be applied (on the negative end along the axis)

notYetReversed(=true)

Flag whether the sense of straining has already been reversed (only used internally).

originalLength(=NaN)

Distance of reference bodies in the direction of axis before straining started (computed automatically) [m]

posIds(=uninitalized)

Bodies on which strain will be applied (on the positive end along the axis)

setSpeeds(=false)

should we set speeds at the beginning directly, instead of increasing strain rate progressively?

stopStrain(=NaN)

Strain at which we will pause simulation; inactive (nan) by default; must be reached from below (in absolute value)

strain(=0)

Current strain value, elongation/originalLength (auto-updated) [-]

strainRate(=NaN)

Rate of strain, starting at 0, linearly raising to strainRate. [-]

stressUpdateInterval(=10)

How often to recompute stress on supports.

Collider

digraph Collider {
        rankdir=RL;
        margin=.2;
        "Collider" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Collider"];
        "SpatialQuickSortCollider" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.SpatialQuickSortCollider"];
        "SpatialQuickSortCollider" -> "Collider" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "FlatGridCollider" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FlatGridCollider"];
        "FlatGridCollider" -> "Collider" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "InsertionSortCollider" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.InsertionSortCollider"];
        "InsertionSortCollider" -> "Collider" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.Collider(inherits GlobalEngineEngineSerializable)

Abstract class for finding spatial collisions between bodies.

Special constructor

Derived colliders (unless they override pyHandleCustomCtorArgs) can be given list of BoundFunctors which is used to initialize the internal boundDispatcher instance.

boundDispatcher(=new BoundDispatcher)

BoundDispatcher object that is used for creating bounds on collider’s request as necessary.

class yade.wrapper.FlatGridCollider(inherits ColliderGlobalEngineEngineSerializable)

Non-optimized grid collider, storing grid as dense flat array. Each body is assigned to (possibly multiple) cells, which are arranged in regular grid between aabbMin and aabbMax, with cell size step (same in all directions). Bodies outsize (aabbMin, aabbMax) are handled gracefully, assigned to closest cells (this will create spurious potential interactions). verletDist determines how much is each body enlarged to avoid collision detection at every step.

Note

This collider keeps all cells in linear memory array, therefore will be memory-inefficient for sparse simulations.

Warning

Body::bound objects are not used, BoundFunctors are not used either: assigning cells to bodies is hard-coded internally. Currently handles Shapes are: Sphere.

Note

Periodic boundary is not handled (yet).

aabbMax(=Vector3r::Zero())

Upper corner of grid (approximate, might be rouded up to minStep.

aabbMin(=Vector3r::Zero())

Lower corner of grid.

step(=0)

Step in the grid (cell size)

verletDist(=0)

Length by which enlarge space occupied by each particle; avoids running collision detection at every step.

class yade.wrapper.InsertionSortCollider(inherits ColliderGlobalEngineEngineSerializable)

Collider with O(n log(n)) complexity, using Aabb for bounds.

At the initial step, Bodies’ bounds (along sortAxis) are first std::sort’ed along one axis (sortAxis), then collided. The initial sort has O(n^2) complexity, see Colliders’ performance for some information (There are scripts in examples/collider-perf for measurements).

Insertion sort is used for sorting the bound list that is already pre-sorted from last iteration, where each inversion calls checkOverlap which then handles either overlap (by creating interaction if necessary) or its absence (by deleting interaction if it is only potential).

Bodies without bounding volume (such as clumps) are handled gracefully and never collide. Deleted bodies are handled gracefully as well.

This collider handles periodic boundary conditions. There are some limitations, notably:

  1. No body can have Aabb larger than cell’s half size in that respective dimension. You get exception it it does and gets in interaction.
  2. No body can travel more than cell’s distance in one step; this would mean that the simulation is numerically exploding, and it is only detected in some cases.

Stride can be used to avoid running collider at every step by enlarging the particle’s bounds, tracking their velocities and only re-run if they might have gone out of that bounds (see Verlet list for brief description and background) . This requires cooperation from NewtonIntegrator as well as BoundDispatcher, which will be found among engines automatically (exception is thrown if they are not found).

If you wish to use strides, set sweepLength (length by which bounds will be enlarged in all directions) to some value, e.g. 0.05 × typical particle radius. This parameter expresses the tradeoff between many potential interactions (running collider rarely, but with longer exact interaction resolution phase) and few potential interactions (running collider more frequently, but with less exact resolutions of interactions); it depends mainly on packing density and particle radius distribution.

If you additionally set nBins to >=1, not all particles will have their bound enlarged by sweepLength; instead, they will be put to bins (in the statistical sense) based on magnitude of their velocity; sweepLength will only be used for particles in the fastest bin, whereas only proportionally smaller length will be used for slower particles; The coefficient between bin’s velocities is given by binCoeff.

binCoeff(=5)

Coefficient of bins for velocities, i.e. if binCoeff==5, successive bins have 5 × smaller velocity peak than the previous one. (Passed to VelocityBins)

binOverlap(=0.8)

Relative bins hysteresis, to avoid moving body back and forth if its velocity is around the border value. (Passed to VelocityBins)

dumpBounds() → tuple

Return representation of the internal sort data. The format is ([...],[...],[...]) for 3 axes, where each ... is a list of entries (bounds). The entry is a tuple with the fllowing items:

  • coordinate (float)
  • body id (int), but negated for negative bounds
  • period numer (int), if the collider is in the periodic regime.
fastestBodyMaxDist(=-1)

Maximum displacement of the fastest body since last run; if >= sweepLength, we could get out of bboxes and will trigger full run. DEPRECATED, was only used without bins. (auto-updated)

histInterval(=100)

How often to show velocity bins graphically, if debug logging is enabled for VelocityBins.

maxRefRelStep(=.3)

(Passed to VelocityBins)

nBins(=0)

Number of velocity bins for striding. If <=0, bin-less strigin is used (this is however DEPRECATED).

numReinit(=0)

Cummulative number of bound array re-initialization.

periodic

Whether the collider is in periodic mode (read-only; for debugging) (auto-updated)

sortAxis(=0)

Axis for the initial contact detection.

sortThenCollide(=false)

Separate sorting and colliding phase; it is MUCH slower, but all interactions are processed at every step; this effectively makes the collider non-persistent, not remembering last state. (The default behavior relies on the fact that inversions during insertion sort are overlaps of bounding boxes that just started/ceased to exist, and only processes those; this makes the collider much more efficient.)

strideActive

Whether striding is active (read-only; for debugging). (auto-updated)

sweepFactor(=1.05)

Overestimation factor for the sweep velocity; must be >=1.0. Has no influence on sweepLength, only on the computed stride. [DEPRECATED, is used only when bins are not used].

sweepLength(=-1, Stride deactivated)

Length by which to enlarge particle bounds, to avoid running collider at every step. Stride disabled if negative.

class yade.wrapper.SpatialQuickSortCollider(inherits ColliderGlobalEngineEngineSerializable)

Collider using quicksort along axes at each step, using Aabb bounds.

Its performance is lower than that of InsertionSortCollider (see Colliders’ performance), but the algorithm is simple enought to make it good for checking other collider’s correctness.

FieldApplier

digraph FieldApplier {
        rankdir=RL;
        margin=.2;
        "FieldApplier" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FieldApplier"];
        "CentralGravityEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CentralGravityEngine"];
        "CentralGravityEngine" -> "FieldApplier" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "AxialGravityEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.AxialGravityEngine"];
        "AxialGravityEngine" -> "FieldApplier" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "HdapsGravityEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.HdapsGravityEngine"];
        "HdapsGravityEngine" -> "GravityEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "GravityEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GravityEngine"];
        "GravityEngine" -> "FieldApplier" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.FieldApplier(inherits GlobalEngineEngineSerializable)

Base for engines applying force files on particles. Not to be used directly.

class yade.wrapper.AxialGravityEngine(inherits FieldApplierGlobalEngineEngineSerializable)

Apply acceleration (independent of distance) directed towards an axis.

acceleration(=0)

Acceleration magnitude [kgms⁻²]

axisDirection(=Vector3r::UnitX())

direction of the gravity axis (will be normalized automatically)

axisPoint(=Vector3r::Zero())

Point through which the axis is passing.

class yade.wrapper.CentralGravityEngine(inherits FieldApplierGlobalEngineEngineSerializable)

Engine applying acceleration to all bodies, towards a central body.

accel(=0)

Acceleration magnitude [kgms⁻²]

centralBody(=Body::ID_NONE)

The body towards which all other bodies are attracted.

reciprocal(=false)

If true, acceleration will be applied on the central body as well.

class yade.wrapper.GravityEngine(inherits FieldApplierGlobalEngineEngineSerializable)

Engine applying constant acceleration to all bodies.

gravity(=Vector3r::Zero())

Acceleration [kgms⁻²]

class yade.wrapper.HdapsGravityEngine(inherits GravityEngineFieldApplierGlobalEngineEngineSerializable)

Read accelerometer in Thinkpad laptops (HDAPS and accordingly set gravity within the simulation. This code draws from hdaps-gl . See scripts/test/hdaps.py for an example.

accel(=Vector2i::Zero())

reading from the sysfs file

calibrate(=Vector2i::Zero())

Zero position; if NaN, will be read from the hdapsDir / calibrate.

calibrated(=false)

Whether calibrate was already updated. Do not set to True by hand unless you also give a meaningful value for calibrate.

hdapsDir(="/sys/devices/platform/hdaps")

Hdaps directory; contains position (with accelerometer readings) and calibration (zero acceleration).

msecUpdate(=50)

How often to update the reading.

updateThreshold(=4)

Minimum difference of reading from the file before updating gravity, to avoid jitter.

zeroGravity(=Vector3r(0, 0, -1))

Gravity if the accelerometer is in flat (zero) position.

Partial engines

digraph PartialEngine {
        rankdir=RL;
        margin=.2;
        "PartialEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PartialEngine"];
        "LawTester" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.LawTester"];
        "LawTester" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "PressTestEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.PressTestEngine"];
        "PressTestEngine" -> "TranslationEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "RotationEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.RotationEngine"];
        "RotationEngine" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "ForceEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.ForceEngine"];
        "ForceEngine" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "InterpolatingHelixEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.InterpolatingHelixEngine"];
        "InterpolatingHelixEngine" -> "HelixEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "StepDisplacer" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.StepDisplacer"];
        "StepDisplacer" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TorqueEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TorqueEngine"];
        "TorqueEngine" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "HelixEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.HelixEngine"];
        "HelixEngine" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TranslationEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TranslationEngine"];
        "TranslationEngine" -> "PartialEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "InterpolatingDirectedForceEngine" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.InterpolatingDirectedForceEngine"];
        "InterpolatingDirectedForceEngine" -> "ForceEngine" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.PartialEngine(inherits EngineSerializable)

Engine affecting only particular bodies in the simulation, defined by ids.

ids(=uninitalized)

Ids of bodies affected by this PartialEngine.

class yade.wrapper.ForceEngine(inherits PartialEngineEngineSerializable)

Apply contact force on some particles at each step.

force(=Vector3r::Zero())

Force to apply.

class yade.wrapper.HelixEngine(inherits PartialEngineEngineSerializable)

Engine applying both rotation and translation, along the same axis, whence the name HelixEngine

angleTurned(=0)

How much have we turned so far. (auto-updated) [rad]

angularVelocity(=0)

Angular velocity [rad/s]

axis(=Vector3r::UnitX())

Axis of translation and rotation; will be normalized by the engine.

axisPt(=Vector3r::Zero())

A point on the axis, to position it in space properly.

linearVelocity(=0)

Linear velocity [m/s]

class yade.wrapper.InterpolatingDirectedForceEngine(inherits ForceEnginePartialEngineEngineSerializable)

Engine for applying force of varying magnitude but constant direction on subscribed bodies. times and magnitudes must have the same length, direction (normalized automatically) gives the orientation.

As usual with interpolating engines: the first magnitude is used before the first time point, last magnitude is used after the last time point. Wrap specifies whether time wraps around the last time point to the first time point.

direction(=Vector3r::UnitX())

Contact force direction (normalized automatically)

magnitudes(=uninitalized)

Force magnitudes readings [N]

times(=uninitalized)

Time readings [s]

wrap(=false)

wrap to the beginning of the sequence if beyond the last time point

class yade.wrapper.InterpolatingHelixEngine(inherits HelixEnginePartialEngineEngineSerializable)

Engine applying spiral motion, finding current angular velocity by linearly interpolating in times and velocities and translation by using slope parameter.

The interpolation assumes the margin value before the first time point and last value after the last time point. If wrap is specified, time will wrap around the last times value to the first one (note that no interpolation between last and first values is done).

angularVelocities(=uninitalized)

List of angular velocities; manadatorily of same length as times. [rad/s]

slope(=0)

Axial translation per radian turn (can be negative) [m/rad]

times(=uninitalized)

List of time points at which velocities are given; must be increasing [s]

wrap(=false)

Wrap t if t>times_n, i.e. t_wrapped=t-N*(times_n-times_0)

class yade.wrapper.LawTester(inherits PartialEngineEngineSerializable)

Prescribe and apply deformations of an interaction in terms of normal and shear displacements. See scripts/test/law-test.py.

axX(=uninitalized)

Local x-axis in global coordinates (normal of the contact) (auto-updated)

axY(=uninitalized)

Local y-axis in global coordinates; perpendicular to axX; initialized arbitrarily, but tracked to be consistent. (auto-updated)

axZ(=uninitalized)

Local z-axis in global coordinates; computed from axX and axY. (auto-updated)

contPt(=Vector3r::Zero())

Contact point (for rendering only)

displIsRel(=true)

Whether displacement values in path are normalized by reference contact length (r1+r2 for 2 spheres).

doneHook(=uninitalized)

Python command (as string) to run when end of the path is achieved. If empty, the engine will be set dead.

forceControl(=Vector3i::Zero())

Select which components of path (non-zero value) have force (stress) rather than displacement (strain) meaning.

hooks(=uninitalized)

Python commands to be run when the corresponding point in path is reached, before doing other things in that particular step. See also doneHook.

idWeight(=1)

Float ∈〈0,1〉 determining on which particle are displacements applied (0 for id1, 1 for id2); intermediate values will apply respective part to each of them.

path(=uninitalized)

Loading path, where each Vector3 contains desired normal displacement and two components of the shear displacement (in local coordinate system, which is being tracked automatically. If shorter than rotPath, the last value is repeated.

pathSteps(=vector<int>(1, 1), (constant step))

Step number for corresponding values in path; if shorter than path, distance between last 2 values is used for the rest.

phiPrev(=Vector3r::Zero())

Rotation value reached in the previous step.

ptGeom(=Vector3r::Zero())

Current displacement, as computed by the geometry functor

ptOurs(=Vector3r::Zero())

Current displacement, computed by ourselves from applied increments; should correspond to ptGeom.

refLength(=0)

Reference contact length, for rendering only.

renderLength(=0)

Characteristic length for the purposes of rendering, set equal to the smaller radius.

rotGeom(=Vector3r::Zero())

Current rotation, as computed by the geometry functor

rotOurs(=Vector3r::Zero())

Current rotation, computed by ourselves from applied increments; should correspond to rotGeom.

rotPath(=uninitalized)

Rotational components of the loading path, where each item contains torsion and two bending rotations in local coordinates. If shorter than path, the last value is repeated.

rotTot(=Vector3r::Zero())

Current rotation in global coordinates.

rotWeight(=1)

Float ∈〈0,1〉 determining whether shear displacement is applied as rotation or displacement on arc (0 is displacemetn-only, 1 is rotation-only).

shearTot(=Vector3r::Zero())

Current displacement in global coordinates.

step(=0)

Step number in which this engine is active; determines position in path, using pathSteps.

trsf(=uninitalized)

Transformation matrix for the local coordinate system. (auto-updated)

trsfQ(=uninitalized)

Transformation quaterion for the local coordinate system. (auto-updated)

uPrev(=Vector3r::Zero())

Displacement value reached in the previous step.

class yade.wrapper.PressTestEngine(inherits TranslationEnginePartialEngineEngineSerializable)

This class simulates the simple press work When the press cracks the solid brittle material, it returns back to the initial position and stops the simulation loop.

numberIterationAfterDestruction(=0)

The number of iterations, which will be carry out after destruction [-]

predictedForce(=0)

The minimal force, after what the engine will look for a destruction [N]

riseUpPressHigher(=1)

After destruction press rises up. This is the relationship between initial press velocity and velocity for going back [-]

class yade.wrapper.RotationEngine(inherits PartialEngineEngineSerializable)

Engine applying rotation (by setting angular velocity) to subscribed bodies. If rotateAroundZero is set, then each body is also displaced around zeroPoint.

angularVelocity(=0)

Angular velocity. [rad/s]

rotateAroundZero(=false)

If True, bodies will not rotate around their centroids, but rather around zeroPoint.

rotationAxis(=Vector3r::UnitX())

Axis of rotation (direction); will be normalized automatically.

zeroPoint(=Vector3r::Zero())

Point around which bodies will rotate if rotateAroundZero is True

class yade.wrapper.StepDisplacer(inherits PartialEngineEngineSerializable)

Apply generalized displacement (displacement or rotation) stepwise on subscribed bodies.

deltaSe3(=Se3r(Vector3r(NaN, NaN, NaN), Quaternionr::Identity()))

|ydeprec| Set mov/rot directly instead; kept only for backwards compat. If the 0th component of the vector is not NaN, then it was updated by the user, warning is issued and mov and rot are updated automatically.

mov(=Vector3r::Zero())

Linear displacement step to be applied per iteration, by addition to State.pos.

rot(=Quaternionr::Identity())

Rotation step to be applied per iteration (via rotation composition with State.ori).

setVelocities(=false)

If true, velocity and angularVelocity are modified in such a way that over one iteration (dt), the body will have the prescribed jump. In this case, position and orientation itself is not updated for dynamic bodies, since they would have the delta applied twice (here and in the integrator). For non-dynamic bodies however, they are still updated.

class yade.wrapper.TorqueEngine(inherits PartialEngineEngineSerializable)

Apply given torque (momentum) value at every subscribed particle, at every step.

moment(=Vector3r::Zero())

Torque value to be applied.

class yade.wrapper.TranslationEngine(inherits PartialEngineEngineSerializable)

This engine is the base class for different engines, which require any kind of motion.

translationAxis(=uninitalized)

Direction [Vector3]

velocity(=uninitalized)

Velocity [m/s]

Bounding volume creation

BoundFunctor

digraph BoundFunctor {
        rankdir=RL;
        margin=.2;
        "BoundFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.BoundFunctor"];
        "Bo1_ChainedCylinder_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_ChainedCylinder_Aabb"];
        "Bo1_ChainedCylinder_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Facet_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Facet_Aabb"];
        "Bo1_Facet_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Sphere_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Sphere_Aabb"];
        "Bo1_Sphere_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Tetra_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Tetra_Aabb"];
        "Bo1_Tetra_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Wall_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Wall_Aabb"];
        "Bo1_Wall_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Box_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Box_Aabb"];
        "Bo1_Box_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Bo1_Cylinder_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Bo1_Cylinder_Aabb"];
        "Bo1_Cylinder_Aabb" -> "BoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.BoundFunctor(inherits FunctorSerializable)

Functor for creating/updating Body::bound.

class yade.wrapper.Bo1_Box_Aabb(inherits BoundFunctorFunctorSerializable)

Create/update an Aabb of a Box.

class yade.wrapper.Bo1_ChainedCylinder_Aabb(inherits BoundFunctorFunctorSerializable)

Functor creating Aabb from ChainedCylinder.

aabbEnlargeFactor

Relative enlargement of the bounding box; deactivated if negative.

Note

This attribute is used to create distant interaction, but is only meaningful with an IGeomFunctor which will not simply discard such interactions: Ig2_Cylinder_Cylinder_Dem3DofGeom::distFactor / Ig2_Cylinder_Cylinder_ScGeom::interactionDetectionFactor should have the same value as aabbEnlargeFactor.

class yade.wrapper.Bo1_Cylinder_Aabb(inherits BoundFunctorFunctorSerializable)

Functor creating Aabb from Cylinder.

aabbEnlargeFactor

Relative enlargement of the bounding box; deactivated if negative.

Note

This attribute is used to create distant interaction, but is only meaningful with an IGeomFunctor which will not simply discard such interactions: Ig2_Cylinder_Cylinder_Dem3DofGeom::distFactor / Ig2_Cylinder_Cylinder_ScGeom::interactionDetectionFactor should have the same value as aabbEnlargeFactor.

class yade.wrapper.Bo1_Facet_Aabb(inherits BoundFunctorFunctorSerializable)

Creates/updates an Aabb of a Facet.

class yade.wrapper.Bo1_Sphere_Aabb(inherits BoundFunctorFunctorSerializable)

Functor creating Aabb from Sphere.

aabbEnlargeFactor

Relative enlargement of the bounding box; deactivated if negative.

Note

This attribute is used to create distant interaction, but is only meaningful with an IGeomFunctor which will not simply discard such interactions: Ig2_Sphere_Sphere_Dem3DofGeom::distFactor / Ig2_Sphere_Sphere_ScGeom::interactionDetectionFactor should have the same value as aabbEnlargeFactor.

class yade.wrapper.Bo1_Tetra_Aabb(inherits BoundFunctorFunctorSerializable)

Create/update Aabb of a Tetra

class yade.wrapper.Bo1_Wall_Aabb(inherits BoundFunctorFunctorSerializable)

Creates/updates an Aabb of a Wall

BoundDispatcher

class yade.wrapper.BoundDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

activated(=true)

Whether the engine is activated (only should be changed by the collider)

dispFunctor((Shape)arg2) → BoundFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

sweepDist(=0)

Distance by which enlarge all bounding boxes, to prevent collider from being run at every step (only should be changed by the collider).

Interaction Geometry creation

IGeomFunctor

digraph IGeomFunctor {
        rankdir=RL;
        margin=.2;
        "IGeomFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.IGeomFunctor"];
        "Ig2_Sphere_Sphere_ScGeom6D" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Sphere_Sphere_ScGeom6D"];
        "Ig2_Sphere_Sphere_ScGeom6D" -> "Ig2_Sphere_Sphere_ScGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Sphere_Sphere_Dem3DofGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Sphere_Sphere_Dem3DofGeom"];
        "Ig2_Sphere_Sphere_Dem3DofGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Wall_Sphere_Dem3DofGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Wall_Sphere_Dem3DofGeom"];
        "Ig2_Wall_Sphere_Dem3DofGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Wall_Sphere_ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Wall_Sphere_ScGeom"];
        "Ig2_Wall_Sphere_ScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Box_Sphere_ScGeom6D" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Box_Sphere_ScGeom6D"];
        "Ig2_Box_Sphere_ScGeom6D" -> "Ig2_Box_Sphere_ScGeom" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Facet_Sphere_Dem3DofGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Facet_Sphere_Dem3DofGeom"];
        "Ig2_Facet_Sphere_Dem3DofGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Facet_Sphere_ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Facet_Sphere_ScGeom"];
        "Ig2_Facet_Sphere_ScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Sphere_Sphere_L3Geom_Inc" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Sphere_Sphere_L3Geom_Inc"];
        "Ig2_Sphere_Sphere_L3Geom_Inc" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Sphere_ChainedCylinder_CylScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Sphere_ChainedCylinder_CylScGeom"];
        "Ig2_Sphere_ChainedCylinder_CylScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Box_Sphere_ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Box_Sphere_ScGeom"];
        "Ig2_Box_Sphere_ScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Tetra_Tetra_TTetraGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Tetra_Tetra_TTetraGeom"];
        "Ig2_Tetra_Tetra_TTetraGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_ChainedCylinder_ChainedCylinder_ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_ChainedCylinder_ChainedCylinder_ScGeom"];
        "Ig2_ChainedCylinder_ChainedCylinder_ScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ig2_Sphere_Sphere_ScGeom" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ig2_Sphere_Sphere_ScGeom"];
        "Ig2_Sphere_Sphere_ScGeom" -> "IGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.IGeomFunctor(inherits FunctorSerializable)

Functor for creating/updating Interaction::geom objects.

class yade.wrapper.Ig2_Box_Sphere_ScGeom(inherits IGeomFunctorFunctorSerializable)

Create an interaction geometry ScGeom from Box and Sphere

class yade.wrapper.Ig2_Box_Sphere_ScGeom6D(inherits Ig2_Box_Sphere_ScGeomIGeomFunctorFunctorSerializable)

Create an interaction geometry ScGeom6D from Box and Sphere

class yade.wrapper.Ig2_ChainedCylinder_ChainedCylinder_ScGeom(inherits IGeomFunctorFunctorSerializable)

Create/update a ScGeom instance representing connexion between chained cylinders.

interactionDetectionFactor(=1)

Enlarge both radii by this factor (if >1), to permit creation of distant interactions.

class yade.wrapper.Ig2_Facet_Sphere_Dem3DofGeom(inherits IGeomFunctorFunctorSerializable)

Compute geometry of facet-sphere contact with normal and shear DOFs. As in all other Dem3DofGeom-related classes, total formulation of both shear and normal deformations is used. See Dem3DofGeom_FacetSphere for more information.

class yade.wrapper.Ig2_Facet_Sphere_ScGeom(inherits IGeomFunctorFunctorSerializable)

Create/update a ScGeom instance representing intersection of Facet and Sphere.

shrinkFactor(=0, no shrinking)

The radius of the inscribed circle of the facet is decreased by the value of the sphere’s radius multipled by shrinkFactor. From the definition of contact point on the surface made of facets, the given surface is not continuous and becomes in effect surface covered with triangular tiles, with gap between the separate tiles equal to the sphere’s radius multiplied by 2×*shrinkFactor*. If zero, no shrinking is done.

class yade.wrapper.Ig2_Sphere_ChainedCylinder_CylScGeom(inherits IGeomFunctorFunctorSerializable)

Create/update a ScGeom instance representing intersection of two Spheres.

interactionDetectionFactor(=1)

Enlarge both radii by this factor (if >1), to permit creation of distant interactions.

class yade.wrapper.Ig2_Sphere_Sphere_Dem3DofGeom(inherits IGeomFunctorFunctorSerializable)

Functor handling contact of 2 spheres, producing Dem3DofGeom instance

distFactor(=-1)

Factor of sphere radius such that sphere “touch” if their centers are not further than distFactor*(r1+r2); if negative, equilibrium distance is the sum of the sphere’s radii.

class yade.wrapper.Ig2_Sphere_Sphere_L3Geom_Inc(inherits IGeomFunctorFunctorSerializable)

Incrementally compute L3Geom for contact of 2 spheres.

Note

The initial value of u[0] (normal displacement) might be non-zero, with or without distFactor, since it is given purely by sphere’s geometry. If you want to set “equilibrium distance”, do it in the contact law as explained in L3Geom.u0.

approxMask

Selectively enable geometrical approximations (bitmask); add the values for approximations to be enabled.

1: do not renormalize transformation matrix at every step 2: use previous transformation to transform velocities (which are known at mid-steps), instead of mid-step transformation computed as quaternion slerp at t=0.5. 4: do not take average (mid-step) normal when computing relative shear displacement, use previous value instead 8: do not re-normalize average (mid-step) normal, if used.… By default, the mask is zero and neither of these approximations is used.

distFactor(=1)

Create interaction if spheres are not futher than distFactor*(r1+r2).

noRatch(=true)

See ScGeom.avoidGranularRatcheting.

class yade.wrapper.Ig2_Sphere_Sphere_ScGeom(inherits IGeomFunctorFunctorSerializable)

Create/update a ScGeom instance representing intersection of two Spheres.

avoidGranularRatcheting

Granular ratcheting is mentioned in [GarciaRojo2004], [Alonso2004], [McNamara2008].

Unfortunately, published papers tend to focus on the “good” ratcheting, i.e. irreversible deformations due to the intrinsic nature of frictional granular materials, while a 2004 talk of McNamara in Paris clearly mentioned a possible “bad” ratcheting, purely linked with the formulation of the contact laws in what he called “molecular dynamics” (i.e. Cundall’s model, as opposed to “contact dynamics” from Moreau and Jean).

The bad ratcheting is best understood considering this small elastic cycle at a contact between two grains: assuming b1 is fixed, impose this displacement to b2:

  1. translation dx in the normal direction
  2. rotation a
  3. translation -dx (back to the initial position)
  4. rotation -a (back to the initial orientation)

If the branch vector used to define the relative shear in rotation×branch is not constant (typically if it is defined from the vector center→contactPoint), then the shear displacement at the end of this cycle is not zero: rotations a and -a are multiplied by branches of different lengths.

It results in a finite contact force at the end of the cycle even though the positions and orientations are unchanged, in total contradiction with the elastic nature of the problem. It could also be seen as an inconsistent energy creation or loss. Given that DEM simulations tend to generate oscillations around equilibrium (damped mass-spring), it can have a significant impact on the evolution of the packings, resulting for instance in slow creep in iterations under constant load.

The solution to avoid that is quite simple in the case of linear-elastic laws: use a constant branch vector, which is what this functor does by default.

interactionDetectionFactor

Enlarge both radii by this factor (if >1), to permit creation of distant interactions.

InteractionGeometry will be computed when interactionDetectionFactor*(rad1+rad2) > distance.

Note

This parameter is functionally coupled with Bo1_Sphere_Aabb::aabbEnlargeFactor, which will create larger bounding boxes and should be of the same value.

Warning

Functionally equal class Ig2_Sphere_Sphere_Dem3DofGeom (which creates Dem3DofGeom rather than ScGeom) calls this parameter distFactor, but its semantics is different in some aspects.

class yade.wrapper.Ig2_Sphere_Sphere_ScGeom6D(inherits Ig2_Sphere_Sphere_ScGeomIGeomFunctorFunctorSerializable)

Create/update a ScGeom6D instance representing intersection of two Spheres.

creep(=false)

Substract rotational creep from relative rotation. The rotational creep ScGeom6D::twistCreep is a quaternion and has to be updated inside a constitutive law, see for instance Law2_ScGeom_CohFrictPhys_CohesionMoment.

updateRotations(=true)

Precompute relative rotations. Turning this false can speed up simulations when rotations are not needed in constitutive laws (e.g. when spheres are compressed without cohesion and moment in early stage of a triaxial test), but is not foolproof. Change this value only if you know what you are doing.

class yade.wrapper.Ig2_Tetra_Tetra_TTetraGeom(inherits IGeomFunctorFunctorSerializable)

Create/update geometry of collision between 2 tetrahedra (TTetraGeom instance)

class yade.wrapper.Ig2_Wall_Sphere_Dem3DofGeom(inherits IGeomFunctorFunctorSerializable)

Create/update contact of Wall and Sphere (Dem3DofGeom_WallSphere instance)

class yade.wrapper.Ig2_Wall_Sphere_ScGeom(inherits IGeomFunctorFunctorSerializable)

Create/update a ScGeom instance representing intersection of Wall and Sphere.

noRatch(=true)

Avoid granular ratcheting

IGeomDispatcher

class yade.wrapper.IGeomDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((Shape)arg2, (Shape)arg3) → IGeomFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

Interaction Physics creation

IPhysFunctor

digraph IPhysFunctor {
        rankdir=RL;
        margin=.2;
        "IPhysFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.IPhysFunctor"];
        "Ip2_RpmMat_RpmMat_RpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_RpmMat_RpmMat_RpmPhys"];
        "Ip2_RpmMat_RpmMat_RpmPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_2xNormalInelasticMat_NormalInelasticityPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_2xNormalInelasticMat_NormalInelasticityPhys"];
        "Ip2_2xNormalInelasticMat_NormalInelasticityPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_FrictMat_FrictMat_CapillaryPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_FrictMat_FrictMat_CapillaryPhys"];
        "Ip2_FrictMat_FrictMat_CapillaryPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_FrictMat_FrictMat_FrictPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_FrictMat_FrictMat_FrictPhys"];
        "Ip2_FrictMat_FrictMat_FrictPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_FrictMat_FrictMat_MindlinPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_FrictMat_FrictMat_MindlinPhys"];
        "Ip2_FrictMat_FrictMat_MindlinPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_MomentMat_MomentMat_MomentPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_MomentMat_MomentMat_MomentPhys"];
        "Ip2_MomentMat_MomentMat_MomentPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_CpmMat_CpmMat_CpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_CpmMat_CpmMat_CpmPhys"];
        "Ip2_CpmMat_CpmMat_CpmPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_CFpmMat_CFpmMat_CFpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_CFpmMat_CFpmMat_CFpmPhys"];
        "Ip2_CFpmMat_CFpmMat_CFpmPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_2xFrictMat_CSPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_2xFrictMat_CSPhys"];
        "Ip2_2xFrictMat_CSPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_2xCohFrictMat_CohFrictPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_2xCohFrictMat_CohFrictPhys"];
        "Ip2_2xCohFrictMat_CohFrictPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Ip2_ViscElMat_ViscElMat_ViscElPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Ip2_ViscElMat_ViscElMat_ViscElPhys"];
        "Ip2_ViscElMat_ViscElMat_ViscElPhys" -> "IPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.IPhysFunctor(inherits FunctorSerializable)

Functor for creating/updating Interaction::phys objects.

class yade.wrapper.Ip2_2xCohFrictMat_CohFrictPhys(inherits IPhysFunctorFunctorSerializable)

Generates cohesive-frictional interactions with moments. Used in the contact law Law2_ScGeom_CohFrictPhys_CohesionMoment.

setCohesionNow(=false)

If true, assign cohesion to all existing contacts in current time-step. The flag is turned false automatically, so that assignment is done in the current timestep only.

setCohesionOnNewContacts(=false)

If true, assign cohesion at all new contacts. If false, only existing contacts can be cohesive (also see Ip2_2xCohFrictMat_CohFrictPhys::setCohesionNow), and new contacts are only frictional.

class yade.wrapper.Ip2_2xFrictMat_CSPhys(inherits IPhysFunctorFunctorSerializable)

Functor creating CSPhys from two FrictMat. See Law2_Dem3Dof_CSPhys_CundallStrack for details.

class yade.wrapper.Ip2_2xNormalInelasticMat_NormalInelasticityPhys(inherits IPhysFunctorFunctorSerializable)

The RelationShips for using Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity

In these RelationShips all the attributes of the interactions (which are of NormalInelasticityPhys type) are computed.

Warning

as in the others Ip2 functors, most of the attributes are computed only once, when the interaction is new.

betaR(=0.12)

Parameter for computing the torque-stifness : T-stifness = betaR * Rmoy^2

class yade.wrapper.Ip2_CFpmMat_CFpmMat_CFpmPhys(inherits IPhysFunctorFunctorSerializable)

Converts 2 CFpmmat instances to CFpmPhys with corresponding parameters.

Alpha(=0)

Defines the ratio ks/kn.

Beta(=0)

Defines the ratio kr/(ks*meanRadius^2) to compute the resistive moment in rotation. [-]

cohesion(=0)

Defines the maximum admissible tangential force in shear FsMax=cohesion*crossSection. [Pa]

cohesiveTresholdIteration(=1)

Should new contacts be cohesive? They will before this iter, they won’t afterward.

eta(=0)

Defines the maximum admissible resistive moment in rotation MtMax=eta*meanRadius*Fn. [-]

strengthSoftening(=0)

Defines the softening when Dtensile is reached to avoid explosion of the contact. Typically, when D > Dtensile, Fn=FnMax - (kn/strengthSoftening)*(Dtensile-D). [-]

tensileStrength(=0)

Defines the maximum admissible normal force in traction FnMax=tensileStrength*crossSection. [Pa]

useAlphaBeta(=false)

If true, stiffnesses are computed based on Alpha and Beta.

class yade.wrapper.Ip2_CpmMat_CpmMat_CpmPhys(inherits IPhysFunctorFunctorSerializable)

Convert 2 CpmMat instances to CpmPhys with corresponding parameters. Uses simple (arithmetic) averages if material are different. Simple copy of parameters is performed if the material is shared between both particles. See cpm-model for detals.

cohesiveThresholdIter(=10)

Should new contacts be cohesive? They will before this iter#, they will not be afterwards. If 0, they will never be. If negative, they will always be created as cohesive (10 by default).

class yade.wrapper.Ip2_FrictMat_FrictMat_CapillaryPhys(inherits IPhysFunctorFunctorSerializable)

RelationShips to use with Law2_ScGeom_CapillaryPhys_Capillarity

In these RelationShips all the interaction attributes are computed.

Warning

as in the others Ip2 functors, most of the attributes are computed only once, when the interaction is new.

class yade.wrapper.Ip2_FrictMat_FrictMat_FrictPhys(inherits IPhysFunctorFunctorSerializable)

Create a FrictPhys from two FrictMats. The compliance of one sphere under symetric point loads is defined here as 1/(E.r), with E the stiffness of the sphere and r its radius, and corresponds to a compliance 1/(2.E.r)=1/(E.D) from each contact point. The compliance of the contact itself will be the sum of compliances from each sphere, i.e. 1/(E.D1)+1/(E.D2) in the general case, or 1/(E.r) in the special case of equal sizes. Note that summing compliances corresponds to an harmonic average of stiffnesss, which is how kn is actually computed in the Ip2_FrictMat_FrictMat_FrictPhys functor.

The shear stiffness ks of one sphere is defined via the material parameter ElastMat::poisson, as ks=poisson*kn, and the resulting shear stiffness of the interaction will be also an harmonic average.

The friction angle of the contact is defined as the minimum angle of the two materials in contact.

Only interactions with ScGeom or Dem3DofGeom geometry are meaningfully accepted; run-time typecheck can make this functor unnecessarily slow in general. Such design is problematic in itself, though – from http://www.mail-archive.com/yade-dev@lists.launchpad.net/msg02603.html:

You have to suppose some exact type of IGeom in the Ip2 functor, but you don’t know anything about it (Ip2 only guarantees you get certain IPhys types, via the dispatch mechanism).

That means, unless you use Ig2 functor producing the desired type, the code will break (crash or whatever). The right behavior would be either to accept any type (what we have now, at least in principle), or really enforce IGeom type of the interation passed to that particular Ip2 functor.

class yade.wrapper.Ip2_FrictMat_FrictMat_MindlinPhys(inherits IPhysFunctorFunctorSerializable)

Calculate some physical parameters needed to obtain the normal and shear stiffnesses according to the Hertz-Mindlin’s formulation (as implemented in PFC).

Viscous parameters can be specified either using coefficients of restitution (e_n, e_s) or viscous damping coefficient (\beta_n, \beta_s). The following rules apply: #. If the \beta_n (\beta_s) coefficient is given, it is assigned to MindlinPhys.betan (MindlinPhys.betas) directly. #. If e_n is given, MindlinPhys.betan is computed using \beta_n=-(\log e_n)/\sqrt{\pi^2+(\log e_n)^2}. The same applies to e_s, MindlinPhys.betas. #. It is an error (exception) to specify both e_n and \beta_n (e_s and \beta_s). #. If neither e_n nor \beta_n is given, zero value for MindlinPhys.betan is used; there will be no viscous effects. #.If neither e_s nor \beta_s is given, the value of MindlinPhys.betan is used for MindlinPhys.betas as well.

The e_n, \beta_n, e_s, \beta_s are MatchMaker objects; they can be constructed from float values to always return constant value.

See scripts/shots.py for an example of specifying e_n based on combination of parameters.

betan(=uninitalized)

Normal viscous damping coefficient \beta_n.

betas(=uninitalized)

Shear viscous damping coefficient \beta_s.

en(=uninitalized)

Normal coefficient of restitution e_n.

es(=uninitalized)

Shear coefficient of restitution e_s.

gamma(=0.0)

Surface energy parameter [J/m^2] per each unit contact surface, to derive DMT formulation from HM

class yade.wrapper.Ip2_MomentMat_MomentMat_MomentPhys(inherits IPhysFunctorFunctorSerializable)

Create MomentPhys from 2 instances of MomentMat.

  1. If boolean userInputStiffness=true & useAlphaBeta=false, users can input Knormal, Kshear and Krotate directly. Then, kn,ks and kr will be equal to these values, rather than calculated E and v.
  2. If boolean userInputStiffness=true & useAlphaBeta=true, users input Knormal, Alpha and Beta. Then ks and kr are calculated from alpha & beta respectively.
  3. If both are false, it calculates kn and ks are calculated from E and v, whilst kr = 0.
Alpha(=0)

Ratio of Ks/Kn

Beta(=0)

Ratio to calculate Kr

Knormal(=0)

Allows user to input stiffness properties from triaxial test. These will be passed to MomentPhys or NormShearPhys

Krotate(=0)

Allows user to input stiffness properties from triaxial test. These will be passed to MomentPhys or NormShearPhys

Kshear(=0)

Allows user to input stiffness properties from triaxial test. These will be passed to MomentPhys or NormShearPhys

useAlphaBeta(=false)

for users to choose whether to input stiffness directly or use ratios to calculate Ks/Kn

userInputStiffness(=false)

for users to choose whether to input stiffness directly or use ratios to calculate Ks/Kn

class yade.wrapper.Ip2_RpmMat_RpmMat_RpmPhys(inherits IPhysFunctorFunctorSerializable)

Convert 2 RpmMat instances to RpmPhys with corresponding parameters.

initDistance(=0)

Initial distance between spheres at the first step.

class yade.wrapper.Ip2_ViscElMat_ViscElMat_ViscElPhys(inherits IPhysFunctorFunctorSerializable)

Convert 2 instances of ViscElMat to ViscElPhys using the rule of consecutive connection.

IPhysDispatcher

class yade.wrapper.IPhysDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((Material)arg2, (Material)arg3) → IPhysFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

Constitutive laws

LawFunctor

digraph LawFunctor {
        rankdir=RL;
        margin=.2;
        "LawFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.LawFunctor"];
        "Law2_Dem3DofGeom_FrictPhys_CundallStrack" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_Dem3DofGeom_FrictPhys_CundallStrack"];
        "Law2_Dem3DofGeom_FrictPhys_CundallStrack" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_CohFrictPhys_CohesionMoment" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_CohFrictPhys_CohesionMoment"];
        "Law2_ScGeom_CohFrictPhys_CohesionMoment" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_CpmPhys_Cpm" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_CpmPhys_Cpm"];
        "Law2_ScGeom_CpmPhys_Cpm" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_Dem3DofGeom_RockPMPhys_Rpm" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_Dem3DofGeom_RockPMPhys_Rpm"];
        "Law2_Dem3DofGeom_RockPMPhys_Rpm" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_Dem3Dof_CSPhys_CundallStrack" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_Dem3Dof_CSPhys_CundallStrack"];
        "Law2_Dem3Dof_CSPhys_CundallStrack" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_L3Geom_FrictPhys_ElPerfPl" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_L3Geom_FrictPhys_ElPerfPl"];
        "Law2_L3Geom_FrictPhys_ElPerfPl" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_ViscElPhys_Basic" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_ViscElPhys_Basic"];
        "Law2_ScGeom_ViscElPhys_Basic" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_Dem3DofGeom_CpmPhys_Cpm" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_Dem3DofGeom_CpmPhys_Cpm"];
        "Law2_Dem3DofGeom_CpmPhys_Cpm" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_MindlinPhys_Mindlin" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_MindlinPhys_Mindlin"];
        "Law2_ScGeom_MindlinPhys_Mindlin" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_CFpmPhys_CohesiveFrictionalPM" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_CFpmPhys_CohesiveFrictionalPM"];
        "Law2_ScGeom_CFpmPhys_CohesiveFrictionalPM" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_SCG_MomentPhys_CohesionlessMomentRotation" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_SCG_MomentPhys_CohesionlessMomentRotation"];
        "Law2_SCG_MomentPhys_CohesionlessMomentRotation" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_MindlinPhys_HertzWithLinearShear" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_MindlinPhys_HertzWithLinearShear"];
        "Law2_ScGeom_MindlinPhys_HertzWithLinearShear" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity"];
        "Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_FrictPhys_CundallStrack" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_FrictPhys_CundallStrack"];
        "Law2_ScGeom_FrictPhys_CundallStrack" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_L6Geom_FrictPhys_Linear" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_L6Geom_FrictPhys_Linear"];
        "Law2_L6Geom_FrictPhys_Linear" -> "Law2_L3Geom_FrictPhys_ElPerfPl" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Law2_ScGeom_MindlinPhys_MindlinDeresiewitz" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Law2_ScGeom_MindlinPhys_MindlinDeresiewitz"];
        "Law2_ScGeom_MindlinPhys_MindlinDeresiewitz" -> "LawFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.LawFunctor(inherits FunctorSerializable)

Functor for applying constitutive laws on interactions.

class yade.wrapper.Law2_Dem3DofGeom_CpmPhys_Cpm(inherits LawFunctorFunctorSerializable)

Constitutive law for the cpm-model.

epsSoft(=-3e-3, approximates confinement -20MPa precisely, -100MPa a little over, -200 and -400 are OK (secant))

Strain at which softening in compression starts (non-negative to deactivate)

funcG((float)epsCrackOnset, (float)epsFracture[, (bool)neverDamage=False]) → float

Damage evolution law, evaluating the \omega parameter. \kappa_D is historically maximum strain, epsCrackOnset (\varepsilon_0) = CpmPhys.epsCrackOnset, epsFracture = CpmPhys.epsFracture; if neverDamage is True, the value returned will always be 0 (no damage).

omegaThreshold(=1., >=1. to deactivate, i.e. never delete any contacts)

damage after which the contact disappears (<1), since omega reaches 1 only for strain →+∞

relKnSoft(=.3)

Relative rigidity of the softening branch in compression (0=perfect elastic-plastic, <0 softening, >0 hardening)

yieldEllipseShift(=NaN)

horizontal scaling of the ellipse (shifts on the +x axis as interactions with +y are given)

yieldLogSpeed(=.1)

scaling in the logarithmic yield surface (should be <1 for realistic results; >=0 for meaningful results)

yieldSigmaTMagnitude((float)sigmaN, (float)omega, (float)undamagedCohesion, (float)tanFrictionAngle) → float

Return radius of yield surface for given material and state parameters; uses attributes of the current instance (yieldSurfType etc), change them before calling if you need that.

yieldSurfType(=2)

yield function: 0: mohr-coulomb (original); 1: parabolic; 2: logarithmic, 3: log+lin_tension, 4: elliptic, 5: elliptic+log

class yade.wrapper.Law2_Dem3DofGeom_FrictPhys_CundallStrack(inherits LawFunctorFunctorSerializable)

Constitutive law for linear compression, no tension, and linear plasticity surface.

This class serves also as tutorial and is documented in detail at https://yade-dem.org/index.php/ConstitutiveLawHowto.

class yade.wrapper.Law2_Dem3DofGeom_RockPMPhys_Rpm(inherits LawFunctorFunctorSerializable)

Constitutive law for the Rpm model

class yade.wrapper.Law2_Dem3Dof_CSPhys_CundallStrack(inherits LawFunctorFunctorSerializable)

Basic constitutive law published originally by Cundall&Strack; it has normal and shear stiffnesses (Kn, Kn) and dry Coulomb friction. Operates on associated Dem3DofGeom and CSPhys instances.

class yade.wrapper.Law2_L3Geom_FrictPhys_ElPerfPl(inherits LawFunctorFunctorSerializable)

Basic law for testing L3Geom; it bears no cohesion (unless noBreak is True), and plastic slip obeys the Mohr-Coulomb criterion (unless noSlip is True).

noBreak(=false)

Do not break contacts when particles separate.

noSlip(=false)

No plastic slipping.

class yade.wrapper.Law2_L6Geom_FrictPhys_Linear(inherits Law2_L3Geom_FrictPhys_ElPerfPlLawFunctorFunctorSerializable)

Basic law for testing L6Geom – linear in both normal and shear sense, without slip or breakage.

charLen(=1)

Characteristic length with the meaning of the stiffness ratios bending/shear and torsion/normal.

class yade.wrapper.Law2_SCG_MomentPhys_CohesionlessMomentRotation(inherits LawFunctorFunctorSerializable)

Contact law based on Plassiard et al. (2009) : A spherical discrete element model: calibration procedure and incremental response. The functionality has been verified with results in the paper.

The contribution of stiffnesses are scaled according to the radius of the particle, as implemented in that paper.

See also associated classes MomentMat, Ip2_MomentMat_MomentMat_MomentPhys, MomentPhys.

Note

This constitutive law can be used with triaxial test, but the following significant changes in code have to be made: Ip2_MomentMat_MomentMat_MomentPhys and Law2_SCG_MomentPhys_CohesionlessMomentRotation have to be added. Since it uses ScGeom, it uses boxes rather than facets. Spheres and boxes have to be changed to MomentMat rather than FrictMat.

preventGranularRatcheting(=false)

??

class yade.wrapper.Law2_ScGeom6D_NormalInelasticityPhys_NormalInelasticity(inherits LawFunctorFunctorSerializable)

Contact law used to simulate granulate filler in rock joints [Duriez2009a], [Duriez2010]. It includes possibility of cohesion, moment transfer and inelastic compression behaviour (to reproduce the normal inelasticity observed for rock joints, for the latter).

The moment transfer relation corresponds to the adaptation of the work of Plassiard & Belheine (see in [DeghmReport2006] for example), which was realized by J. Kozicki, and is now coded in ScGeom6D.

As others LawFunctor, it uses pre-computed data of the interactions (rigidities, friction angles -with their tan()-, orientations of the interactions); this work is done here in Ip2_2xNormalInelasticMat_NormalInelasticityPhys.

To use this you should also use NormalInelasticMat as material type of the bodies.

The effects of this law are illustrated in scripts/normalInelasticityTest.py

momentAlwaysElastic(=false)

boolean, true=> the torque (computed only if momentRotationLaw !!) is not limited by a plastic threshold

momentRotationLaw(=true)

boolean, true=> computation of a torque (against relative rotation) exchanged between particles

class yade.wrapper.Law2_ScGeom_CFpmPhys_CohesiveFrictionalPM(inherits LawFunctorFunctorSerializable)

Constitutive law for the CFpm model.

preventGranularRatcheting(=true)

If true rotations are computed such as granular ratcheting is prevented. See article [Alonso2004], pg. 3-10 – and a lot more papers from the same authors).

class yade.wrapper.Law2_ScGeom_CohFrictPhys_CohesionMoment(inherits LawFunctorFunctorSerializable)

Law for linear traction-compression-bending-twisting, with cohesion+friction and Mohr-Coulomb plasticity surface. This law adds adhesion and moments to Law2_ScGeom_FrictPhys_CundallStrack.

The normal force is (with the convention of positive tensile forces) F_n=min(k_n*u_n, a_n), with a_n the normal adhesion. The shear force is F_s=k_s*u_s, the plasticity condition defines the maximum value of the shear force, by default F_s^{max}=F_n*tan(\phi)+a_s, with \phi the friction angle and a_n the shear adhesion. If CohFrictPhys::cohesionDisableFriction is True, friction is ignored as long as adhesion is active, and the maximum shear force is only F_s^{max}=a_s.

If the maximum tensile or maximum shear force is reached and CohFrictPhys::fragile =True (default), the cohesive link is broken, and a_n, a_s are set back to zero. If a tensile force is present, the contact is lost, else the shear strength is F_s^{max}=F_n*tan(\phi). If CohFrictPhys::fragile =False (in course of implementation), the behaviour is perfectly plastic, and the shear strength is kept constant.

If Law2_ScGeom_CohFrictPhys_CohesionMoment::momentRotationLaw =True, bending and twisting moments are computed using a linear law with moduli respectively k_t and k_r (the two values are the same currently), so that the moments are : M_b=k_b*\Theta_b and M_t=k_t*\Theta_t, with \Theta_{b,t} the relative rotations between interacting bodies. There is no maximum value of moments in the current implementation, though they could be added in the future.

Creep at contact is implemented in this law, as defined in [Hassan2010]. If activated, there is a viscous behaviour of the shear and twisting components, and the evolution of the elastic parts of shear displacement and relative twist is given by du_{s,e}/dt=-F_s/\nu_s and d\Theta_{t,e}/dt=-M_t/\nu_t.

Note

Periodicity is not handled yet in this law.

always_use_moment_law(=false)

If true, use bending/twisting moments at all contacts. If false, compute moments only for cohesive contacts.

creep_viscosity(=1)

creep viscosity [Pa.s/m]. probably should be moved to Ip2_2xCohFrictMat_CohFrictPhys...

neverErase(=false)

Keep interactions even if particles go away from each other (only in case another constitutive law is in the scene, e.g. Law2_ScGeom_CapillaryPhys_Capillarity)

shear_creep(=false)

activate creep on the shear force, using CohesiveFrictionalContactLaw::creep_viscosity.

twist_creep(=false)

activate creep on the twisting moment, using CohesiveFrictionalContactLaw::creep_viscosity.

class yade.wrapper.Law2_ScGeom_CpmPhys_Cpm(inherits LawFunctorFunctorSerializable)

An experimental version of Law2_Dem3DofGeom_CpmPhys_Cpm which uses ScGeom instead of Dem3DofGeom.

omegaThreshold(=1., >=1. to deactivate, i.e. never delete any contacts)

damage after which the contact disappears (<1), since omega reaches 1 only for strain →+∞

class yade.wrapper.Law2_ScGeom_FrictPhys_CundallStrack(inherits LawFunctorFunctorSerializable)

Law for linear compression, and Mohr-Coulomb plasticity surface without cohesion. This law implements the classical linear elastic-plastic law from [CundallStrack1979] (see also [Pfc3dManual30]). The normal force is (with the convention of positive tensile forces) F_n=\min(k_n u_n, 0). The shear force is F_s=k_s u_s, the plasticity condition defines the maximum value of the shear force : F_s^{\max}=F_n\tan(\phi), with \phi the friction angle.

Note

This law uses ScGeom; there is also functionally equivalent Law2_Dem3DofGeom_FrictPhys_CundallStrack, which uses Dem3DofGeom (sphere-box interactions are not implemented for the latest).

Note

This law is well tested in the context of triaxial simulation, and has been used for a number of published results (see e.g. [Scholtes2009b] and other papers from the same authors). It is generalised by Law2_ScGeom_CohFrictPhys_CohesionMoment, which adds cohesion and moments at contact.

neverErase(=false)

Keep interactions even if particles go away from each other (only in case another constitutive law is in the scene, e.g. Law2_ScGeom_CapillaryPhys_Capillarity)

class yade.wrapper.Law2_ScGeom_MindlinPhys_HertzWithLinearShear(inherits LawFunctorFunctorSerializable)

Constitutive law for the Hertz formulation (using MindlinPhys.kno) and linear beahvior in shear (using MindlinPhys.kso for stiffness and FrictPhys.tangensOfFrictionAngle).

Note

No viscosity or damping. If you need those, look at Law2_ScGeom_MindlinPhys_Mindlin, which also includes non-linear Mindlin shear.

nonLin(=0)

Shear force nonlinearity (the value determines how many features of the non-linearity are taken in account). 1: ks as in HM 2: shearElastic increment computed as in HM 3. granular ratcheting disabled.

class yade.wrapper.Law2_ScGeom_MindlinPhys_Mindlin(inherits LawFunctorFunctorSerializable)

Constitutive law for the Hertz-Mindlin formulation. It includes non linear elasticity in the normal direction as predicted by Hertz for two non-conforming elastic contact bodies. In the shear direction, instead, it reseambles the simplified case without slip discussed in Mindlin’s paper, where a linear relationship between shear force and tangential displacement is provided. Finally, the Mohr-Coulomb criterion is employed to established the maximum friction force which can be developed at the contact. Moreover, it is also possible to include the effect of linear viscous damping through the definition of the parameters \beta_{n} and \beta_{s}.

calcEnergy(=false)

bool to calculate energy terms (shear potential energy, dissipation of energy due to friction and dissipation of energy due to normal and tangential damping)

contactsAdhesive() → float

Compute total number of adhesive contacts.

frictionDissipation(=uninitalized)

Energy dissipation due to sliding

includeAdhesion(=false)

bool to include the adhesion force following the DMT formulation. If true, also the normal elastic energy takes into account the adhesion effect.

normDampDissip(=uninitalized)

Energy dissipation due to sliding

normElastEnergy() → float

Compute normal elastic potential energy. It handle the DMT formulation if Law2_ScGeom_MindlinPhys_Mindlin::includeAdhesion is set to true.

preventGranularRatcheting(=true)

bool to avoid granular ratcheting

shearDampDissip(=uninitalized)

Energy dissipation due to sliding

shearEnergy(=uninitalized)

Shear elastic potential energy

class yade.wrapper.Law2_ScGeom_MindlinPhys_MindlinDeresiewitz(inherits LawFunctorFunctorSerializable)

Hertz-Mindlin contact law with partial slip solution, as described in [Thornton1991].

class yade.wrapper.Law2_ScGeom_ViscElPhys_Basic(inherits LawFunctorFunctorSerializable)

Linear viscoelastic model operating on ScGeom and ViscElPhys.

LawDispatcher

class yade.wrapper.LawDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((IGeom)arg2, (IPhys)arg3) → LawFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

Callbacks

BodyCallback

digraph BodyCallback {
        rankdir=RL;
        margin=.2;
        "BodyCallback" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.BodyCallback"];
        "SumBodyForcesCb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.SumBodyForcesCb"];
        "SumBodyForcesCb" -> "BodyCallback" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.BodyCallback(inherits Serializable)

Abstract callback object which will be called for every Body after being processed by NewtonIntegrator. See IntrCallback for details.

class yade.wrapper.SumBodyForcesCb(inherits BodyCallbackSerializable)

Callback summing magnitudes of resultant forces over dynamic bodies.

IntrCallback

digraph IntrCallback {
        rankdir=RL;
        margin=.2;
        "IntrCallback" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.IntrCallback"];
        "SumIntrForcesCb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.SumIntrForcesCb"];
        "SumIntrForcesCb" -> "IntrCallback" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.IntrCallback(inherits Serializable)

Abstract callback object which will be called for every (real) Interaction after the interaction has been processed by InteractionLoop.

At the beginning of the interaction loop, stepInit is called, initializing the object; it returns either NULL (to deactivate the callback during this time step) or pointer to function, which will then be passed (1) pointer to the callback object itself and (2) pointer to Interaction.

Note

(NOT YET DONE) This functionality is accessible from python by passing 4th argument to InteractionLoop constructor, or by appending the callback object to InteractionLoop::callbacks.

class yade.wrapper.SumIntrForcesCb(inherits IntrCallbackSerializable)

Callback summing magnitudes of forces over all interactions. IPhys of interactions must derive from NormShearPhys (responsability fo the user).

Preprocessors

digraph FileGenerator {
        rankdir=RL;
        margin=.2;
        "FileGenerator" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.FileGenerator"];
        "CapillaryTriaxialTest" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CapillaryTriaxialTest"];
        "CapillaryTriaxialTest" -> "FileGenerator" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "CohesiveTriaxialTest" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.CohesiveTriaxialTest"];
        "CohesiveTriaxialTest" -> "FileGenerator" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "SimpleShear" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.SimpleShear"];
        "SimpleShear" -> "FileGenerator" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "TriaxialTest" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.TriaxialTest"];
        "TriaxialTest" -> "FileGenerator" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.FileGenerator(inherits Serializable)

Base class for scene generators, preprocessors.

generate((str)out) → None

Generate scene, save to given file

load() → None

Generate scene, save to temporary file and load immediately

class yade.wrapper.CapillaryTriaxialTest(inherits FileGeneratorSerializable)

This preprocessor is a variant of TriaxialTest, including the model of capillary forces developed as part of the PhD of Luc Scholtès. See the documentation of Law2_ScGeom_CapillaryPhys_Capillarity or the main page https://yade-dem.org/wiki/CapillaryTriaxialTest, for more details.

Results obtained with this preprocessor were reported for instance in ‘Scholtes et al. Micromechanics of granular materials with capillary effects. International Journal of Engineering Science 2009,(47)1, 64-75.’

CapillaryPressure(=0)

Define succion in the packing [Pa]. This is the value used in the capillary model.

Key(="")

A code that is added to output filenames.

Rdispersion(=0.3)

Normalized standard deviation of generated sizes.

StabilityCriterion(=0.01)

Value of unbalanced force for which the system is considered stable. Used in conditionals to switch between loading stages.

WallStressRecordFile(="./WallStressesWater"+Key)

autoCompressionActivation(=true)

Do we just want to generate a stable packing under isotropic pressure (false) or do we want the triaxial loading to start automatically right after compaction stage (true)?

autoStopSimulation(=false)

freeze the simulation when conditions are reached (don’t activate this if you want to be able to run/stop from Qt GUI)

autoUnload(=true)

auto adjust the isotropic stress state from TriaxialTest::sigmaIsoCompaction to TriaxialTest::sigmaLateralConfinement if they have different values. See docs for TriaxialCompressionEngine::autoUnload

biaxial2dTest(=false)

FIXME : what is that?

binaryFusion(=true)

Defines how overlapping bridges affect the capillary forces (see CapillaryTriaxialTest::fusionDetection). If binary=true, the force is null as soon as there is an overlap detected, if not, the force is divided by the number of overlaps.

boxFrictionDeg(=0.0)

Friction angle [°] of boundaries contacts.

boxKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for boxes.

boxWalls(=true)

Use boxes for boundaries (recommended).

boxYoungModulus(=15000000.0)

Stiffness of boxes.

capillaryStressRecordFile(="./capStresses"+Key)

compactionFrictionDeg(=sphereFrictionDeg)

Friction angle [°] of spheres during compaction (different values result in different porosities)]. This value is overridden by TriaxialTest::sphereFrictionDeg before triaxial testing.

contactStressRecordFile(="./contStresses"+Key)

dampingForce(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of forces)

dampingMomentum(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of torques)

defaultDt(=0.0001)

Max time-step. Used as initial value if defined. Latter adjusted by the time stepper.

density(=2600)

density of spheres

facetWalls(=false)

Use facets for boundaries (not tested)

finalMaxMultiplier(=1.001)

max multiplier of diameters during internal compaction (secondary precise adjustment)

fixedBoxDims(="")

string that contains some subset (max. 2) of {‘x’,’y’,’z’} ; contains axes will have box dimension hardcoded, even if box is scaled as mean_radius is prescribed: scaling will be applied on the rest.

fixedPoroCompaction(=false)

flag to choose an isotropic compaction until a fixed porosity choosing a same translation speed for the six walls

fixedPorosity(=1)

FIXME : what is that?

fusionDetection(=false)

test overlaps between liquid bridges on modify forces if overlaps exist

importFilename(="")

File with positions and sizes of spheres.

internalCompaction(=false)

flag for choosing between moving boundaries or increasing particles sizes during the compaction stage.

lowerCorner(=Vector3r(0, 0, 0))

Lower corner of the box.

maxMultiplier(=1.01)

max multiplier of diameters during internal compaction (initial fast increase)

maxWallVelocity(=10)

max velocity of boundaries. Usually useless, but can help stabilizing the system in some cases.

noFiles(=false)

Do not create any files during run (.xml, .spheres, wall stress records)

numberOfGrains(=400)

Number of generated spheres.

radiusControlInterval(=10)

interval between size changes when growing spheres.

radiusMean(=-1)

Mean radius. If negative (default), autocomputed to as a function of box size and TriaxialTest::numberOfGrains

recordIntervalIter(=20)

interval between file outputs

sigmaIsoCompaction(=50000)

Confining stress during isotropic compaction.

sigmaLateralConfinement(=50000)

Lateral stress during triaxial loading. An isotropic unloading is performed if the value is not equal to CapillaryTriaxialTest::SigmaIsoCompaction.

sphereFrictionDeg(=18.0)

Friction angle [°] of spheres assigned just before triaxial testing.

sphereKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for spheres.

sphereYoungModulus(=15000000.0)

Stiffness of spheres.

strainRate(=1)

Strain rate in triaxial loading.

thickness(=0.001)

thickness of boundaries. It is arbitrary and should have no effect

timeStepOutputInterval(=50)

interval for outputing general information on the simulation (stress,unbalanced force,...)

timeStepUpdateInterval(=50)

interval for GlobalStiffnessTimeStepper

upperCorner(=Vector3r(1, 1, 1))

Upper corner of the box.

wallOversizeFactor(=1.3)

Make boundaries larger than the packing to make sure spheres don’t go out during deformation.

wallStiffnessUpdateInterval(=10)

interval for updating the stiffness of sample/boundaries contacts

wallWalls(=false)

Use walls for boundaries (not tested)

water(=true)

activate capillary model

class yade.wrapper.CohesiveTriaxialTest(inherits FileGeneratorSerializable)

This preprocessor is a variant of TriaxialTest using the cohesive-frictional contact law with moments. It sets up a scene for cohesive triaxial tests. See full documentation at http://yade-dem.org/wiki/TriaxialTest.

Cohesion is initially 0 by default. The suggested usage is to define cohesion values in a second step, after isotropic compaction : define shear and normal cohesions in Ip2_2xCohFrictMat_CohFrictPhys, then turn Ip2_2xCohFrictMat_CohFrictPhys::setCohesionNow true to assign them at each contact at next iteration.

Key(="")

A code that is added to output filenames.

StabilityCriterion(=0.01)

Value of unbalanced force for which the system is considered stable. Used in conditionals to switch between loading stages.

WallStressRecordFile(="./CohesiveWallStresses"+Key)

autoCompressionActivation(=true)

Do we just want to generate a stable packing under isotropic pressure (false) or do we want the triaxial loading to start automatically right after compaction stage (true)?

autoStopSimulation(=false)

freeze the simulation when conditions are reached (don’t activate this if you want to be able to run/stop from Qt GUI)

autoUnload(=true)

auto adjust the isotropic stress state from TriaxialTest::sigmaIsoCompaction to TriaxialTest::sigmaLateralConfinement if they have different values. See docs for TriaxialCompressionEngine::autoUnload

biaxial2dTest(=false)

FIXME : what is that?

boxFrictionDeg(=0.0)

Friction angle [°] of boundaries contacts.

boxKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for boxes.

boxWalls(=true)

Use boxes for boundaries (recommended).

boxYoungModulus(=15000000.0)

Stiffness of boxes.

compactionFrictionDeg(=sphereFrictionDeg)

Friction angle [°] of spheres during compaction (different values result in different porosities)]. This value is overridden by TriaxialTest::sphereFrictionDeg before triaxial testing.

dampingForce(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of forces)

dampingMomentum(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of torques)

defaultDt(=0.001)

Max time-step. Used as initial value if defined. Latter adjusted by the time stepper.

density(=2600)

density of spheres

facetWalls(=false)

Use facets for boundaries (not tested)

finalMaxMultiplier(=1.001)

max multiplier of diameters during internal compaction (secondary precise adjustment)

fixedBoxDims(="")

string that contains some subset (max. 2) of {‘x’,’y’,’z’} ; contains axes will have box dimension hardcoded, even if box is scaled as mean_radius is prescribed: scaling will be applied on the rest.

fixedPoroCompaction(=false)

flag to choose an isotropic compaction until a fixed porosity choosing a same translation speed for the six walls

fixedPorosity(=1)

FIXME : what is that?

importFilename(="")

File with positions and sizes of spheres.

internalCompaction(=false)

flag for choosing between moving boundaries or increasing particles sizes during the compaction stage.

lowerCorner(=Vector3r(0, 0, 0))

Lower corner of the box.

maxMultiplier(=1.01)

max multiplier of diameters during internal compaction (initial fast increase)

maxWallVelocity(=10)

max velocity of boundaries. Usually useless, but can help stabilizing the system in some cases.

noFiles(=false)

Do not create any files during run (.xml, .spheres, wall stress records)

normalCohesion(=0)

Material parameter used to define contact strength in tension.

numberOfGrains(=400)

Number of generated spheres.

radiusControlInterval(=10)

interval between size changes when growing spheres.

radiusDeviation(=0.3)

Normalized standard deviation of generated sizes.

radiusMean(=-1)

Mean radius. If negative (default), autocomputed to as a function of box size and TriaxialTest::numberOfGrains

recordIntervalIter(=20)

interval between file outputs

setCohesionOnNewContacts(=false)

create cohesionless (False) or cohesive (True) interactions for new contacts.

shearCohesion(=0)

Material parameter used to define shear strength of contacts.

sigmaIsoCompaction(=50000)

Confining stress during isotropic compaction.

sigmaLateralConfinement(=50000)

Lateral stress during triaxial loading. An isotropic unloading is performed if the value is not equal to TriaxialTest::sigmaIsoCompaction.

sphereFrictionDeg(=18.0)

Friction angle [°] of spheres assigned just before triaxial testing.

sphereKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for spheres.

sphereYoungModulus(=15000000.0)

Stiffness of spheres.

strainRate(=0.1)

Strain rate in triaxial loading.

thickness(=0.001)

thickness of boundaries. It is arbitrary and should have no effect

timeStepUpdateInterval(=50)

interval for GlobalStiffnessTimeStepper

upperCorner(=Vector3r(1, 1, 1))

Upper corner of the box.

wallOversizeFactor(=1.3)

Make boundaries larger than the packing to make sure spheres don’t go out during deformation.

wallStiffnessUpdateInterval(=10)

interval for updating the stiffness of sample/boundaries contacts

wallWalls(=false)

Use walls for boundaries (not tested)

class yade.wrapper.SimpleShear(inherits FileGeneratorSerializable)

Preprocessor for creating a numerical model of a simple shear box.

  • Boxes (6) constitute the different sides of the box itself
  • Spheres are contained in the box. The sample could be generated via the same method used in TriaxialTest Preprocesor (=> see GenerateCloud) or by reading a text file containing positions and radii of a sample (=> see ImportCloud). This last one is the one by default used by this PreProcessor as it is written here => you need to have such a file.
Thanks to the Engines (in pkg/common/Engine/PartialEngine) KinemCNDEngine, KinemCNSEngine and KinemCNLEngine, respectively constant normal displacement, constant normal rigidity and constant normal stress are possible to execute over such samples.

NB about micro-parameters : their values correspond to those used in [Duriez2009a].

boxPoissonRatio(=0.04)

value of ElastMat::poisson for the spheres [-]

boxYoungModulus(=4.0e9)

value of ElastMat::young for the boxes [Pa]

density(=2600)

density of the spheres [kg/m^3]

filename(="../porosite0_44.txt")

file with the list of spheres centers and radii

gravApplied(=false)

depending on this, GravityEngine is added or not to the scene to take into account the weight of particles

gravity(=Vector3r(0, -9.81, 0))

vector corresponding to used gravity [m/s^2]

height(=0.02)

initial height (along y-axis) of the shear box [m]

length(=0.1)

initial length (along x-axis) of the shear box [m]

sphereFrictionDeg(=37)

value of ElastMat::poisson for the spheres [^\circ] (the necessary conversion in rad is done automatically)

spherePoissonRatio(=0.04)

value of ElastMat::poisson for the spheres [-]

sphereYoungModulus(=4.0e9)

value of ElastMat::young for the spheres [Pa]

thickness(=0.001)

thickness of the boxes constituting the shear box [m]

timeStepUpdateInterval(=50)

value of TimeStepper::timeStepUpdateInterval for the TimeStepper used here

width(=0.04)

initial width (along z-axis) of the shear box [m]

class yade.wrapper.TriaxialTest(inherits FileGeneratorSerializable)

Create a scene for triaxal test.

Introduction

Yade includes tools to simulate triaxial tests on particles assemblies. This pre-processor (and variants like e.g. CapillaryTriaxialTest) illustrate how to use them. It generates a scene which will - by default - go through the following steps :

  • generate random loose packings in a parallelepiped.
  • compress the packing isotropicaly, either squeezing the packing between moving rigid boxes or expanding the particles while boxes are fixed (depending on flag internalCompaction). The confining pressure in this stage is defined via sigmaIsoCompaction.
  • when the packing is dense and stable, simulate a loading path and get the mechanical response as a result.

The default loading path corresponds to a constant lateral stress (sigmaLateralConfinement) in 2 directions and constant strain rate on the third direction. This default loading path is performed when the flag autoCompressionActivation it True, otherwise the simulation stops after isotropic compression.

Different loading paths might be performed. In order to define them, the user can modify the flags found in engine TriaxialStressController at any point in the simulation (in c++). If TriaxialStressController.wall_X_activated is true boundary X is moved automatically to maintain the defined stress level sigmaN (see axis conventions below). If false the boundary is not controlled by the engine at all. In that case the user is free to prescribe fixed position, constant velocity, or more complex conditions.

Note

Axis conventions. Boundaries perpendicular to the x axis are called “left” and “right”, y corresponds to “top” and “bottom”, and axis z to “front” and “back”. In the default loading path, strain rate is assigned along y, and constant stresses are assigned on x and z.

Essential engines
  1. The TrixaialCompressionEngine is used for controlling the state of the sample and simulating loading paths. TriaxialCompressionEngine inherits from TriaxialStressController, which computes stress- and strain-like quantities in the packing and maintain a constant level of stress at each boundary. TriaxialCompressionEngine has few more members in order to impose constant strain rate and control the transition between isotropic compression and triaxial test. Transitions are defined by changing some flags of the TriaxialStressController, switching from/to imposed strain rate to/from imposed stress.
  2. The class TriaxialStateRecorder is used to write to a file the history of stresses and strains.
  3. TriaxialTest is using GlobalStiffnessTimeStepper to compute an appropriate \Dt for the numerical scheme.

Note

TriaxialStressController::ComputeUnbalancedForce returns a value that can be useful for evaluating the stability of the packing. It is defined as (mean force on particles)/(mean contact force), so that it tends to 0 in a stable packing. This parameter is checked by TriaxialCompressionEngine to switch from one stage of the simulation to the next one (e.g. stop isotropic confinment and start axial loading)

Frequently Asked Questions

  1. How is generated the packing? How to change particles sizes distribution? Why do I have a message “Exceeded 3000 tries to insert non-overlapping sphere?

    The initial positioning of spheres is done by generating random (x,y,z) in a box and checking if a sphere of radius R (R also randomly generated with respect to a uniform distribution between mean*(1-std_dev) and mean*(1+std_dev) can be inserted at this location without overlaping with others.

    If the sphere overlaps, new (x,y,z)’s are generated until a free position for the new sphere is found. This explains the message you have: after 3000 trial-and-error, the sphere couldn’t be placed, and the algorithm stops.

    You get the message above if you try to generate an initialy dense packing, which is not possible with this algorithm. It can only generate clouds. You should keep the default value of porosity (n~0.7), or even increase if it is still to low in some cases. The dense state will be obtained in the second step (compaction, see below).

  2. How is the compaction done, what are the parameters maxWallVelocity and finalMaxMultiplier?
    Compaction is done
    1. by moving rigid boxes or
    2. by increasing the sizes of the particles (decided using the option internalCompaction ⇒ size increase).

    Both algorithm needs numerical parameters to prevent instabilities. For instance, with the method (1) maxWallVelocity is the maximum wall velocity, with method (2) finalMaxMultiplier is the max value of the multiplier applied on sizes at each iteration (always something like 1.00001).

  3. During the simulation of triaxial compression test, the wall in one direction moves with an increment of strain while the stresses in other two directions are adjusted to sigma_iso. How the stresses in other directions are maintained constant to sigma_iso? What is the mechanism? Where is it implemented in Yade?

    The control of stress on a boundary is based on the total stiffness K of all contacts between the packing and this boundary. In short, at each step, displacement=stress_error/K. This algorithm is implemented in TriaxialStressController, and the control itself is in TriaxialStressController::ControlExternalStress. The control can be turned off independently for each boundary, using the flags wall_XXX_activated, with XXX∈{top, bottom, left, right, back, front}. The imposed sress is a unique value (sigma_iso) for all directions if TriaxialStressController.isAxisymetric, or 3 independent values sigma1, sigma2, sigma3.

  4. Which value of friction angle do you use during the compaction phase of the Triaxial Test?

    The friction during the compaction (whether you are using the expansion method or the compression one for the specimen generation) can be anything between 0 and the final value used during the Triaxial phase. Note that higher friction than the final one would result in volumetric collapse at the beginning of the test. The purpose of using a different value of friction during this phase is related to the fact that the final porosity you get at the end of the sample generation essentially depends on it as well as on the assumed Particle Size Distribution. Changing the initial value of friction will get to a different value of the final porosity.

  5. Which is the aim of the bool isRadiusControlIteration?

    This internal variable (updated automatically) is true each N timesteps (with N=radiusControlInterval). For other timesteps, there is no expansion. Cycling without expanding is just a way to speed up the simulation, based on the idea that 1% increase each 10 iterations needs less operations than 0.1% at each iteration, but will give similar results.

  6. How comes the unbalanced force reaches a low value only after many timesteps in the compaction phase?

    The value of unbalanced force (dimensionless) is expected to reach low value (i.e. identifying a static-equilibrium condition for the specimen) only at the end of the compaction phase. The code is not aiming at simulating a quasistatic isotropic compaction process, it is only giving a stable packing at the end of it.

Key(="")

A code that is added to output filenames.

StabilityCriterion(=0.01)

Value of unbalanced force for which the system is considered stable. Used in conditionals to switch between loading stages.

WallStressRecordFile(="./WallStresses"+Key)

autoCompressionActivation(=true)

Do we just want to generate a stable packing under isotropic pressure (false) or do we want the triaxial loading to start automatically right after compaction stage (true)?

autoStopSimulation(=false)

freeze the simulation when conditions are reached (don’t activate this if you want to be able to run/stop from Qt GUI)

autoUnload(=true)

auto adjust the isotropic stress state from TriaxialTest::sigmaIsoCompaction to TriaxialTest::sigmaLateralConfinement if they have different values. See docs for TriaxialCompressionEngine::autoUnload

biaxial2dTest(=false)

FIXME : what is that?

boxFrictionDeg(=0.0)

Friction angle [°] of boundaries contacts.

boxKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for boxes.

boxYoungModulus(=15000000.0)

Stiffness of boxes.

compactionFrictionDeg(=sphereFrictionDeg)

Friction angle [°] of spheres during compaction (different values result in different porosities)]. This value is overridden by TriaxialTest::sphereFrictionDeg before triaxial testing.

dampingForce(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of forces)

dampingMomentum(=0.2)

Coefficient of Cundal-Non-Viscous damping (applied on on the 3 components of torques)

defaultDt(=-1)

Max time-step. Used as initial value if defined. Latter adjusted by the time stepper.

density(=2600)

density of spheres

facetWalls(=false)

Use facets for boundaries (not tested)

finalMaxMultiplier(=1.001)

max multiplier of diameters during internal compaction (secondary precise adjustment)

fixedBoxDims(="")

string that contains some subset (max. 2) of {‘x’,’y’,’z’} ; contains axes will have box dimension hardcoded, even if box is scaled as mean_radius is prescribed: scaling will be applied on the rest.

importFilename(="")

File with positions and sizes of spheres.

internalCompaction(=false)

flag for choosing between moving boundaries or increasing particles sizes during the compaction stage.

lowerCorner(=Vector3r(0, 0, 0))

Lower corner of the box.

maxMultiplier(=1.01)

max multiplier of diameters during internal compaction (initial fast increase)

maxWallVelocity(=10)

max velocity of boundaries. Usually useless, but can help stabilizing the system in some cases.

noFiles(=false)

Do not create any files during run (.xml, .spheres, wall stress records)

numberOfGrains(=400)

Number of generated spheres.

radiusControlInterval(=10)

interval between size changes when growing spheres.

radiusMean(=-1)

Mean radius. If negative (default), autocomputed to as a function of box size and TriaxialTest::numberOfGrains

radiusStdDev(=0.3)

Normalized standard deviation of generated sizes.

recordIntervalIter(=20)

interval between file outputs

sigmaIsoCompaction(=50000)

Confining stress during isotropic compaction.

sigmaLateralConfinement(=50000)

Lateral stress during triaxial loading. An isotropic unloading is performed if the value is not equal to TriaxialTest::sigmaIsoCompaction.

sphereFrictionDeg(=18.0)

Friction angle [°] of spheres assigned just before triaxial testing.

sphereKsDivKn(=0.5)

Ratio of shear vs. normal contact stiffness for spheres.

sphereYoungModulus(=15000000.0)

Stiffness of spheres.

strainRate(=0.1)

Strain rate in triaxial loading.

thickness(=0.001)

thickness of boundaries. It is arbitrary and should have no effect

timeStepUpdateInterval(=50)

interval for GlobalStiffnessTimeStepper

upperCorner(=Vector3r(1, 1, 1))

Upper corner of the box.

wallOversizeFactor(=1.3)

Make boundaries larger than the packing to make sure spheres don’t go out during deformation.

wallStiffnessUpdateInterval(=10)

interval for updating the stiffness of sample/boundaries contacts

wallWalls(=false)

Use walls for boundaries (not tested)

Rendering

OpenGLRenderer

class yade.wrapper.OpenGLRenderer(inherits Serializable)

Class responsible for rendering scene on OpenGL devices.

bgColor(=Vector3r(.2, .2, .2))

Color of the background canvas (RGB)

bound(=false)

Render body Bound

clipPlaneActive(=vector<bool>(numClipPlanes, false))

Activate/deactivate respective clipping planes

clipPlaneSe3(=vector<Se3r>(numClipPlanes, Se3r(Vector3r::Zero(), Quaternionr::Identity())))

Position and orientation of clipping planes

dispScale(=Vector3r::Ones(), disable scaling)

Artificially enlarge (scale) dispalcements from bodies’ reference positions by this relative amount, so that they become better visible (independently in 3 dimensions). Disbled if (1,1,1).

dof(=false)

Show which degrees of freedom are blocked for each body

extraDrawers(=uninitalized)

Additional rendering components (GlExtraDrawer).

id(=false)

Show body id’s

intrAllWire(=false)

Draw wire for all interactions, blue for potential and green for real ones (mostly for debugging)

intrGeom(=false)

Render Interaction::geom objects.

intrPhys(=false)

Render Interaction::phys objects

intrWire(=false)

If rendering interactions, use only wires to represent them.

lightPos(=Vector3r(75, 130, 0))

Position of OpenGL light source in the scene.

mask(=~0, draw everything)

Bitmask for showing only bodies where ((mask & Body::mask)!=0)

render() → None

Render the scene in the current OpenGL context.

rotScale(=1., disable scaling)

Artificially enlarge (scale) rotations of bodies relative to their reference orientation, so the they are better visible.

selId(=Body::ID_NONE)

Id of particle that was selected by the user.

setRefSe3() → None

Make current positions and orientation reference for scaleDisplacements and scaleRotations.

shape(=true)

Render body Shape

wire(=false)

Render all bodies with wire only (faster)

GlShapeFunctor

digraph GlShapeFunctor {
        rankdir=RL;
        margin=.2;
        "GlShapeFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlShapeFunctor"];
        "Gl1_Sphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Sphere"];
        "Gl1_Sphere" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Tetra" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Tetra"];
        "Gl1_Tetra" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Wall" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Wall"];
        "Gl1_Wall" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Facet" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Facet"];
        "Gl1_Facet" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Box" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Box"];
        "Gl1_Box" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_ChainedCylinder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_ChainedCylinder"];
        "Gl1_ChainedCylinder" -> "Gl1_Cylinder" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Cylinder" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Cylinder"];
        "Gl1_Cylinder" -> "GlShapeFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.GlShapeFunctor(inherits FunctorSerializable)

Abstract functor for rendering Shape objects.

class yade.wrapper.Gl1_Box(inherits GlShapeFunctorFunctorSerializable)

Renders Box object

class yade.wrapper.Gl1_ChainedCylinder(inherits Gl1_CylinderGlShapeFunctorFunctorSerializable)

Renders ChainedCylinder object including a shift for compensating flexion.

class yade.wrapper.Gl1_Cylinder(inherits GlShapeFunctorFunctorSerializable)

Renders Cylinder object

wire(=false) [static]

Only show wireframe (controlled by glutSlices and glutStacks.

glutNormalize(=true) [static]

Fix normals for non-wire rendering

glutSlices(=8) [static]

Number of sphere slices.

glutStacks(=4) [static]

Number of sphere stacks.

class yade.wrapper.Gl1_Facet(inherits GlShapeFunctorFunctorSerializable)

Renders Facet object

normals(=false) [static]

In wire mode, render normals of facets and edges; facet’s colors are disregarded in that case.

class yade.wrapper.Gl1_Sphere(inherits GlShapeFunctorFunctorSerializable)

Renders Sphere object

wire(=false) [static]

Only show wireframe (controlled by glutSlices and glutStacks.

stripes(=false) [static]

In non-wire rendering, show stripes clearly showing particle rotation.

glutNormalize(=true) [static]

Fix normals for non-wire rendering; see http://lists.apple.com/archives/Mac-opengl/2002/Jul/msg00085.html

glutSlices(=12) [static]

Number of sphere slices; not used with stripes (see glut{Solid,Wire}Sphere reference)

glutStacks(=6) [static]

Number of sphere stacks; not used with stripes (see glut{Solid,Wire}Sphere reference)

class yade.wrapper.Gl1_Tetra(inherits GlShapeFunctorFunctorSerializable)

Renders Tetra object

class yade.wrapper.Gl1_Wall(inherits GlShapeFunctorFunctorSerializable)

Renders Wall object

div(=20) [static]

Number of divisions of the wall inside visible scene part.

GlStateFunctor

class yade.wrapper.GlStateFunctor(inherits FunctorSerializable)

Abstract functor for rendering State objects.

GlBoundFunctor

digraph GlBoundFunctor {
        rankdir=RL;
        margin=.2;
        "GlBoundFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlBoundFunctor"];
        "Gl1_Aabb" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Aabb"];
        "Gl1_Aabb" -> "GlBoundFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.GlBoundFunctor(inherits FunctorSerializable)

Abstract functor for rendering Bound objects.

class yade.wrapper.Gl1_Aabb(inherits GlBoundFunctorFunctorSerializable)

Render Axis-aligned bounding box (Aabb).

GlIGeomFunctor

digraph GlIGeomFunctor {
        rankdir=RL;
        margin=.2;
        "GlIGeomFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlIGeomFunctor"];
        "Gl1_Dem3DofGeom_SphereSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Dem3DofGeom_SphereSphere"];
        "Gl1_Dem3DofGeom_SphereSphere" -> "GlIGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Dem3DofGeom_FacetSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Dem3DofGeom_FacetSphere"];
        "Gl1_Dem3DofGeom_FacetSphere" -> "GlIGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_Dem3DofGeom_WallSphere" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_Dem3DofGeom_WallSphere"];
        "Gl1_Dem3DofGeom_WallSphere" -> "GlIGeomFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.GlIGeomFunctor(inherits FunctorSerializable)

Abstract functor for rendering IGeom objects.

class yade.wrapper.Gl1_Dem3DofGeom_FacetSphere(inherits GlIGeomFunctorFunctorSerializable)

Render interaction of facet and sphere (represented by Dem3DofGeom_FacetSphere)

normal(=false) [static]

Render interaction normal

rolledPoints(=false) [static]

Render points rolled on the sphere & facet (original contact point)

unrolledPoints(=false) [static]

Render original contact points unrolled to the contact plane

shear(=false) [static]

Render shear line in the contact plane

shearLabel(=false) [static]

Render shear magnitude as number

class yade.wrapper.Gl1_Dem3DofGeom_SphereSphere(inherits GlIGeomFunctorFunctorSerializable)

Render interaction of 2 spheres (represented by Dem3DofGeom_SphereSphere)

normal(=false) [static]

Render interaction normal

rolledPoints(=false) [static]

Render points rolled on the spheres (tracks the original contact point)

unrolledPoints(=false) [static]

Render original contact points unrolled to the contact plane

shear(=false) [static]

Render shear line in the contact plane

shearLabel(=false) [static]

Render shear magnitude as number

class yade.wrapper.Gl1_Dem3DofGeom_WallSphere(inherits GlIGeomFunctorFunctorSerializable)

Render interaction of wall and sphere (represented by Dem3DofGeom_WallSphere)

normal(=false) [static]

Render interaction normal

rolledPoints(=false) [static]

Render points rolled on the spheres (tracks the original contact point)

unrolledPoints(=false) [static]

Render original contact points unrolled to the contact plane

shear(=false) [static]

Render shear line in the contact plane

shearLabel(=false) [static]

Render shear magnitude as number

GlIPhysFunctor

digraph GlIPhysFunctor {
        rankdir=RL;
        margin=.2;
        "GlIPhysFunctor" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.GlIPhysFunctor"];
        "Gl1_CpmPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_CpmPhys"];
        "Gl1_CpmPhys" -> "GlIPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
        "Gl1_NormPhys" [shape="box",fontsize=8,style="setlinewidth(0.5),solid",height=0.2,URL="yade.wrapper.html#yade.wrapper.Gl1_NormPhys"];
        "Gl1_NormPhys" -> "GlIPhysFunctor" [arrowsize=0.5,style="setlinewidth(0.5)"];
}

class yade.wrapper.GlIPhysFunctor(inherits FunctorSerializable)

Abstract functor for rendering IPhys objects.

class yade.wrapper.Gl1_CpmPhys(inherits GlIPhysFunctorFunctorSerializable)

Render CpmPhys objects of interactions.

contactLine(=true) [static]

Show contact line

dmgLabel(=true) [static]

Numerically show contact damage parameter

dmgPlane(=false) [static]

[what is this?]

epsT(=false) [static]

Show shear strain

epsTAxes(=false) [static]

Show axes of shear plane

normal(=false) [static]

Show contact normal

colorStrainRatio(=-1) [static]

If positive, set the interaction (wire) color based on \eps_N normalized by \eps_0 × colorStrainRatio (\eps_0=:yref:CpmPhys.epsCrackOnset). Otherwise, color based on the residual strength.

epsNLabel(=false) [static]

Numerically show normal strain

class yade.wrapper.Gl1_NormPhys(inherits GlIPhysFunctorFunctorSerializable)

Renders NormPhys objects as cylinders of which diameter and color depends on NormPhys:normForce magnitude.

maxFn(=0) [static]

Value of NormPhys.normalForce corresponding to maxDiameter. This value will be increased (but not decreased) automatically.

signFilter(=0) [static]

If non-zero, only display contacts with negative (-1) or positive (+1) normal forces; if zero, all contacts will be displayed.

refRadius(=std::numeric_limits<Real>::infinity()) [static]

Reference (minimum) particle radius; used only if maxRadius is negative. This value will be decreased (but not increased) automatically. (auto-updated)

maxRadius(=-1) [static]

Cylinder radius corresponding to the maximum normal force. If negative, auto-updated refRadius will be used instead.

slices(=6) [static]

Number of sphere slices; (see glutCylinder reference)

stacks(=1) [static]

Number of sphere stacks; (see glutCylinder reference)

Simulation data

Omega

class yade.wrapper.Omega
bodies

Bodies in the current simulation (container supporting index access by id and iteration)

cell

Periodic cell of the current scene (None if the scene is aperiodic).

childClassesNonrecursive((str)arg2) → list

Return list of all classes deriving from given class, as registered in the class factory

disableGdb() → None

Revert SEGV and ABRT handlers to system defaults.

dt

Current timestep (Δt) value.

  • assigning negative value enables dynamic Δt (by looking for a TimeStepper in O.engine) and sets positive timestep O.dt=|Δt| (will be used until the timestepper is run and updates it)
  • assigning positive value sets Δt to that value and disables dynamic Δt (via TimeStepper, if there is one).

dynDt can be used to query whether dynamic Δt is in use.

dynDt

Whether a TimeStepper is used for dynamic Δt control. See dt on how to enable/disable TimeStepper.

dynDtAvailable

Whether a TimeStepper is amongst O.engines, activated or not.

energy

EnergyTracker of the current simulation. (meaningful only with O.trackEnergy)

engines

List of engines in the simulation (Scene::engines).

exitNoBacktrace([(int)status=0]) → None

Disable SEGV handler and exit, optionally with given status number.

filename

Filename under which the current simulation was saved (None if never saved).

forceSyncCount

Counter for number of syncs in ForceContainer, for profiling purposes.

forces

ForceContainer (forces, torques, displacements) in the current simulation.

initializers

List of initializers (Scene::initializers).

interactions

Interactions in the current simulation (container supporting index acces by either (id1,id2) or interactionNumber and iteration)

isChildClassOf((str)arg2, (str)arg3) → bool

Tells whether the first class derives from the second one (both given as strings).

iter

Get current step number

labeledEngine((str)arg2) → object

Return instance of engine/functor with the given label. This function shouldn’t be called by the user directly; every ehange in O.engines will assign respective global python variables according to labels.

For example:: O.engines=[InsertionSortCollider(label=’collider’)] collider.nBins=5 ## collider has become a variable after assignment to O.engines automatically)

load((str)arg2) → None

Load simulation from file.

loadTmp([(str)mark='']) → None

Load simulation previously stored in memory by saveTmp. mark optionally distinguishes multiple saved simulations

lsTmp() → list

Return list of all memory-saved simulations.

materials

Shared materials; they can be accessed by id or by label

miscParams

MiscParams in the simulation (Scene::mistParams), usually used to save serializables that don’t fit anywhere else, like GL functors

numThreads

Get maximum number of threads openMP can use.

pause() → None

Stop simulation execution. (May be called from within the loop, and it will stop after the current step).

periodic

Get/set whether the scene is periodic or not (True/False).

plugins() → list

Return list of all plugins registered in the class factory.

realtime

Return clock (human world) time the simulation has been running.

reload() → None

Reload current simulation

reset() → None

Reset simulations completely (including another scene!).

resetThisScene() → None

Reset current scene.

resetTime() → None

Reset simulation time: step number, virtual and real time. (Doesn’t touch anything else, including timings).

run([(int)nSteps=-1[, (bool)wait=False]]) → None

Run the simulation. nSteps how many steps to run, then stop (if positive); wait will cause not returning to python until simulation will have stopped.

runEngine((Engine)arg2) → None

Run given engine exactly once; simulation time, step number etc. will not be incremented (use only if you know what you do).

running

Whether background thread is currently running a simulation.

save((str)arg2) → None

Save current simulation to file (should be .xml or .xml.bz2)

saveTmp([(str)mark='']) → None

Save simulation to memory (disappears at shutdown), can be loaded later with loadTmp. mark optionally distinguishes different memory-saved simulations.

step() → None

Advance the simulation by one step. Returns after the step will have finished.

stopAtIter

Get/set number of iteration after which the simulation will stop.

subStep

Get the current subStep number (only meaningful if O.subStepping==True)

subStepping

Get/set whether subStepping is active.

switchScene() → None

Switch to alternative simulation (while keeping the old one). Calling the function again switches back to the first one. Note that most variables from the first simulation will still refer to the first simulation even after the switch (e.g. b=O.bodies[4]; O.switchScene(); [b still refers to the body in the first simulation here])

tags

Tags (string=string dictionary) of the current simulation (container supporting string-index access/assignment)

time

Return virtual (model world) time of the simulation.

timingEnabled

Globally enable/disable timing services (see documentation of the timing module).

tmpFilename() → str

Return unique name of file in temporary directory which will be deleted when yade exits.

tmpToFile((str)fileName[, (str)mark='']) → None

Save XML of saveTmp‘d simulation into fileName.

tmpToString([(str)mark='']) → str

Return XML of saveTmp‘d simulation as string.

trackEnergy

When energy tracking is enabled or disabled in this simulation.

wait() → None

Don’t return until the simulation will have been paused. (Returns immediately if not running).

BodyContainer

class yade.wrapper.BodyContainer
__init__((BodyContainer)arg2) → None
append((Body)arg2) → int
Append one Body instance, return its id.
append( (BodyContainer)arg1, (object)arg2) → object :
Append list of Body instance, return list of ids
appendClumped((object)arg2) → tuple

Append given list of bodies as a clump (rigid aggregate); return list of ids.

clear() → None

Remove all bodies (interactions not checked)

clump((object)arg2) → int

Clump given bodies together (creating a rigid aggregate); returns clump id.

erase((int)arg2) → bool

Erase body with the given id; all interaction will be deleted by InteractionLoop in the next step.

replace((object)arg2) → object

InteractionContainer

class yade.wrapper.InteractionContainer

Access to interactions of simulation, by using

  1. id’s of both Bodies of the interactions, e.g. O.interactions[23,65]

  2. iteraction over the whole container:

    for i in O.interactions: print i.id1,i.id2
    

Note

Iteration silently skips interactions that are not real.

__init__((InteractionContainer)arg2) → None
clear() → None

Remove all interactions

countReal() → int

Return number of interactions that are “real”, i.e. they have phys and geom.

erase((int)arg2, (int)arg3) → None

Erase one interaction, given by id1, id2 (internally, requestErase is called – the interaction might still exist as potential, if the Collider decides so).

eraseNonReal() → None

Erase all interactions that are not real .

nth((int)arg2) → Interaction

Return n-th interaction from the container (usable for picking random interaction).

serializeSorted
withBody((int)arg2) → list

Return list of real interactions of given body.

withBodyAll((int)arg2) → list

Return list of all (real as well as non-real) interactions of given body.

ForceContainer

class yade.wrapper.ForceContainer
__init__((ForceContainer)arg2) → None
addF((int)id, (Vector3)f) → None

Apply force on body (accumulates).

addMove((int)id, (Vector3)m) → None

Apply displacement on body (accumulates).

addRot((int)id, (Vector3)r) → None

Apply rotation on body (accumulates).

addT((int)id, (Vector3)t) → None

Apply torque on body (accumulates).

f((int)id) → Vector3

Force applied on body.

m((int)id) → Vector3

Deprecated alias for t (torque).

move((int)id) → Vector3

Displacement applied on body.

rot((int)id) → Vector3

Rotation applied on body.

syncCount

Number of synchronizations of ForceContainer (cummulative); if significantly higher than number of steps, there might be unnecessary syncs hurting performance.

t((int)id) → Vector3

Torque applied on body.

MaterialContainer

class yade.wrapper.MaterialContainer

Container for Materials. A material can be accessed using

  1. numerical index in range(0,len(cont)), like cont[2];
  2. textual label that was given to the material, like cont[‘steel’]. This etails traversing all materials and should not be used frequently.
__init__((MaterialContainer)arg2) → None
append((Material)arg2) → int
Add new shared Material; changes its id and return it.
append( (MaterialContainer)arg1, (object)arg2) → object :
Append list of Material instances, return list of ids.
index((str)arg2) → int

Return id of material, given its label.

Scene

class yade.wrapper.Scene(inherits Serializable)

Object comprising the whole simulation.

dt(=1e-8)

Current timestep for integration.

isPeriodic(=false)

Whether periodic boundary conditions are active.

iter(=0)

Current iteration (computational step) number

needsInitializers(=true)

Whether initializers will be run before the first step.

selectedBody(=-1)

Id of body that is selected by the user

stopAtIter(=0)

Iteration after which to stop the simulation.

subStep(=-1)

Number of sub-step; not to be changed directly. -1 means to run loop prologue (cell integration), 0…n-1 runs respective engines (n is number of engines), n runs epilogue (increment step number and time.

subStepping(=false)

Whether we currently advance by one engine in every step (rather than by single run through all engines).

tags(=uninitalized)

Arbitrary key=value associations (tags like mp3 tags: author, date, version, description etc.)

time(=0)

Simulation time (virtual time) [s]

trackEnergy(=false)

Whether energies are being traced.

Cell

class yade.wrapper.Cell(inherits Serializable)

Parameters of periodic boundary conditions. Only applies if O.isPeriodic==True.

Hsize(=Matrix3r::Zero())

The current cell size (one column per box edge), computed from refSize and trsf (auto-updated)

homoDeform(=3)

Deform (velGrad) the cell homothetically, by adjusting positions or velocities of particles. The values have the following meaning: 0: no homothetic deformation, 1: set absolute particle positions directly (when velGrad is non-zero), but without changing their velocity, 2: adjust particle velocity (only when velGrad changed) with Δv_i=Δ ∇v x_i. 3: as 2, but include a 2nd order term in addition – the derivative of 1 (convective term in the velocity update).

prevVelGrad(=Matrix3r::Zero())

Velocity gradient in the previous step.

refSize(=Vector3r(1, 1, 1))

Reference size of the cell.

shearPt((Vector3)arg2) → Vector3

Apply shear (cell skew+rot) on the point

shearTrsf

Current skew+rot transformation (no resize)

size

Current size of the cell, i.e. lengths of 3 cell lateral vectors after applying current trsf. Update automatically at every step.

trsf(=Matrix3r::Identity())

Current transformation matrix of the cell.

unshearPt((Vector3)arg2) → Vector3

Apply inverse shear on the point (removes skew+rot of the cell)

unshearTrsf

Inverse of the current skew+rot transformation (no resize)

velGrad(=Matrix3r::Zero())

Velocity gradient of the transformation; used in NewtonIntegrator.

volume

Current volume of the cell.

wrap((Vector3)arg2) → Vector3

Transform an arbitrary point into a point in the reference cell

wrapPt((Vector3)arg2) → Vector3

Wrap point inside the reference cell, assuming the cell has no skew+rot.

Other classes

class yade.wrapper.Engine(inherits Serializable)

Basic execution unit of simulation, called from the simulation loop (O.engines)

dead(=false)

If true, this engine will not run at all; can be used for making an engine temporarily deactivated and only resurrect it at a later point.

execCount

Cummulative count this engine was run (only used if O.timingEnabled==True).

execTime

Cummulative time this Engine took to run (only used if O.timingEnabled==True).

label(=uninitalized)

Textual label for this object; must be valid python identifier, you can refer to it directly from python.

timingDeltas

Detailed information about timing inside the Engine itself. Empty unless enabled in the source code and O.timingEnabled==True.

class yade.wrapper.Cell(inherits Serializable)

Parameters of periodic boundary conditions. Only applies if O.isPeriodic==True.

Hsize(=Matrix3r::Zero())

The current cell size (one column per box edge), computed from refSize and trsf (auto-updated)

homoDeform(=3)

Deform (velGrad) the cell homothetically, by adjusting positions or velocities of particles. The values have the following meaning: 0: no homothetic deformation, 1: set absolute particle positions directly (when velGrad is non-zero), but without changing their velocity, 2: adjust particle velocity (only when velGrad changed) with Δv_i=Δ ∇v x_i. 3: as 2, but include a 2nd order term in addition – the derivative of 1 (convective term in the velocity update).

prevVelGrad(=Matrix3r::Zero())

Velocity gradient in the previous step.

refSize(=Vector3r(1, 1, 1))

Reference size of the cell.

shearPt((Vector3)arg2) → Vector3

Apply shear (cell skew+rot) on the point

shearTrsf

Current skew+rot transformation (no resize)

size

Current size of the cell, i.e. lengths of 3 cell lateral vectors after applying current trsf. Update automatically at every step.

trsf(=Matrix3r::Identity())

Current transformation matrix of the cell.

unshearPt((Vector3)arg2) → Vector3

Apply inverse shear on the point (removes skew+rot of the cell)

unshearTrsf

Inverse of the current skew+rot transformation (no resize)

velGrad(=Matrix3r::Zero())

Velocity gradient of the transformation; used in NewtonIntegrator.

volume

Current volume of the cell.

wrap((Vector3)arg2) → Vector3

Transform an arbitrary point into a point in the reference cell

wrapPt((Vector3)arg2) → Vector3

Wrap point inside the reference cell, assuming the cell has no skew+rot.

class yade.wrapper.TimingDeltas
data

Get timing data as list of tuples (label, execTime[nsec], execCount) (one tuple per checkpoint)

reset() → None

Reset timing information

class yade.wrapper.GlIGeomDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((IGeom)arg2) → GlIGeomFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

class yade.wrapper.ParallelEngine(inherits EngineSerializable)

Engine for running other Engine in parallel.

__init__() → None

object __init__(tuple args, dict kwds)

__init__((list)arg2) → object :
Construct from (possibly nested) list of slaves.
slaves

List of lists of Engines; each top-level group will be run in parallel with other groups, while Engines inside each group will be run sequentially, in given order.

class yade.wrapper.GlShapeDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((Shape)arg2) → GlShapeFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

class yade.wrapper.Functor(inherits Serializable)

Function-like object that is called by Dispatcher, if types of arguments match those the Functor declares to accept.

bases

Ordered list of types (as strings) this functor accepts.

label(=uninitalized)

Textual label for this object; must be valid python identifier, you can refer to it directly fron python (must be a valid python identifier).

timingDeltas

Detailed information about timing inside the Dispatcher itself. Empty unless enabled in the source code and O.timingEnabled==True.

class yade.wrapper.Serializable
dict() → dict

Return dictionary of attributes.

name
updateAttrs((dict)arg2) → None

Update object attributes from given dictionary

class yade.wrapper.GlExtra_LawTester(inherits GlExtraDrawerSerializable)

Find an instance of LawTester and show visually its data.

tester(=uninitalized)

Associated LawTester object.

class yade.wrapper.GlStateDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((State)arg2) → GlStateFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

class yade.wrapper.MatchMaker(inherits Serializable)

Class matching pair of ids to return pre-defined or derived value of a scalar parameter.

Note

There is a converter from python number defined for this class, which creates a new MatchMaker returning the value of that number; instead of giving the object instance therefore, you can only pass the number value and it will be converted automatically.

computeFallback((float)val1, (float)val2) → float

Compute fallback value for val1 and val2, using algorithm specified by fallback.

fallback

Alogorithm used to compute value when no match for ids is found. Possible values are * ‘avg’ (arithmetic average) * ‘min’ (minimum value) * ‘max’ (maximum value) * ‘harmAvg’ (harmonic average)

The following fallback algorithms do not require meaningful input values in order to work: * ‘val’ (return value specified by val) * ‘zero’ (return 0.)

matches(=uninitalized)

Array of (id1,id2,value) items; queries matching id1``+``id2 or id2``+``id1 will return value

val(=NaN)

Constant value returned if there is no match and fallback is val

class yade.wrapper.GlBoundDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((Bound)arg2) → GlBoundFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

class yade.wrapper.GlIPhysDispatcher(inherits DispatcherEngineSerializable)

Dispatcher calling functors based on received argument type(s).

dispFunctor((IPhys)arg2) → GlIPhysFunctor

Return functor that would be dispatched for given argument(s); None if no dispatch; ambiguous dispatch throws.

dispMatrix([(bool)names=True]) → dict

Return dictionary with contents of the dispatch matrix.

functors

Functors associated with this dispatcher.

class yade.wrapper.GlExtraDrawer(inherits Serializable)

Performing arbitrary OpenGL drawing commands; called from OpenGLRenderer (see OpenGLRenderer.extraDrawers) once regular rendering routines will have finished.

This class itself does not render anything, derived classes should override the render method.

dead(=false)

Deactivate the object (on error/exception).

class yade.wrapper.Dispatcher(inherits EngineSerializable)

Engine dispatching control to its associated functors, based on types of argument it receives. This abstract base class provides no functionality in itself.

class yade.wrapper.EnergyTracker(inherits Serializable)

Storage for tracing energies. Only to be used if O.traceEnergy is True.

clear() → None

Clear all stored values.

energies(=uninitalized)

Energy values, in linear array

keys() → list

Return defined energies.