| 1 |
#include "globalDefines.h" |
| 2 |
|
| 3 |
!========================================================= |
| 4 |
program main |
| 5 |
!========================================================= |
| 6 |
use params_module, only : nx, ny, nz |
| 7 |
|
| 8 |
implicit none |
| 9 |
|
| 10 |
integer, parameter :: g = 9.81 |
| 11 |
real, allocatable, dimension(:,:,:) :: array |
| 12 |
integer :: a, b, c |
| 13 |
real*8 :: x, y, z |
| 14 |
|
| 15 |
b = 5 |
| 16 |
c = 7 |
| 17 |
|
| 18 |
#ifdef ARRAY_COMP |
| 19 |
allocate(array(10,10,10), status=a) |
| 20 |
|
| 21 |
write(c,'(i5.5)') b |
| 22 |
#endif |
| 23 |
|
| 24 |
if(x.lt.5.0) then |
| 25 |
array(:,:,:) = g |
| 26 |
else |
| 27 |
array(:,:,:) = x - y |
| 28 |
endif |
| 29 |
|
| 30 |
return |
| 31 |
!======================================================== |
| 32 |
end program main |
| 33 |
!======================================================== |