MAPL_SunOrbitQuery Subroutine

public subroutine MAPL_SunOrbitQuery(ORBIT, ECCENTRICITY, OBLIQUITY, PERIHELION, EQUINOX, YEAR_LENGTH, YEARS_PER_CYCLE, DAYS_PER_CYCLE, CLOCK, ZS, ZC, TH, PP, ET, RC)

Query for quantities in an orbit object. Optionally returns the parameters of the orbit and its associated ESMF_Clock. It fails if the orbit has not been created.

@note Bug Not updated for ORBIT_ANAL2B option, which does not precalc many of the above outputs.

Arguments

Type IntentOptional Attributes Name
type(MAPL_SunOrbit), intent(in) :: ORBIT
real, intent(out), optional :: ECCENTRICITY
real, intent(out), optional :: OBLIQUITY
real, intent(out), optional :: PERIHELION
integer, intent(out), optional :: EQUINOX
real, intent(out), optional :: YEAR_LENGTH
integer, intent(out), optional :: YEARS_PER_CYCLE
integer, intent(out), optional :: DAYS_PER_CYCLE
type(ESMF_Clock), intent(out), optional :: CLOCK
real, optional, pointer, dimension(:) :: ZS
real, optional, pointer, dimension(:) :: ZC
real, optional, pointer, dimension(:) :: TH
real, optional, pointer, dimension(:) :: PP
real, optional, pointer, dimension(:) :: ET
integer, intent(out), optional :: RC

Calls

proc~~mapl_sunorbitquery~~CallsGraph proc~mapl_sunorbitquery MAPL_SunOrbitQuery interface~mapl_assert MAPL_Assert proc~mapl_sunorbitquery->interface~mapl_assert proc~mapl_return MAPL_Return proc~mapl_sunorbitquery->proc~mapl_return proc~mapl_sunorbitcreated MAPL_SunOrbitCreated proc~mapl_sunorbitquery->proc~mapl_sunorbitcreated at at proc~mapl_return->at insert insert proc~mapl_return->insert proc~mapl_throw_exception MAPL_throw_exception proc~mapl_return->proc~mapl_throw_exception proc~mapl_sunorbitcreated->proc~mapl_return

Source Code

subroutine  MAPL_SunOrbitQuery(ORBIT,           &
                               ECCENTRICITY,    &
                               OBLIQUITY,       &
                               PERIHELION,      &
                               EQUINOX,         &
                               YEAR_LENGTH,     &
                               YEARS_PER_CYCLE, &
                               DAYS_PER_CYCLE,  &
                               CLOCK,           &
                               ZS,              &
                               ZC,              &
                               TH,              &
                               PP,              &
                               ET,              &
                                             RC )

! !ARGUMENTS:

       type(MAPL_SunOrbit),           intent(IN ) :: ORBIT
       real,                optional, intent(OUT) :: OBLIQUITY
       real,                optional, intent(OUT) :: ECCENTRICITY
       real,                optional, intent(OUT) :: PERIHELION
       real,                optional, intent(OUT) :: YEAR_LENGTH
       integer,             optional, intent(OUT) :: EQUINOX
       integer,             optional, intent(OUT) :: YEARS_PER_CYCLE
       integer,             optional, intent(OUT) :: DAYS_PER_CYCLE
       type(ESMF_Clock   ), optional, intent(OUT) :: CLOCK
       real,                optional, pointer, dimension(:) :: ZS
       real,                optional, pointer, dimension(:) :: ZC
       real,                optional, pointer, dimension(:) :: TH
       real,                optional, pointer, dimension(:) :: PP
       real,                optional, pointer, dimension(:) :: ET
       integer,             optional, intent(OUT) :: RC

       character(len=ESMF_MAXSTR), parameter :: IAm = "SunOrbitQuery"
       integer :: STATUS

       _ASSERT(MAPL_SunOrbitCreated(ORBIT,RC=STATUS),'MAPL_SunOrbit not yet created!')

       if(present(CLOCK          )) CLOCK           = ORBIT%CLOCK
       if(present(OBLIQUITY      )) OBLIQUITY       = ORBIT%OB
       if(present(ECCENTRICITY   )) ECCENTRICITY    = ORBIT%ECC
       if(present(PERIHELION     )) PERIHELION      = ORBIT%PER
       if(present(EQUINOX        )) EQUINOX         = ORBIT%EQNX
       if(present(YEAR_LENGTH    )) YEAR_LENGTH     = ORBIT%YEARLEN
       if(present(DAYS_PER_CYCLE )) DAYS_PER_CYCLE  = ORBIT%DAYS_PER_CYCLE
       if(present(YEARS_PER_CYCLE)) YEARS_PER_CYCLE = ORBIT%YEARS_PER_CYCLE
       if(present(ZS             )) ZS => ORBIT%ZS
       if(present(ZC             )) ZC => ORBIT%ZC
       if(present(TH             )) TH => ORBIT%TH
       if(present(PP             )) PP => ORBIT%PP
       if(present(ET             )) ET => ORBIT%ET

       _RETURN(ESMF_SUCCESS)

     end subroutine MAPL_SunOrbitQuery