InputsCentroid#

class ansys.dpf.core.operators.math.centroid.InputsCentroid(op: ansys.dpf.core.dpf_operator.Operator)#

Bases: ansys.dpf.core.inputs._Inputs

Intermediate class used to connect user inputs to centroid operator.

Examples

>>> from ansys.dpf import core as dpf
>>> op = dpf.operators.math.centroid()
>>> my_fieldA = dpf.Field()
>>> op.inputs.fieldA.connect(my_fieldA)
>>> my_fieldB = dpf.Field()
>>> op.inputs.fieldB.connect(my_fieldB)
>>> my_factor = float()
>>> op.inputs.factor.connect(my_factor)

Overview#

connect

Connect any input (an entity or an operator output) to any input pin of this operator.

fieldA

Allows to connect fieldA input to the operator.

fieldB

Allows to connect fieldB input to the operator.

factor

Allows to connect factor input to the operator.

Import detail#

from ansys.dpf.core.operators.math.centroid import InputsCentroid

Property detail#

property InputsCentroid.fieldA: ansys.dpf.core.inputs.Input#

Allows to connect fieldA input to the operator.

field or fields container with only one field is expected

Returns:

An Input instance for this pin.

Return type:

input

Examples

>>> from ansys.dpf import core as dpf
>>> op = dpf.operators.math.centroid()
>>> op.inputs.fieldA.connect(my_fieldA)
>>> # or
>>> op.inputs.fieldA(my_fieldA)
property InputsCentroid.fieldB: ansys.dpf.core.inputs.Input#

Allows to connect fieldB input to the operator.

field or fields container with only one field is expected

Returns:

An Input instance for this pin.

Return type:

input

Examples

>>> from ansys.dpf import core as dpf
>>> op = dpf.operators.math.centroid()
>>> op.inputs.fieldB.connect(my_fieldB)
>>> # or
>>> op.inputs.fieldB(my_fieldB)
property InputsCentroid.factor: ansys.dpf.core.inputs.Input#

Allows to connect factor input to the operator.

Scalar

Returns:

An Input instance for this pin.

Return type:

input

Examples

>>> from ansys.dpf import core as dpf
>>> op = dpf.operators.math.centroid()
>>> op.inputs.factor.connect(my_factor)
>>> # or
>>> op.inputs.factor(my_factor)

Method detail#

InputsCentroid.__str__()#
InputsCentroid.connect(inpt)#

Connect any input (an entity or an operator output) to any input pin of this operator.

Searches for the input type corresponding to the output.

Deprecated since version Deprecated: in favor of explicit output-to-input connections.

Parameters:
  • inpt (str, int, double, bool, list[int], list[float], Field, FieldsContainer, Scoping, Enum,)

  • ScopingsContainer (E501) – Input of the operator.

  • MeshedRegion (E501) – Input of the operator.

  • MeshesContainer (E501) – Input of the operator.

  • DataSources (E501) – Input of the operator.

  • CyclicSupport (E501) – Input of the operator.

  • Outputs (E501) – Input of the operator.

  • noqa (os.PathLike #) – Input of the operator.

InputsCentroid.__call__(inpt)#
InputsCentroid.__getitem__(item) Input#