## numerictype of Fixed-Point Objects

### Valid Values for `numerictype` Object Properties

The `numerictype` object contains all the data type and scaling attributes of a fixed-point object. The `numerictype` object behaves like any MATLAB® object, except that it only lets you set valid values for defined fields. The following table shows the possible settings of each field of the object.

Note

When you create a `fi` object, any unspecified field of the `numerictype` object reverts to its default value. Thus, if the `DataTypeMode` is set to `unspecified scaling`, it defaults to `binary point scaling` when the `fi` object is created. If the `Signedness` property of the `numerictype` object is set to `Auto`, it defaults to `Signed` when the `fi` object is created.

DataTypeModeDataTypeScalingSignednessWord-
Length
Fraction-
Length
SlopeBias

Fixed-point data types

```Fixed-point: binary point scaling```

`Fixed`

`BinaryPoint`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

Positive or negative integer

2^(-fraction length)

`0`

```Fixed-point: slope and bias scaling```

`Fixed`

`SlopeBias`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

`N/A`

Any floating- point number greater than zero

Any floating- point number

```Fixed-point: unspecified scaling```

`Fixed`

`Unspecified`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

`N/A`

`N/A`

`N/A`

Scaled double data types

```Scaled double: binary point scaling```

`ScaledDouble`

`BinaryPoint`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

Positive or negative integer

2^(-fraction length)

`0`

```Scaled double: slope and bias scaling```

`ScaledDouble`

`SlopeBias`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

`N/A`

Any floating- point number greater than zero

Any floating- point number

```Scaled double: unspecified scaling```

`ScaledDouble`

`Unspecified`

`Signed`
`Unsigned`
`Auto`

Positive integer from 1 to 65,535

`N/A`

`N/A`

`N/A`

Built-in data types

`Double`

`double`

`N/A`

`1`
`true`

`64`

`0`

`1`

`0`

`Single`

`single`

`N/A`

`1`
`true`

`32`

`0`

`1`

`0`

`Boolean`

`boolean`

`N/A`

`0`
`false`

`1`

`0`

`1`

`0`

You cannot change the `numerictype` properties of a `fi` object after `fi` object creation.

### Properties That Affect the Slope

The Slope field of the `numerictype` object is related to the `SlopeAdjustmentFactor` and `FixedExponent` properties by

`$slope=slopeadjustmentfactor×{2}^{fixedexponent}$`

The `FixedExponent` and `FractionLength` properties are related by

`$fixedexponent=-fractionlength$`

If you set the `SlopeAdjustmentFactor`, `FixedExponent`, or `FractionLength` property, the Slope field is modified.

### Stored Integer Value and Real World Value

In binary point scaling the `numerictype` `StoredIntegerValue` and `RealWorldValue` properties are related according to

`$real\text{-}worldvalue=storedintegervalue×{2}^{-fractionlength}$`

In [Slope Bias] scaling the `RealWorldValue` can be represented by

which is equivalent to

`$real\text{-}worldvalue=\left(slope×storedinteger\right)+bias$`

If any of these properties are updated, the others are modified accordingly.