src.usr
ccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc
c The following subroutines are from Novak, Ostriker and Ciotti 2010.

c      bugs= bugs + 1
c      write(*,*) "Bug No.", bugs
c      pause

c      if(bugs.eq.1) then
c         call reset
c      endif

#ifdef ACCRETION
C SUB-GRID MODEL OF BLACK-HOLE ACCRETION, FROM
C THE FIRST ACTIVE GRID TO THE ACCRETION DISK
      call agn_bh_acc  
#endif 

#ifdef RADCOOL
C RADIATIVE ENERGY LOSS VIA BREMSSTRAHLUNG, AND ALSO RADIATIVE 
C HEATING/COOLING BY AGN IRADIATING, THE LATER IS CUSTOMIZED 
C BY SETTING "lum_en = 0" OR NOT
      call ism_rad_loss 
#endif 

      call ensure_good

#ifdef AGNFB
C AGN FEEDBACK NEEDS TO KNOW HEATING TO
C CALCULATE MOMENTUM FEEDBACK ON LINES
      call agn_feedback  
#endif 

      call ensure_good

#ifdef STARFORM
C STAR FORMATION
      call star_formation  
#endif 

      call ensure_good

#if defined(STAREV) || defined(SNII) || defined(SNIA)
C FEEDBACK FROM EVOLUTING STARS, INCLUDING MASS LOSS 
c (THE MAIN SOURCE OF ACCRETING MATTER), ENERGY AND 
c MOMENTUM DEPOSITION
      call stellar_to_ism
#endif 

      call ensure_good

#ifdef STARRAD
      call stellar_rad 
#endif 

      call ensure_good

#ifdef PROBES
c       call probe
#endif

c END OF NOC2010
ccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc