ansys.dpf.core.operators.math.minus_fc#
- class ansys.dpf.core.operators.math.minus_fc(field_or_fields_container_A=None, field_or_fields_container_B=None, config=None, server=None)#
Bases:
ansys.dpf.core.dpf_operator.Operator
Computes the difference of two fields. If one field’s scoping has an ‘overall’ location, then this field’s values are applied on the other field entirely. When using a constant or ‘work_by_index’, you can use ‘inplace’ to reuse one of the fields.
- Parameters:
field_or_fields_container_A (Field or FieldsContainer or float) – field or fields container with only one field is expected
field_or_fields_container_B (Field or FieldsContainer or float) – field or fields container with only one field is expected
- Returns:
fields_container
- Return type:
Examples
>>> from ansys.dpf import core as dpf
>>> # Instantiate operator >>> op = dpf.operators.math.minus_fc()
>>> # Make input connections >>> my_field_or_fields_container_A = dpf.Field() >>> op.inputs.field_or_fields_container_A.connect(my_field_or_fields_container_A) >>> my_field_or_fields_container_B = dpf.Field() >>> op.inputs.field_or_fields_container_B.connect(my_field_or_fields_container_B)
>>> # Instantiate operator and connect inputs in one line >>> op = dpf.operators.math.minus_fc( ... field_or_fields_container_A=my_field_or_fields_container_A, ... field_or_fields_container_B=my_field_or_fields_container_B, ... )
>>> # Get output data >>> result_fields_container = op.outputs.fields_container()
- _inputs#
- _outputs#
- static _spec() ansys.dpf.core.operators.specification.Specification #
- static default_config(server: ansys.dpf.core.server_types.AnyServerType = None) ansys.dpf.core.config.Config #
Returns the default config of the operator.
This config can then be changed to the user needs and be used to instantiate the operator. The Configuration allows to customize how the operation will be processed by the operator.
- Parameters:
server – Server with channel connected to the remote or local instance. When
None
, attempts to use the global server.- Returns:
A new Config instance equivalent to the default config for this operator.
- Return type:
config
- property inputs: InputsMinusFc#
Enables to connect inputs to the operator
- Returns:
An instance of InputsMinusFc.
- Return type:
inputs
- property outputs: OutputsMinusFc#
Enables to get outputs of the operator by evaluating it
- Returns:
An instance of OutputsMinusFc.
- Return type:
outputs