|
11 | 11 | !! You, Rey-Jer. (2000). Transformation of Cartesian to Geodetic Coordinates without Iterations. |
12 | 12 | !! Journal of Surveying Engineering. doi: 10.1061/(ASCE)0733-9453 |
13 | 13 |
|
14 | | -real(wp) :: ea, eb, r, E, u, Q, huE, Beta, eps, sinBeta, cosBeta |
| 14 | +real :: ea, eb, r, E, u, Q, huE, Beta, eps, sinBeta, cosBeta |
15 | 15 | type(Ellipsoid) :: ell |
16 | 16 | logical :: d, inside |
17 | 17 |
|
|
61 | 61 | alt = hypot(z - eb * sinBeta, Q - ea * cosBeta) |
62 | 62 |
|
63 | 63 | !> inside ellipsoid? |
64 | | - inside = x**2 / ea**2 + y**2 / ea**2 + z**2 / eb**2 < 1._wp |
| 64 | + inside = x**2 / ea**2 + y**2 / ea**2 + z**2 / eb**2 < 1 |
65 | 65 | if (inside) alt = -alt |
66 | 66 | endif |
67 | 67 |
|
|
91 | 91 | !! |
92 | 92 | !! * x,y,z: ECEF coordinates of test point(s) (meters) |
93 | 93 |
|
94 | | -real(wp) :: N, sinLat, cosLat, cosLon, sinLon, lat, lon |
| 94 | +real :: N, sinLat, cosLat, cosLon, sinLon, lat, lon |
95 | 95 | type(Ellipsoid) :: ell |
96 | 96 | logical :: d |
97 | 97 |
|
|
166 | 166 | ! ------- |
167 | 167 | ! x,y,z: Earth Centered Earth Fixed (ECEF) coordinates of test point (meters) |
168 | 168 |
|
169 | | -real(wp) :: x0,y0,z0,dx,dy,dz |
| 169 | +real :: x0,y0,z0,dx,dy,dz |
170 | 170 |
|
171 | 171 | call geodetic2ecef(lat0, lon0, alt0, x0, y0, z0, spheroid, deg) |
172 | 172 | call enu2uvw(e, n, u, lat0, lon0, dx, dy, dz, deg) |
|
191 | 191 | !! |
192 | 192 | !! * e,n,u: East, North, Up coordinates of test points (meters) |
193 | 193 |
|
194 | | -real(wp) :: x0,y0,z0 |
| 194 | +real :: x0,y0,z0 |
195 | 195 |
|
196 | 196 | call geodetic2ecef(lat0, lon0, alt0, x0,y0,z0, spheroid,deg) |
197 | 197 | call ecef2enuv(x - x0, y - y0, z - z0, lat0, lon0, east, north, up, deg) |
|
211 | 211 | !! |
212 | 212 | !! * east,north,Up: East, North, Up vector |
213 | 213 |
|
214 | | -real(wp) :: t, lat0, lon0 |
| 214 | +real :: t, lat0, lon0 |
215 | 215 | logical :: d |
216 | 216 |
|
217 | 217 | d=.true. |
|
231 | 231 | end procedure ecef2enuv |
232 | 232 |
|
233 | 233 |
|
234 | | -elemental real(wp) function radius_normal(lat,E) |
| 234 | +elemental real function radius_normal(lat,E) |
235 | 235 |
|
236 | | -real(wp), intent(in) :: lat |
| 236 | +real, intent(in) :: lat |
237 | 237 | type(Ellipsoid), intent(in) :: E |
238 | 238 |
|
239 | 239 | !> singularity pi/2 issue is inherent to real32 |
|
0 commit comments