KIND(3) - [KIND:INQUIRY] Query kind of an entity
result = kind(x)
integer function kind(x)type(TYPE(kind=**)),intent(in) :: x(..)
o X may be of any intrinsic type. It may be a scalar or an array. o the result is a default integer scalar
KIND(X)(3) returns the kind value of the entity X.
o X : Value to query the kind of.
The return value indicates the kind of the argument X.
Note that kinds are processor-dependent.
Sample program:
program demo_kind implicit none integer,parameter :: dc = kind( ) integer,parameter :: dl = kind(.true.)Results:print *, "The default character kind is ", dc print *, "The default logical kind is ", dl
end program demo_kind
> The default character kind is 1 > The default logical kind is 4
Fortran 95
Fortran intrinsic descriptions (license: MIT) @urbanjost
o ALLOCATED(3) - Status of an allocatable entity o IS_CONTIGUOUS(3) - test if object is contiguous o LBOUND(3) - Lower dimension bounds of an array o RANK(3) - Rank of a data object o SHAPE(3) - Determine the shape of an array o SIZE(3) - Determine the size of an array o UBOUND(3) - Upper dimension bounds of an array o BIT_SIZE(3) - Bit size inquiry function o STORAGE_SIZE(3) - Storage size in bits o KIND(3) - Kind of an entity
Nemo Release 3.1 | kind (3fortran) | November 02, 2024 |