I work with FORTRAN a lot, but I never had formal instruction in the proper way to write source code. I currently use modules to store global variables, but I understand yo
One of the major benefits of using modules is that your compiler will automatically perform interface checking on any functions or subroutines you use from a module to ensure that your are calling the routine with the appropriate parameter types. A good article on this topic is Doctor Fortran Gets Explicit - Again!. From this article:
There are several ways to provide an explicit interface. The simplest and best way is to put the procedure in a module, or make it a CONTAINed procedure of the calling program or procedure. This has the advantage of not requiring you to write the information twice and thus increasing the chances of getting it wrong in one of the places. When you have a module procedure, or a contained procedure, its interface is automatically visible to everything else in the module or in the parent scope. Assuming the name hasn't been declared PRIVATE, the interface is also available to places where you USE a module containing a module procedure.
I would recommend putting all related routines in the same module. Modules are, to me, the equivalent of classes in other languages. Modules are a way to group related data and routines (which may operate on that data). So modules offer a way of making your code easier to navigate, if your routines are grouped logically into modules, and add type checking to your function and subroutine calls.