Documentation Center

  • Trial Software
  • Product Updates

Contents

sfix

Create Simulink.NumericType object describing signed fixed-point data type

Syntax

a = sfix(WordLength)

Description

sfix(WordLength) returns a Simulink.NumericType object that describes a signed fixed-point number with the specified word length and unspecified scaling.

    Note:   sfix is a legacy function. In new code, use fixdt instead. In existing code, replace sfix(WordLength) with fixdt(1,WordLength).

Examples

Define a 16-bit signed fixed-point data type.

a = sfix(16)
a = 

  NumericType with properties:

    DataTypeMode: 'Fixed-point: unspecified scaling'
      Signedness: 'Signed'
      WordLength: 16
         IsAlias: 0
       DataScope: 'Auto'
      HeaderFile: ''
     Description: ''

See Also

| | | | | | |

Was this topic helpful?