BeamElement
- class compas_model.elements.BeamElement(width=0.1, depth=0.2, length=3.0, transformation=None, features=None, name=None)
Bases:
Element
Class representing a beam element with a square section, constructed from the WorldXY Frame. The beam is defined in its local frame, where the length corresponds to the Z-Axis, the depth to the Y-Axis, and the width to the X-Axis. By default, the local frame is set to WorldXY frame.
- Parameters:
- widthfloat
The width of the beam.
- depthfloat
The depth of the beam.
- lengthfloat
The length of the beam.
- transformationOptional[
compas.geometry.Transformation
] Transformation applied to the beam.
- featuresOptional[list[
compas_model.features.BeamFeature
]] Features of the beam.
- nameOptional[str]
If no name is defined, the class name is given.
- Attributes:
- box
compas.geometry.Box
The box geometry of the beam.
- widthfloat
The width of the beam.
- depthfloat
The depth of the beam.
- lengthfloat
The length of the beam.
- center_line
compas.geometry.Line
Line axis of the beam.
- box
Methods
Compute the axis-aligned bounding box of the element.
Compute the collision mesh of the element.
Compute the mesh shape from a box.
Compute the oriented bounding box of the element.
Compute the reference point of the beam from the centroid of its geometry.
Extend the beam.
Inherited Methods
Converts the instance to a string.
Add a feature to the list of features of the element.
Apply the features to the (base) geometry.
Computes the 2D FE analysis mesh of the element's model geometry.
Computes the 3D FE mesh of the element's model geometry.
Compute the geometry of the element in model coordinates and taking into account the effect of interactions with connected elements.
Compute the transformation to model coordinates of this element based on its position in the spatial hierarchy of the model.
Compute the contacts between this element and another element.
Make an independent copy of the data object.
Construct an object of this type from a JSON file.
Construct an object of this type from a JSON string.
Compute a hash of the data for comparison during version control using the sha256 algorithm.
Convert an object to its native data representation and save it to a JSON file.
Convert an object to its native data representation and save it to a JSON string.
Transforms the element.
Creates a transformed copy of the element.
Validate the data against the object's data schema.