Classes namespace¶
Classes.Assembly module¶
Classes.FEM module¶
-
class
Classes.FEM.BeamMesh(Namestr, ElemType, Radius, TypeStr, PosStr, NodeList=[], ElemList=[], Node0=1, Elem0=1)[source]¶ Bases:
object
Classes.Geometry module¶
-
class
Classes.Geometry.Order3Base(e1=[1, 0, 0], e2=[0, 1, 0], e3=[0, 0, 1], BuildFromThis=False)[source]¶ Bases:
objectUsed to store 3D linear algebra bases three attribues: e1, e2 and e3, corresponding to the three vectors
The vector given as entry will always be normalized
__getitem__() is defined so that you can call an axis by its index or char reference (x, y or z)
Classes.Path module¶
-
class
Classes.Path.path(Lx=[], Ly=[], Lz=[])[source]¶ Bases:
object-
Init3DHelix(theta, DirectionParam, Pitch, Nby, Dbyin, Dbyout, PlaitSegments)[source]¶ Credits to Louis for most of the code in this function, most of it comes from a matlab script he had written that I converted in Python
-
Init3DSinus(LinearMatrix, Lengh, NbPoints, Omega, Phi, R0, Cth, Th0, OffX=0, OffY=0, OffZ=0)[source]¶ The linear matrix parameter is defined as follow:
- [[Cx,Cy,Cz],
- [Ax,Ay,Az]]
Équation paramétrique de la droite {x = Cx*t+Ax;y = Cy*t+Ay;z = Cz*t+Az}
Équation du sinus: définie en coordonées cylindriques autour de x x -> x ; y -> r sin(theta) ; y -> r cos(theta) {r = R0*sin(Omega*x+Phi), theta = Cth*x+Th0}
OffX, OffY and OffZ are used to add offset to the filaments generate (between each filament in a strand for example)
-
Classes.RigidBodies module¶
-
class
Classes.RigidBodies.Pulley(Name, Density, ShapeString, ShapeArgs, RotInertiaMatrix=None, CenterPoint=[0, 0, 0], RotVect=[0, 0, 0], **kwargs)[source]¶ Bases:
Classes.RigidBodies.rigid_BodySubclass of rigid_Body, used to define pulleys.
New attributes: ShapeString –> defines the type of pulley, admissible values are “Cyl” (Cylinder), “V” (Vshape contact surface), “U” (U shape contact surface) and “I” (Cylinder with borders)
ShapeArgs –> Tuple used to specify the shape-related parameters
-
class
Classes.RigidBodies.SquareSectionBar(Name, Density, ShapeArgs, RotInertiaMatrix=None, CenterPoint=[0, 0, 0], RotVect=[0, 0, 0])[source]¶
-
Classes.RigidBodies.random() → x in the interval [0, 1).¶
Classes.Wired_Structures module¶
-
class
Classes.Wired_Structures.Braid(Pitch, Nby, Dbyin, BraidThickness, PlaitSegments, R, Config=['Beam', None], SparsingCoeff=0, Imposed_FilR=None, **kwargs)[source]¶ Bases:
inPy.Classes.Assembly.InstanceClass used to represent a braid, mandatory parameters are Pitch, Nby (number of strands, must always be even), Dbyin (internal radius) BraidThickness (Thickness of the braid), PlaitSegments (discretization of each beam) and R (number of radiuses in each strand).
Valid optional paramters are:
Config—> Array used to configure the embeded beams configuration [2x1], Config[0] gives the external elements type, Config[1] give the internal element Type For exampleConfig = ["Truss",None]will configure inPy to only use Truss elements,Config = ["Truss","Beam"]is the default embeded beam situation with external truss and internal beams, default to [“Beam”,None]SparsingCoeffthis parameter will be changed in future version, right now, it controlls the circlespacking call and defines the gap between each filaments center the smallest distance between each filament is defined as d = (1 + Filament_Diameter)*SparsingCoeff, default to 0Imposed_FilRallows the user to specify a filament radius, default to None and in this case, the filament radius is defined as BraidThickness/2*R**kwargs–> used to defined the Instance master-class attributes if needed-
Draw(SectionFunction=<function circlespacking>, Secargs=None, standalone=True, fig=None)[source]¶ Draws the braid for preview purposes, depends on the plot backend chosen by the end-user
Valid parameters:
SectionFunction–> python function that will be call on**SceargsThe section function should remains as default for now since the braid object is not yet compatible with other section shapes.Secargs–> tuple of arguments for the section function, if None, this will be set to (self.R,self.BundleR,self.SparsingCoeff)standalone—> parameter that should always appear in draw functions for inPy.Instance subclasses, if True (default) the plot will be shown directly, if False, a figure object is returnedfig—> this is used if you want to add the braid to a previously existing figure object
-
circlespacking(yarnR, SparsingCoeff=0)¶
-
-
class
Classes.Wired_Structures.Strand(InitShapeFunction, PathGenerationFunction, Line, Shargs=None, Shkwargs=None, Pthargs=None, Pthkwargs=None, **kwargs)[source]¶ Bases:
object-
class
path(Lx=[], Ly=[], Lz=[])¶ Bases:
object-
Init3DHelix(theta, DirectionParam, Pitch, Nby, Dbyin, Dbyout, PlaitSegments)¶ Credits to Louis for most of the code in this function, most of it comes from a matlab script he had written that I converted in Python
-
Init3DSinus(LinearMatrix, Lengh, NbPoints, Omega, Phi, R0, Cth, Th0, OffX=0, OffY=0, OffZ=0)¶ The linear matrix parameter is defined as follow:
- [[Cx,Cy,Cz],
- [Ax,Ay,Az]]
Équation paramétrique de la droite {x = Cx*t+Ax;y = Cy*t+Ay;z = Cz*t+Az}
Équation du sinus: définie en coordonées cylindriques autour de x x -> x ; y -> r sin(theta) ; y -> r cos(theta) {r = R0*sin(Omega*x+Phi), theta = Cth*x+Th0}
OffX, OffY and OffZ are used to add offset to the filaments generate (between each filament in a strand for example)
-
InitLinear(LinearMatrix, Lengh, NbPoints, OffX=0, OffY=0, OffZ=0)¶ Équation paramétrique de la droite {x = Cx*t+Ax;y = Cy*t+Ay;z = Cz*t+Az}
-
MakeNodeList(ID0=0, R=0, YarnR=0, SparsingCoeff=0)¶
-
-
class