public class FloatForce extends AbstractFloatScalarRel<ForceUnit,FloatForce>
FloatScalar.Rel<ForceUnit> value = new FloatScalar.Rel<ForceUnit>(100.0, ForceUnit.SI);we can now write:
FloatForce value = new FloatForce(100.0, ForceUnit.SI);The compiler will automatically recognize which units belong to which quantity, and whether the quantity type and the unit used are compatible.
Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See DJUNITS License.
$LastChangedDate: 2019-01-18 00:35:01 +0100 (Fri, 18 Jan 2019) $, @version $Revision: 324 $, by $Author: averbraeck $,
initial version Sep 5, 2015
Modifier and Type | Field and Description |
---|---|
static FloatForce |
NaN
constant with value NaN.
|
static FloatForce |
NEG_MAXVALUE
constant with value -MAX_VALUE.
|
static FloatForce |
NEGATIVE_INFINITY
constant with value NEGATIVE_INFINITY.
|
static FloatForce |
POS_MAXVALUE
constant with value MAX_VALUE.
|
static FloatForce |
POSITIVE_INFINITY
constant with value POSITIVE_INFINITY.
|
static FloatForce |
ZERO
constant with value zero.
|
si
Constructor and Description |
---|
FloatForce(double value,
ForceUnit unit)
Construct FloatForce scalar using a double value.
|
FloatForce(FloatForce value)
Construct FloatForce scalar.
|
FloatForce(float value,
ForceUnit unit)
Construct FloatForce scalar.
|
Modifier and Type | Method and Description |
---|---|
static FloatForce |
createSI(float value)
Construct FloatForce scalar.
|
FloatMass |
divideBy(FloatAcceleration v)
Calculate the division of FloatForce and FloatAcceleration, which results in a FloatMass scalar.
|
FloatPressure |
divideBy(FloatArea v)
Calculate the division of FloatForce and FloatArea, which results in a FloatPressure scalar.
|
FloatLinearDensity |
divideBy(FloatEnergy v)
Calculate the division of FloatForce and FloatEnergy, which results in a FloatLinearDensity scalar.
|
FloatDimensionless |
divideBy(FloatForce v)
Calculate the division of FloatForce and FloatForce, which results in a FloatDimensionless scalar.
|
FloatEnergy |
divideBy(FloatLinearDensity v)
Calculate the division of FloatForce and FloatLinearDensity, which results in a FloatEnergy scalar.
|
FloatAcceleration |
divideBy(FloatMass v)
Calculate the division of FloatForce and FloatMass, which results in a FloatAcceleration scalar.
|
FloatArea |
divideBy(FloatPressure v)
Calculate the division of FloatForce and FloatPressure, which results in a FloatArea scalar.
|
FloatForce |
instantiateRel(float value,
ForceUnit unit)
Construct a new Relative Immutable FloatScalar of the right type.
|
static FloatForce |
interpolate(FloatForce zero,
FloatForce one,
float ratio)
Interpolate between two values.
|
static FloatForce |
max(FloatForce r1,
FloatForce r2)
Return the maximum value of two relative scalars.
|
static FloatForce |
max(FloatForce r1,
FloatForce r2,
FloatForce... rn)
Return the maximum value of more than two relative scalars.
|
static FloatForce |
min(FloatForce r1,
FloatForce r2)
Return the minimum value of two relative scalars.
|
static FloatForce |
min(FloatForce r1,
FloatForce r2,
FloatForce... rn)
Return the minimum value of more than two relative scalars.
|
FloatEnergy |
multiplyBy(FloatLength v)
Calculate the multiplication of FloatForce and FloatLength, which results in a FloatEnergy scalar.
|
FloatPower |
multiplyBy(FloatSpeed v)
Calculate the multiplication of FloatForce and FloatSpeed, which results in a FloatPower scalar.
|
abs, ceil, divideBy, floor, minus, multiplyBy, neg, plus, rint, round
compareTo, doubleValue, eq, eq0, equals, floatValue, ge, ge0, getInUnit, getInUnit, getSI, gt, gt0, hashCode, intValue, le, le0, longValue, lt, lt0, ne, ne0, toString, toString, toString, toString
expressAsSIUnit, expressAsSpecifiedUnit, getUnit, isAbsolute, isRelative, setDisplayUnit
byteValue, shortValue
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
DIV, MULT, POW
public static final FloatForce ZERO
public static final FloatForce NaN
public static final FloatForce POSITIVE_INFINITY
public static final FloatForce NEGATIVE_INFINITY
public static final FloatForce POS_MAXVALUE
public static final FloatForce NEG_MAXVALUE
public FloatForce(float value, ForceUnit unit)
value
- float; float valueunit
- ForceUnit; unit for the float valuepublic FloatForce(FloatForce value)
value
- FloatForce; Scalar from which to construct this instancepublic FloatForce(double value, ForceUnit unit)
value
- double; double valueunit
- ForceUnit; unit for the resulting float valuepublic final FloatForce instantiateRel(float value, ForceUnit unit)
instantiateRel
in class AbstractFloatScalarRel<ForceUnit,FloatForce>
value
- float; the float valueunit
- U; the unitpublic static final FloatForce createSI(float value)
value
- float; float value in SI unitspublic static FloatForce interpolate(FloatForce zero, FloatForce one, float ratio)
zero
- FloatForce; the low valueone
- FloatForce; the high valueratio
- float; the ratio between 0 and 1, inclusivepublic static FloatForce max(FloatForce r1, FloatForce r2)
r1
- FloatForce; the first scalarr2
- FloatForce; the second scalarpublic static FloatForce max(FloatForce r1, FloatForce r2, FloatForce... rn)
r1
- FloatForce; the first scalarr2
- FloatForce; the second scalarrn
- FloatForce...; the other scalarspublic static FloatForce min(FloatForce r1, FloatForce r2)
r1
- FloatForce; the first scalarr2
- FloatForce; the second scalarpublic static FloatForce min(FloatForce r1, FloatForce r2, FloatForce... rn)
r1
- FloatForce; the first scalarr2
- FloatForce; the second scalarrn
- FloatForce...; the other scalarspublic final FloatDimensionless divideBy(FloatForce v)
v
- FloatForce; FloatForce scalarpublic final FloatEnergy multiplyBy(FloatLength v)
v
- FloatLength; FloatForce scalarpublic final FloatEnergy divideBy(FloatLinearDensity v)
v
- FloatLinearDensity; FloatForce scalarpublic final FloatLinearDensity divideBy(FloatEnergy v)
v
- FloatEnergy; FloatForce scalarpublic final FloatPower multiplyBy(FloatSpeed v)
v
- FloatSpeed; FloatForce scalarpublic final FloatAcceleration divideBy(FloatMass v)
v
- FloatMass; FloatForce scalarpublic final FloatMass divideBy(FloatAcceleration v)
v
- FloatAcceleration; FloatForce scalarpublic final FloatPressure divideBy(FloatArea v)
v
- FloatArea; FloatForce scalarpublic final FloatArea divideBy(FloatPressure v)
v
- FloatPressure; FloatForce scalarCopyright © 2015–2019 Delft University of Technology. All rights reserved.