Hi..
Would you please help me understand what is wrong with the below code structure. I spent a couple of months for converting my straight code into modules and subroutines similar to a form as below. Now, the speed of my code has decreased four times. By the way, in the new structure I didnt use 'interface" and the code works fine. The huge issue is right now is the speed.
The new object oriented code structure
module arrayMod real,dimension(:,:) :: theArray end module arrayMod program test use arrayMod implicit none call arraySub write(*,*) (thenewArray) end program test subroutine arraySub use arrayMod write(*,*) 'Inside arraySub()' perform operations end subroutine arraySub
The old straight forward code structure
program test implicit none real,dimension(:,:) :: theArray perform the operations write(*,*) (thenewArray) end program test