Skip to content

Commit

Permalink
Platform swap (NOAA-GFDL#54)
Browse files Browse the repository at this point in the history
* monin_obukhov (no mod required)

* updated drifters

* updated time_manager

* updated block_control
  • Loading branch information
GFDL-Eric authored Sep 18, 2020
1 parent aad0e66 commit 4e89be3
Show file tree
Hide file tree
Showing 11 changed files with 16 additions and 27 deletions.
1 change: 0 additions & 1 deletion block_control/block_control.F90
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
!! \brief Contains the \ref block_control_mod module

module block_control_mod
#include <fms_platform.h>

use mpp_mod, only: mpp_error, NOTE, WARNING, FATAL
use mpp_domains_mod, only: mpp_compute_extent
Expand Down
1 change: 1 addition & 0 deletions drifters/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

# Include .h and .mod files.
AM_CPPFLAGS = -I${top_srcdir}/include
AM_CPPFLAGS += -I${top_builddir}/platform
AM_CPPFLAGS += -I${top_builddir}/mpp

# Build these uninstalled convenience libraries.
Expand Down
1 change: 0 additions & 1 deletion drifters/cloud_interpolator.F90
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#define _FLATTEN(A) reshape((A), (/size((A))/) )

MODULE cloud_interpolator_mod
#include <fms_platform.h>
implicit none
private

Expand Down
1 change: 0 additions & 1 deletion drifters/drifters.F90
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
#define _FLATTEN(A) reshape((A), (/size((A))/) )

module drifters_mod
#include <fms_platform.h>
! <CONTACT EMAIL="Alexander.Pletzer@noaa.gov">
! Alexander Pletzer
! </CONTACT>
Expand Down
1 change: 0 additions & 1 deletion drifters/drifters_comm.F90
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include "fms_switches.h"

module drifters_comm_mod
#include <fms_platform.h>

#ifdef _SERIAL

Expand Down
6 changes: 3 additions & 3 deletions drifters/drifters_core.F90
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@


module drifters_core_mod
#include <fms_platform.h>
use platform_mod, only: i8_kind
implicit none
private

Expand All @@ -39,11 +39,11 @@ module drifters_core_mod
type drifters_core_type
! Be sure to update drifters_core_new, drifters_core_del and drifters_core_copy_new
! when adding members
integer*8 :: it ! time index
integer(kind=i8_kind) :: it ! time index
integer :: nd ! number of dimensions
integer :: np ! number of particles (drifters)
integer :: npdim ! max number of particles (drifters)
integer, allocatable :: ids(:)_NULL ! particle id number
integer, allocatable :: ids(:) ! particle id number
real , allocatable :: positions(:,:)
end type drifters_core_type

Expand Down
4 changes: 0 additions & 4 deletions drifters/drifters_input.F90
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@


module drifters_input_mod
#include <fms_platform.h>
implicit none
private

Expand Down Expand Up @@ -427,6 +426,3 @@ subroutine drifters_input_save(self, filename, geolon, geolat, ermesg)
end subroutine drifters_input_save

end module drifters_input_mod

!===============================================================================
!===============================================================================
3 changes: 0 additions & 3 deletions drifters/drifters_io.F90
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
!* You should have received a copy of the GNU Lesser General Public
!* License along with FMS. If not, see <http://www.gnu.org/licenses/>.
!***********************************************************************
!!#include <fms_platform.h>

module drifters_io_mod
implicit none
Expand Down Expand Up @@ -304,5 +303,3 @@ subroutine drifters_io_write(self, time, np, nd, nf, ids, positions, fields, erm
end subroutine drifters_io_write

end module drifters_io_mod
!###############################################################################
!###############################################################################
19 changes: 9 additions & 10 deletions monin_obukhov/monin_obukhov_kernel.F90
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@


module monin_obukhov_inter
#include <fms_platform.h>
implicit none
private

Expand All @@ -38,7 +37,7 @@ module monin_obukhov_inter
contains


_PURE subroutine monin_obukhov_diff(vonkarm, &
pure subroutine monin_obukhov_diff(vonkarm, &
& ustar_min, &
& neutral, stable_option,new_mo_option,rich_crit, zeta_trans, &
& ni, nj, nk, z, u_star, b_star, k_m, k_h, ier)
Expand Down Expand Up @@ -86,7 +85,7 @@ _PURE subroutine monin_obukhov_diff(vonkarm, &
end subroutine monin_obukhov_diff


_PURE subroutine monin_obukhov_drag_1d(grav, vonkarm, &
pure subroutine monin_obukhov_drag_1d(grav, vonkarm, &
& error, zeta_min, max_iter, small, &
& neutral, stable_option, new_mo_option, rich_crit, zeta_trans,&
& drag_min_heat, drag_min_moist, drag_min_mom, &
Expand Down Expand Up @@ -197,7 +196,7 @@ _PURE subroutine monin_obukhov_drag_1d(grav, vonkarm, &
end subroutine monin_obukhov_drag_1d


_PURE subroutine monin_obukhov_solve_zeta(error, zeta_min, max_iter, small, &
pure subroutine monin_obukhov_solve_zeta(error, zeta_min, max_iter, small, &
& stable_option, new_mo_option, rich_crit, zeta_trans, & !miz
& n, rich, z, z0, zt, zq, f_m, f_t, f_q, mask, ier)

Expand Down Expand Up @@ -314,7 +313,7 @@ end subroutine monin_obukhov_solve_zeta

! the differential similarity function for buoyancy and tracers
! Note: seems to be the same as monin_obukhov_derivative_m?
_PURE subroutine monin_obukhov_derivative_t(stable_option,new_mo_option,rich_crit, zeta_trans, &
pure subroutine monin_obukhov_derivative_t(stable_option,new_mo_option,rich_crit, zeta_trans, &
& n, phi_t, zeta, mask, ier)

integer, intent(in ) :: stable_option
Expand Down Expand Up @@ -370,7 +369,7 @@ end subroutine monin_obukhov_derivative_t


! the differential similarity function for momentum
_PURE subroutine monin_obukhov_derivative_m(stable_option, rich_crit, zeta_trans, &
pure subroutine monin_obukhov_derivative_m(stable_option, rich_crit, zeta_trans, &
& n, phi_m, zeta, mask, ier)

integer, intent(in ) :: stable_option
Expand Down Expand Up @@ -418,7 +417,7 @@ _PURE subroutine monin_obukhov_derivative_m(stable_option, rich_crit, zeta_trans
end subroutine monin_obukhov_derivative_m


_PURE subroutine monin_obukhov_profile_1d(vonkarm, &
pure subroutine monin_obukhov_profile_1d(vonkarm, &
& neutral, stable_option, new_mo_option, rich_crit, zeta_trans, &
& n, zref, zref_t, z, z0, zt, zq, u_star, b_star, q_star, &
& del_m, del_t, del_q, lavail, avail, ier)
Expand Down Expand Up @@ -502,7 +501,7 @@ end subroutine monin_obukhov_profile_1d


! the integral similarity function for momentum
_PURE subroutine monin_obukhov_integral_m(stable_option, rich_crit, zeta_trans, &
pure subroutine monin_obukhov_integral_m(stable_option, rich_crit, zeta_trans, &
& n, psi_m, zeta, zeta_0, ln_z_z0, mask, ier)

integer, intent(in ) :: stable_option
Expand Down Expand Up @@ -578,7 +577,7 @@ end subroutine monin_obukhov_integral_m


! the integral similarity function for moisture and tracers
_PURE subroutine monin_obukhov_integral_tq(stable_option, new_mo_option, rich_crit, zeta_trans, &
pure subroutine monin_obukhov_integral_tq(stable_option, new_mo_option, rich_crit, zeta_trans, &
& n, psi_t, psi_q, zeta, zeta_t, zeta_q, &
& ln_z_zt, ln_z_zq, mask, ier)

Expand Down Expand Up @@ -676,7 +675,7 @@ _PURE subroutine monin_obukhov_integral_tq(stable_option, new_mo_option, rich_cr
end subroutine monin_obukhov_integral_tq


_PURE subroutine monin_obukhov_stable_mix(stable_option, rich_crit, zeta_trans, &
pure subroutine monin_obukhov_stable_mix(stable_option, rich_crit, zeta_trans, &
& n, rich, mix, ier)

integer, intent(in ) :: stable_option
Expand Down
1 change: 1 addition & 0 deletions time_manager/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

# Include .h and .mod files.
AM_CPPFLAGS = -I${top_srcdir}/include
AM_CPPFLAGS += -I${top_builddir}/platform
AM_CPPFLAGS += -I${top_builddir}/constants
AM_CPPFLAGS += -I${top_builddir}/fms
AM_CPPFLAGS += -I${top_builddir}/mpp
Expand Down
5 changes: 2 additions & 3 deletions time_manager/time_manager.F90
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ module time_manager_mod
! contains three PRIVATE variables: days, seconds and ticks.
! </DATA>

#include <fms_platform.h>

use platform_mod, only: r8_kind
use constants_mod, only: rseconds_per_day=>seconds_per_day
use fms_mod, only: error_mesg, FATAL, WARNING, write_version_number, stdout

Expand Down Expand Up @@ -1255,7 +1254,7 @@ end subroutine time_assignment

function time_type_to_real(time)

real(DOUBLE_KIND) :: time_type_to_real
real(kind=r8_kind) :: time_type_to_real
type(time_type), intent(in) :: time

if(.not.module_is_initialized) call time_manager_init
Expand Down

0 comments on commit 4e89be3

Please sign in to comment.