Facet
-
class
itasca.wall.facet.
Facet
- Objects of this type should not be created (instantiated) directly in Python. Use the module functions that return instances of this type.
-
active
() → int. Get the facet activity code. The following codes apply: 0 - both sides are active; 1 - the top side (e.g., in the direction of the facet normal) is active; -1 - the bottom side of the facet is active; or 2 - neither side of the facet is active.
-
contact_count
(all=False, type=None) → int. Get the number of contacts associated with this Facet. If the optional keyword argument type is given, the count is limited to the contact types specified. The type keyword argument should be a Python type object (one of: itasca.BallBallContact, itasca.BallPebbleContact, itasca.PebblePebbleContact, itasca.BallFacetContact or itasca.PebbleFacetContact). If the (optional) keyword argument all is True the count includes virtual contacts.
-
contacts
([piece: object, ]all=False, type=None) → tuple of Contact objects. Get a tuple of contacts associated with this Facet. An optional argument can be included which is a piece object (a Ball, a Pebble or a Facet). If the optional keyword argument type is given, the returned list is limited to the contact types specified. The type keyword argument should be a Python type object (one of: itasca.BallBallContact, itasca.BallPebbleContact, itasca.PebblePebbleContact, itasca.BallFacetContact or itasca.PebbleFacetContact). If the (optional) keyword argument all is True the returned list includes virtual contacts.
-
conveyor
() → vec. Get the facet conveyor velocity (vector).
-
conveyor_x
() → float. Get the x-component of the facet conveyor velocity.
-
conveyor_y
() → float. Get the y-component of the facet conveyor velocity.
-
conveyor_z
() → float. Get the z-component of the facet conveyor velocity.
-
delete
() → None. Delete a facet. The wall position is automatically updated.
-
edge_neighbors
() → tuple of Facet objects. Get the neighboring facets. Neighboring facets are those sharing a {vertex in 2D; edge in 3D}. The tuple is length 3 in 3D and length 2 in 2D. Each position in the tuple contains either a Facet object or None if no facet is adjacent to that edge (point in 2d).
-
extra
(slot: int) → any. Get the facet extra data in the given slot.
-
group
([slot: str or int]) → str. Get the facet group name in a given slot.
-
group_remove
(group_name: str or int[, slot: str or int]) → bool. Remove from the given group from all group slots of the facet. One argument of type string, giving the group name, is required. The return value is a bool which is True if the group was removed from any slot, otherwise False.
-
groups
() → {slot: group_name}. Get a dictionary describing which groups this facet is part of. The keys of the dictionary are the slot names and the values are the group names.
-
has_prop
(property_name: str) → bool. Returns True if the facet has the given surface property.
-
id
() → int. Get the facet id.
-
in_group
(group_name: str or int[, slot: str or int]) → bool. Test if the facet is part of a given group. If the optional argument slot is given, only that slot is searched. Otherwise, all group slots are searched.
-
normal
() → vec. Get the facet normal direction (vector).
-
normal_x
() → float. Get the x-component of the facet normal direction.
-
normal_y
() → float. Get the y-component of the facet normal direction.
-
normal_z
() → float. Get the z-component of the facet normal direction.
-
point_near
(point: vec) → vec. Get the closest point on the facet to another point.
-
pos
() → vec. Get the facet location (vector).
-
pos_x
() → float. Get the x-component of the facet location.
-
pos_y
() → float. Get the y-component of the facet location.
-
pos_z
() → float. Get the z-component of the facet location.
-
prop
(property_name: str) → any. Get a surface property value of this facet.
-
props
() → dict {str: any}. Get a dictionary of all the surface properties of this facet.
-
set_active
(activity_code: int) → None. The following codes apply: 0 - both sides are active; 1 - the top side (e.g., in the direction of the facet normal) is active; -1 - the bottom side of the facet is active; or 2 - neither side of the facet is active.
-
set_conveyor
(value: vec) → None. Set the facet conveyor velocity (vector).
-
set_conveyor_x
(value: float) → None. Set the x-component of the facet conveyor velocity.
-
set_conveyor_y
(value: float) → None. Set the y-component of the facet conveyor velocity.
-
set_conveyor_z
(value: float) → None. Set the z-component of the facet conveyor velocity.
-
set_extra
(slot: int, value: any) → None. Set the facet extra data in the given slot.
-
set_group
(group_name: str or int[, slot: str or int]) → None. Set the facet group name in a given slot.
-
set_prop
(property_name: str, value: any) → None. Set a surface property of this facet.
-
valid
() → bool. Returns True if this facet is live.
-
vertices
() → tuple of WallVertex objects. Get the facet vertices.
-
wall
() → Wall object. Get the facet’s wall.
-
Was this helpful? ... | FLAC3D © 2019, Itasca | Updated: Feb 25, 2024 |