CFDBall

class itasca.ball.cfd.CFDBall
Objects of this type should not be created (instantiated) directly in Python. Use the module functions that return instances of this type.
ball() → Ball object.

Get the ball corresponding to this CFD ball.

elements() → tuple of CFD element objects.

Get a tuple of CFD elements associated with a CFD ball.

extra(slot: int) → any.

Get the CFD ball extra data in the given slot.

force() → vec.

Get the CFD ball fluid force (vector).

force_x() → float.

Get the x-component of the CFD ball fluid force.

force_y() → float.

Get the y-component of the CFD ball fluid force.

force_z() → float.

Get the z-component of the CFD ball fluid force.

group([slot: str or int]) → str.

Get the CFD ball group name in a given slot.

group_remove(group_name: str or int[, slot: str or int]) → int.

Remove from the given group from the CFD ball. One argument of type string, giving the group name, is required. The return value is an integer which is the first slot in which the group name was found or -1 if not found.

groups() → tuple of strings.

Get a tuple of group names assigned to this CFD ball.

id() → int.

Get the CFD ball id.

in_group(group_name: str or int[, slot: str or int]) → bool.

Test if the CFD ball is part of a given group. All group slots are searched.

overlaps() → tuple of floats.

Get a tuple of the volumes of overlap between this ball and the CFD elements. The volumes returned correspond to the elements returned by the elements method.

pos() → vec.

Get the CFD ball location (vector).

pos_x() → float.

Get the x-component of the CFD ball location.

pos_y() → float.

Get the y-component of the CFD ball location.

pos_z() → float.

Get the z-component of the CFD ball location.

set_extra(slot: int, value: any) → None.

Set the CFD ball extra data in the given slot.

set_force(value: vec) → None.

Set the CFD ball fluid force (vector).

set_force_x(value: float) → None.

Set the x-component of the CFD ball fluid force.

set_force_y(value: float) → None.

Set the y-component of the CFD ball fluid force.

set_force_z(value: float) → None.

Set the z-component of the CFD ball fluid force.

set_group([group_name: str or int[, slot: str or int]]) → None.

Set the CFD ball group name in a given slot.

set_pos(value: vec) → None.

Set the CFD ball location (vector).

set_pos_x(value: float) → None.

Set the x-component of the CFD ball location.

set_pos_y(value: float) → None.

Set the y-component of the CFD ball location.

set_pos_z(value: float) → None.

Set the z-component of the CFD ball location.

valid() → bool.

Returns True if this CFD ball is live.