pflotran.F90       coverage:  100.00 %func     96.88 %block


     1) !=======================================================================
     2) ! PFLOTRAN v2.0 LA-CC-09-047
     3) !=======================================================================
     4) 
     5) !Copyright 2009. Los Alamos National Security, LLC. This material was produced under U.S. 
     6) !Government contract DE-AC52-06NA25396 for Los Alamos National Laboratory (LANL), which is operated 
     7) !by Los Alamos National Security, LLC for the U.S. Department of Energy. The U.S. Government has 
     8) !rights to use, reproduce, and distribute this software.  NEITHER THE GOVERNMENT NOR LOS ALAMOS 
     9) !NATIONAL SECURITY, LLC MAKES ANY WARRANTY, EXPRESS OR IMPLIED, OR ASSUMES ANY LIABILITY FOR THE 
    10) !USE OF THIS SOFTWARE.  If software is modified to produce derivative works, such modified software 
    11) !should be clearly marked, so as not to confuse it with the version available from LANL.
    12) !Additionally, this library is free software; you can redistribute it and/or modify it under the 
    13) !terms of the GNU Lesser General Public License as published by the Free Software Foundation; 
    14) !either version 2.1 of the License, or (at your option) any later version. Accordingly, this 
    15) !library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even 
    16) !the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser 
    17) !General Public License for more details.
    18) 
    19) ! Send all bug reports/questions/comments to:
    20) !
    21) ! Peter C. Lichtner
    22) ! OFM Research
    23) ! (505) 692-4029 (cell)
    24) ! peter.lichtner@gmail.com
    25) ! Santa Fe, New Mexico
    26) 
    27) ! or
    28) 
    29) ! Glenn E. Hammond
    30) ! Sandia National Laboratories
    31) ! Applied Systems Analysis & Research
    32) ! 413 Cherry Blossom Lp
    33) ! Richland, WA 99352
    34) ! (505) 235-0665
    35) ! gehammo@sandia.gov
    36) 
    37) !=======================================================================
    38) program pflotran
    39)   
    40)   use Option_module
    41)   use Simulation_Base_class
    42)   use Multi_Simulation_module
    43)   use Factory_PFLOTRAN_module
    44)   use Factory_Subsurface_module
    45)   use Factory_Hydrogeophysics_module
    46)   use Factory_Surface_module
    47)   use Factory_Surf_Subsurf_module
    48)   use Factory_Geomechanics_module
    49)   use PFLOTRAN_Constants_module
    50)   use Output_Aux_module, only : INSTANTANEOUS_VARS
    51)   use PFLOTRAN_Provenance_module, only : PrintProvenanceToScreen
    52)   
    53)   !TODO(geh): remove
    54)   use PM_Base_class
    55) 
    56)   implicit none
    57) 
    58) #include "petsc/finclude/petscsys.h"
    59) 
    60)   class(simulation_base_type), pointer :: simulation
    61)   ! multisimulation enables multiple simulations to be run concurrently
    62)   ! and/or one after another until a specified set of simulations has 
    63)   ! completed.
    64)   type(multi_simulation_type), pointer :: multisimulation
    65)   class(pm_base_type), pointer :: dummy_list
    66)   type(option_type), pointer :: option
    67)   
    68)   nullify(simulation)
    69)   nullify(multisimulation)
    70)   option => OptionCreate()
    71)   call OptionInitMPI(option)
    72)   call PFLOTRANInitializePrePetsc(multisimulation,option)
    73)   call OptionInitPetsc(option)
    74)   if (option%myrank == option%io_rank .and. option%print_to_screen) then
    75)     call PrintProvenanceToScreen()
    76)   endif
    77) 
    78)   do ! multi-simulation loop
    79)     call PFLOTRANInitializePostPetsc(simulation,multisimulation,option)
    80) 
    81)     call simulation%InitializeRun()
    82) 
    83)     if (option%status == PROCEED) then
    84)       call simulation%ExecuteRun()
    85)     endif
    86) 
    87)     call simulation%FinalizeRun()
    88)     call simulation%Strip()
    89)     deallocate(simulation)
    90)     nullify(simulation)
    91)     call PFLOTRANFinalize(option)
    92)     if (MultiSimulationDone(multisimulation)) exit
    93)   enddo ! multi-simulation loop
    94)   call OptionFinalize(option)
    95) 
    96) end program pflotran

generated by
Intel(R) C++/Fortran Compiler code-coverage tool
Web-Page Owner: Nobody