anchor.diff:           Tinsp,ttime
       real(dp) :: dP_muscle,P_muscle
       ! Local variables
  -    real(dp) :: sum_dP_muscle,sum_dP_muscle_ei,Tpass
  +    real(dp) :: mu
       character(len=60) :: sub_name
       
       ! --------------------------------------------------------------------------
  
positive.code:                sin(2.0_dp*pi*(0.5_dp+(ttime-Tinsp)/(2.0_dp*Texpn)))/ &
                 (2.0_dp*Texpn)*dt
         endif
         
      case('passive')
         if(ttime.le.Tinsp+0.5_dp*dt)then
            dP_muscle = ventilation_values%P_muscle_estimate*ventilation_values%factor_P_muscle_insp*PI*dt* &
                 sin(pi*ttime/Tinsp)/(2.0_dp*Tinsp)
            sum_dP_muscle = sum_dP_muscle+dP_muscle
            sum_dP_muscle_ei = sum_dP_muscle
         else
            Tpass = 0.1_dp
            dP_muscle = MIN(-sum_dP_muscle_ei/(Tpass*Texpn)*dt,-sum_dP_muscle)
            sum_dP_muscle = sum_dP_muscle+dP_muscle
         endif
         
      end select
      
      P_muscle = P_muscle + dP_muscle !current value for muscle pressure
  
      call enter_exit(sub_name,2)
  
    end subroutine set_driving_pressures
  
negative.code:             &4X,''(L)'',5X,''(......cmH2O.......)'')')
         
         write(*,'(F7.3,2(F8.1),8(F8.2))') &
              0.0_dp,0.0_dp,0.0_dp, &  !time, flow, tidal
              elem_field(ne_t_resist,1)*1.0e+6_dp/98.0665_dp, & !res (cmH2O/L.s)
              totalC*98.0665_dp/1.0e+6_dp, & !total model compliance
              ppl_current/98.0665_dp, & !Ppl (cmH2O)
              -ppl_current/98.0665_dp, & !mean Ptp (cmH2O)
              init_vol/1.0e+6_dp, & !total model volume (L)
              0.0_dp, & !Pmuscle (cmH2O)
              Pcw/98.0665_dp, & !Pchest_wall (cmH2O)
              (-Pcw)/98.0665_dp !Pmuscle - Pchest_wall (cmH2O)
         write(10,'(F7.3,2(F8.1),8(F8.2))') &
              0.0_dp,0.0_dp,0.0_dp, &  !time, flow, tidal
              elem_field(ne_t_resist,1)*1.0e+6_dp/98.0665_dp, & !res (cmH2O/L.s)
              totalC*98.0665_dp/1.0e+6_dp, & !total model compliance
  