OpenFAST
Wind turbine multiphysics simulator
Public Member Functions | List of all members
nwtc_num::equalrealnos Interface Reference

This function compares two real numbers and determines if they are "almost" equal, i.e. More...

Public Member Functions

logical function equalrealnos4 (ReNum1, ReNum2)
 This function compares two real numbers and determines if they are "almost" equal, i.e. More...
 
logical function equalrealnos8 (ReNum1, ReNum2)
 This function compares two real numbers and determines if they are "almost" equal, i.e. More...
 
logical function equalrealnos16 (ReNum1, ReNum2)
 This function compares two real numbers and determines if they are "almost" equal, i.e. More...
 

Detailed Description

This function compares two real numbers and determines if they are "almost" equal, i.e.

within some relative tolerance (basically ignoring the last 2 significant digits) (see "Safe Comparisons" suggestion from http://www.lahey.com/float.htm)

Note that the numbers are added together in this routine, so overflow can result if comparing two "huge" numbers.
Use EqualRealNos (nwtc_num::equalrealnos) instead of directly calling a specific routine in the generic interface.

Parameters
[in]renum1the first real number to compare
[in]renum2the second real number to compare
Returns
.true. if and only if the numbers are almost equal

Member Function/Subroutine Documentation

◆ equalrealnos16()

logical function nwtc_num::equalrealnos::equalrealnos16 ( real(quki), intent(in)  ReNum1,
real(quki), intent(in)  ReNum2 
)

This function compares two real numbers and determines if they are "almost" equal, i.e.

within some relative tolerance (basically ignoring the last 2 significant digits) (see "Safe Comparisons" suggestion from http://www.lahey.com/float.htm)

Note that the numbers are added together in this routine, so overflow can result if comparing two "huge" numbers.
Use EqualRealNos (nwtc_num::equalrealnos) instead of directly calling a specific routine in the generic interface.

Parameters
[in]renum1the first real number to compare
[in]renum2the second real number to compare
Returns
.true. if and only if the numbers are almost equal
.true. if and only if the numbers are almost equal

◆ equalrealnos4()

logical function nwtc_num::equalrealnos::equalrealnos4 ( real(siki), intent(in)  ReNum1,
real(siki), intent(in)  ReNum2 
)

This function compares two real numbers and determines if they are "almost" equal, i.e.

within some relative tolerance (basically ignoring the last 2 significant digits) (see "Safe Comparisons" suggestion from http://www.lahey.com/float.htm)

Note that the numbers are added together in this routine, so overflow can result if comparing two "huge" numbers.
Use EqualRealNos (nwtc_num::equalrealnos) instead of directly calling a specific routine in the generic interface.

Parameters
[in]renum1the first real number to compare
[in]renum2the second real number to compare
Returns
.true. if and only if the numbers are almost equal

◆ equalrealnos8()

logical function nwtc_num::equalrealnos::equalrealnos8 ( real(r8ki), intent(in)  ReNum1,
real(r8ki), intent(in)  ReNum2 
)

This function compares two real numbers and determines if they are "almost" equal, i.e.

within some relative tolerance (basically ignoring the last 2 significant digits) (see "Safe Comparisons" suggestion from http://www.lahey.com/float.htm)

Note that the numbers are added together in this routine, so overflow can result if comparing two "huge" numbers.
Use EqualRealNos (nwtc_num::equalrealnos) instead of directly calling a specific routine in the generic interface.

Parameters
[in]renum1the first real number to compare
[in]renum2the second real number to compare
Returns
.true. if and only if the numbers are almost equal
.true. if and only if the numbers are almost equal

The documentation for this interface was generated from the following file: