goto statement and not needed
call flush flush(6) instead of call flush(6) call flush() (i.e. without file unit specified), while using flush() is recognized as a syntax error
print*, write(6,*) instead of print*,
stop quit() subroutine provided by DAMASK
return .lt., .le., .eq., .ne., .gt., and .ge. <, <=, ==, !=, >, and >=
(/ and /) [ and ]
implicit none before data declaration
type / kind
dimension
allocatable / pointer / target / parameter
private / public (protected) intent(in/out/inout)
optional
private after implicit none
public parameter
protected
private
public
private
intent(out) or intent(inout) dummy variables
pure statement directly before the declaration
real(pReal) or integer(pInt) before the function declaration
implicit none and possibly information needed for dimension)
intent(in)
parameter
pure statement directly before the declaration
intent(out)
intent(inout)
intent(in)
parameter
C66 instead of C_66
i for integration point number
e for element number
g for grain number
h for homogenization instance
m for microstructure instance
c for constituent instance
o for output
f for slip/twin family
ip for integration point number
ipc component-ID of current integration point
el for element number
gr for grain number
ipc and gr the same?
state
Tstar_v
do, if, where, forall, select case) ![]()
subIncLooping: do i=1_pInt, 1000_pInt do i=1_pInt, 1000_pInt a=time(i) a=time(i) enddo subIncLooping enddo
spread when initializing fields instead of explicit loops real(pReal), dimension(3,3,10) :: a![]()
a=spread(math_I3,3,10) a=0.0_pReal do i=1_pInt, 10_pInt a(1:3,1:3,i)=math_I3 enddo
sum when calculating average fields instead of explicit loops real(pReal), dimension(3,3,10) :: a real(pReal), dimension(3,3) :: b![]()
b=sum(a,3) b=0.0_pReal do i=1_pInt, 10_pInt b=b + a(1:3,1:3,i) enddo
product when calculating products of array integer(pInt), dimension(3) :: res integer(pInt), :: N![]()
N=product(res) N=res(1)*res(2)*res(3)
integer(pInt), dimension(3,3,5,5) :: field integer(pInt), dimension(3,3) :: tensor![]()
field(1:3,1:3,1,1)=tensor field(:,:,1,1)=tensor
only statement and explicitly include functions of the module integer(pInt) function a(b)![]()
use IO, only: & use IO IO_error, & IO_warning