org.djunits.value

Interface FunctionsAbs<AU extends AbsoluteLinearUnit<AU,RU>,RU extends Unit<RU>,A extends Absolute & Value<AU>,R extends Relative & Value<RU>>

• Method Summary

All Methods
Modifier and Type Method and Description
`R` `minus(A abs)`
Subtract an Absolute value from this Absolute value for a vector or matrix.
`A` `minus(R rel)`
Subtract a Relative value from this Absolute value for a vector or matrix.
`A` `plus(R rel)`
Add a Relative value to this Absolute value for a vector or matrix.
• Method Detail

• plus

```A plus(R rel)
throws ValueException```
Add a Relative value to this Absolute value for a vector or matrix. The addition is done value by value and the result is stored in a new Absolute value. If both operands are sparse, the result is a sparse vector or matrix, otherwise the result is a dense vector or matrix.
Parameters:
`rel` - R; R the right operand
Returns:
A the sum of this vector and the operand
Throws:
`ValueException` - in case this vector and the operand have a different size
• minus

```A minus(R rel)
throws ValueException```
Subtract a Relative value from this Absolute value for a vector or matrix. The subtraction is done value by value and the result is stored in a new Absolute value. If both operands are sparse, the result is a sparse vector or matrix, otherwise the result is a dense vector or matrix.
Parameters:
`rel` - R; R the right operand
Returns:
A the subtraction of this vector and the operand
Throws:
`ValueException` - in case this vector and the operand have a different size
• minus

```R minus(A abs)
throws ValueException```
Subtract an Absolute value from this Absolute value for a vector or matrix. The subtraction is done value by value and the result is stored in a new Relative value. If both operands are sparse, the result is a sparse vector or matrix, otherwise the result is a dense vector or matrix.
Parameters:
`abs` - A; A the right operand
Returns:
R the subtraction of this vector and the operand
Throws:
`ValueException` - in case this vector and the operand have a different size