scalarBinOpUpdater
Works with VSimBase, VSimEM, VSimPD, VSimPA, and VSimMD licenses.
MultiField updater that applies a mathematical operation on two
scalars (A1 and A2) specified through the readScalars
parameter, and writes the result to the writeScalars
parameter.
The scalarBinOpUpdater takes the following parameters:
readScalars (required string vector)
A vector of the names of the two scalars on which to operate.
writeScalars (required string vector)
A vector containing a single element, the name of scalar to update.
binOp (required string)
Operation to apply to the scalars; one of add
,
subtract
, multiply
or divide
. Operations
are:
add: (aCoeff*A1)+(bCoeff*A2)
subtract: (aCoeff*A1)-(bCoeff*A2)
multiply: (aCoeff+A1)*(bCoeff+A2)
divide: (aCoeff+A1)/(bCoeff+A2)
aCoeff (optional float)
Coefficient for first scalar (A1, as described above). Default values:
add: 1.0
subtract: 1.0
multiply: 0.0
divide: 0.0
bCoeff (optional float)
Coefficient for second scalar (A2, as described above). Default values:
add: 1.0
subtract: 1.0
multiply: 0.0
divide: 0.0
<Updater scalarAdd>
kind = scalarBinOpUpdater
binOp = add
readScalars = [A1 A2]
writeScalars = [A2]
aCoeff = 1.5
bCoeff = 0.5
</Updater>