Subroutine Type |
Utility/General |
|
Definition |
Evaluates a Haversine function. |
|
Use |
This function can be called by any user-defined subroutine. |
|
Calling Syntax |
Fortran CALL HAVSIN (X, X0, H0, X1, H1, IORD, VALUE, ERRFLG)
C c_havsin(x, x0, h0, x1, h1, iord, value, errflg)
Python [value, errflg] = py_havsin(x, x0, h0, x1, h1, irod)
MATLAB [value, errflg] = m_havsin(x, x0, h0, x1, h1, irod) |
|
Input Arguments |
X [double precision] |
The independent variable. For example, to specify time as the independent variable, specify X as TIME. |
X0 [double precision] |
The X value at which the Haversine function begins. |
|
H0 [double precision] |
The value of the Haversine function at X0. |
|
X1 [double precision] |
The X value at which the Haversine function ends. |
|
H1 [double precision] |
The value of the Haversine function at X1. |
|
IORD [integer] |
The order of the derivative that HAVSIN has to return. Order can be 0, 1 or 2. |
|
Output Values |
Value [integer] |
A value that the subroutine returns. |
Errflg [logical] |
A logical (true or false) variable that HAVSIN returns to the calling subroutine. If HAVSIN detects an error while calling subroutine, it sets the error flag to true. |