Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/oce_mesh.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2435,6 +2435,7 @@ SUBROUTINE mesh_auxiliary_arrays(partit, mesh)
USE MOD_PARSUP
USE o_PARAM
USE o_ARRAYS
USE g_CONFIG, only: rotated_grid, force_rotation
USE g_ROTATE_grid
use g_comm_auto
use elem_center_interface
Expand Down Expand Up @@ -2477,7 +2478,12 @@ SUBROUTINE mesh_auxiliary_arrays(partit, mesh)
END DO

DO n=1,myDim_nod2D+eDim_nod2D
call r2g(lon, lat, mesh%coord_nod2D(1,n), mesh%coord_nod2D(2,n))
if ((.not. rotated_grid) .and. (.not. force_rotation)) then
lon = mesh%coord_nod2D(1,n)
lat = mesh%coord_nod2D(2,n)
else
call r2g(lon, lat, mesh%coord_nod2D(1,n), mesh%coord_nod2D(2,n))
end if
! in case of numerical noise at the boundaries
if (lon > 2._WP*pi) lon=lon-2._WP*pi
if (lon <-2._WP*pi) lon=lon+2._WP*pi
Expand Down