Package | Description |
---|---|
ptolemy.math |
Math classes.
|
Modifier and Type | Class and Description |
---|---|
static class |
Overflow.Grow
The grow overflow strategy.
|
static class |
Overflow.Minimize
The minimize overflow strategy.
|
static class |
Overflow.Modulo
The modulo overflow strategy.
|
static class |
Overflow.Saturate
The saturate overflows strategy.
|
static class |
Overflow.ToZero
The overflow to zero strategy.
|
static class |
Overflow.Trap
The trap overflows strategy.
|
Modifier and Type | Field and Description |
---|---|
protected Overflow |
Quantization._overflow
The overflow strategy.
|
static Overflow |
Quantizer.OVERFLOW_TO_ZERO
Indicate that overflow should result in a zero value.
|
static Overflow |
Quantizer.SATURATE
Indicate that overflow should saturate.
|
Modifier and Type | Method and Description |
---|---|
static Overflow |
Overflow.forName(java.lang.String name)
Return an instance of this class with the specified name.
|
static Overflow |
Overflow.getName(java.lang.String name)
Return an instance of this class with the specified name,
or null if none exists.
|
Overflow |
Quantization.getOverflow()
Return the overflow strategy.
|
Modifier and Type | Method and Description |
---|---|
static FixPoint |
Quantizer.round(FixPoint value,
Precision newPrecision,
Overflow mode)
Return the fixed point number that is nearest to the specified
value, but has the given precision, possibly introducing
quantization or overflow errors.
|
static FixPoint |
Quantizer.roundDown(FixPoint value,
Precision newPrecision,
Overflow mode)
Return the nearest fixed point number with less than or equal
magnitude that has the given precision, possibly introducing
quantization or overflow errors.
|
static FixPoint |
Quantizer.roundNearestEven(FixPoint value,
Precision newPrecision,
Overflow mode)
Return the fixed point number that is nearest to the specified
value, but has the given precision, possibly introducing
quantization or overflow errors.
|
static FixPoint |
Quantizer.roundToZero(FixPoint value,
Precision newPrecision,
Overflow mode)
Return the fixed point number that is nearest to the specified
value, but has magnitude no greater than the specified value,
and has the given precision, possibly introducing
quantization or overflow errors.
|
static FixPoint |
Quantizer.roundUp(FixPoint value,
Precision newPrecision,
Overflow mode)
Return the smallest greater than or equal fixed point number
that has the given precision, possibly introducing
quantization or overflow errors.
|
FixPointQuantization |
FixPointQuantization.setOverflow(Overflow overflow)
Return a FixPointQuantization with a changed overflow strategy.
|
static FixPoint |
Quantizer.truncate(FixPoint value,
Precision newPrecision,
Overflow mode)
Deprecated.
Use roundToZero instead.
|
Constructor and Description |
---|
FixPointQuantization(Precision precision,
Overflow overflow,
Rounding rounding)
Construct a FixPointQuantization with specified precision, overflow
and rounding.
|
Quantization(Overflow overflow,
Rounding rounding)
Construct a Quantization with the given precision, overflow
strategy, and rounding strategy.
|