Simulation Core
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.
 
 
 
 
 
 

45 linhas
1.6 KiB

  1. SUBROUTINE AnnulusPropertyCalculator (md, den, pre, tem)
  2. !!! This subroutine gets location of a guage or an observation point and determines information of that point such as pressure, density, velocity and temperature later.
  3. USE PressureDisplayVARIABLES
  4. USE Fluid_Flow_Startup_Vars
  5. USE MudSystemVARIABLES
  6. USE FricPressDropVars
  7. USE CDrillWatchVariables
  8. IMPLICIT NONE
  9. INTEGER, intent(in) :: md ! input
  10. REAL(8) :: TVD
  11. real(8), intent(inout) :: den ! output
  12. real(8), intent(inout) :: pre ! output
  13. real(8), intent(inout) :: tem ! output
  14. INTEGER :: ilocal
  15. CALL TVD_Calculator(md * 1.d0 , TVD)
  16. IF (md <= INT(FinalFlowEl(AnnulusFirstEl)%StartX)) THEN !! mouse pointer is in the annulus space
  17. DO ilocal = AnnulusFirstEl , AnnulusLastEl
  18. IF (INT(FinalFlowEl(ilocal)%EndX) <= md) EXIT
  19. END DO
  20. ELSE IF (md > INT(FinalFlowEl(NumbEl)%EndX)) THEN ! mouse pointer is in the open hole space
  21. DO ilocal = OpenholeFirstEl , NumbEl
  22. IF (INT(FinalFlowEl(ilocal)%EndX) <= md) EXIT
  23. END DO
  24. ELSE
  25. WRITE (*,*) ' Error in calculating annulus observation point '
  26. END IF
  27. pre = FinalFlowEl(ilocal)%StartPress - (FinalFlowEl(ilocal)%StartX - md) * FinalFlowEl(ilocal)%dPdLfric &
  28. - (FinalFlowEl(ilocal)%StartTVD - TVD) * FinalFlowEl(ilocal)%dPdLGrav
  29. !write(*,*) ' md, ilocal', md, ilocal
  30. !WRITE (*,*) ' FlowEl dPdLfric , dPdLGrav', FlowEl(ilocal)%dPdLfric , FlowEl(ilocal)%dPdLGrav
  31. den = FinalFlowEl(ilocal)%Density
  32. !tem = 500
  33. END SUBROUTINE