[1306] | 1 | MODULE kinds |
---|
| 2 | |
---|
| 3 | !--------------------------------------------------------------------------------! |
---|
| 4 | ! This file is part of PALM. |
---|
| 5 | ! |
---|
| 6 | ! PALM is free software: you can redistribute it and/or modify it under the terms |
---|
| 7 | ! of the GNU General Public License as published by the Free Software Foundation, |
---|
| 8 | ! either version 3 of the License, or (at your option) any later version. |
---|
| 9 | ! |
---|
| 10 | ! PALM is distributed in the hope that it will be useful, but WITHOUT ANY |
---|
| 11 | ! WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR |
---|
| 12 | ! A PARTICULAR PURPOSE. See the GNU General Public License for more details. |
---|
| 13 | ! |
---|
| 14 | ! You should have received a copy of the GNU General Public License along with |
---|
| 15 | ! PALM. If not, see <http://www.gnu.org/licenses/>. |
---|
| 16 | ! |
---|
[1310] | 17 | ! Copyright 1997-2014 Leibniz Universitaet Hannover |
---|
[1306] | 18 | !--------------------------------------------------------------------------------! |
---|
| 19 | ! |
---|
| 20 | ! Current revisions: |
---|
| 21 | ! ------------------ |
---|
| 22 | ! |
---|
| 23 | ! |
---|
| 24 | ! Former revisions: |
---|
| 25 | ! ----------------- |
---|
| 26 | ! $Id: mod_kinds.f90 1310 2014-03-14 08:01:56Z heinze $ |
---|
| 27 | ! |
---|
[1307] | 28 | ! 1306 2014-03-13 14:30:59Z raasch |
---|
[1306] | 29 | ! Initial revision |
---|
| 30 | ! |
---|
| 31 | ! Description: |
---|
| 32 | ! ------------ |
---|
| 33 | ! Standard kind definitions |
---|
| 34 | ! wp (working precision) and iwp (integer working precision) are the kinds |
---|
| 35 | ! used by default in all variable declarations. |
---|
| 36 | ! By default, PALM is using wp = dp (64bit), and iwp = isp (32bit). |
---|
| 37 | ! If you like to switch to other precision, then please set wp/iwp |
---|
| 38 | ! appropriately by assigning other kinds below. |
---|
| 39 | !------------------------------------------------------------------------------! |
---|
| 40 | |
---|
| 41 | IMPLICIT NONE |
---|
| 42 | |
---|
| 43 | ! |
---|
| 44 | !-- Floating point kinds |
---|
| 45 | INTEGER, PARAMETER :: sp = 4 ! single precision (32 bit) |
---|
| 46 | INTEGER, PARAMETER :: dp = 8 ! double precision (64 bit) |
---|
| 47 | |
---|
| 48 | ! |
---|
| 49 | !-- Integer kinds |
---|
| 50 | INTEGER, PARAMETER :: isp = SELECTED_INT_KIND( 9 ) ! single precision (32 bit) |
---|
| 51 | INTEGER, PARAMETER :: idp = SELECTED_INT_KIND( 14 ) ! double precision (32 bit) |
---|
| 52 | |
---|
| 53 | ! |
---|
| 54 | !-- Set kinds to be used as defaults |
---|
| 55 | INTEGER, PARAMETER :: wp = dp ! default real kind |
---|
| 56 | INTEGER, PARAMETER :: iwp = idp ! default integer kind |
---|
| 57 | |
---|
| 58 | SAVE |
---|
| 59 | |
---|
| 60 | END MODULE kinds |
---|