Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference

ID 767251
Date 3/22/2024
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

EPSILON

Inquiry Intrinsic Function (Generic): Returns a positive model number that is almost negligible compared to unity in the model representing real numbers.

result = EPSILON (x)

x

(Input) Must be of type real; it can be scalar or array valued.

Results

The result is a scalar of the same type and kind parameters as x. The result has the value b 1-p. Parameters b and p are defined in Model for Real Data.

EPSILON makes it easy to select a delta for algorithms (such as root locators) that search until the calculation is within delta of an estimate. If delta is too small (smaller than the decimal resolution of the data type), the algorithm might never halt. By scaling the value returned by EPSILON to the estimate, you obtain a delta that ensures search termination.

Example

If x is of type REAL(4), EPSILON (X) has the value 2 -23.