<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="fr">
	<id>https://patrius.cnes.fr/index.php?action=history&amp;feed=atom&amp;title=LocalTime_4.5.1</id>
	<title>LocalTime 4.5.1 - Historique des versions</title>
	<link rel="self" type="application/atom+xml" href="https://patrius.cnes.fr/index.php?action=history&amp;feed=atom&amp;title=LocalTime_4.5.1"/>
	<link rel="alternate" type="text/html" href="https://patrius.cnes.fr/index.php?title=LocalTime_4.5.1&amp;action=history"/>
	<updated>2026-04-08T12:18:18Z</updated>
	<subtitle>Historique des versions pour cette page sur le wiki</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://patrius.cnes.fr/index.php?title=LocalTime_4.5.1&amp;diff=2683&amp;oldid=prev</id>
		<title>Admin : Page créée avec « &lt;syntaxhighlight lang=&quot;java&quot;&gt; public class LocalTimeComputation {      /**      * @param args      * @throws PatriusException       * @throws URISyntaxException       * @t... »</title>
		<link rel="alternate" type="text/html" href="https://patrius.cnes.fr/index.php?title=LocalTime_4.5.1&amp;diff=2683&amp;oldid=prev"/>
		<updated>2020-08-17T08:58:16Z</updated>

		<summary type="html">&lt;p&gt;Page créée avec « &amp;lt;syntaxhighlight lang=&amp;quot;java&amp;quot;&amp;gt; public class LocalTimeComputation {      /**      * @param args      * @throws PatriusException       * @throws URISyntaxException       * @t... »&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Nouvelle page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;syntaxhighlight lang=&amp;quot;java&amp;quot;&amp;gt;&lt;br /&gt;
public class LocalTimeComputation {&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * @param args&lt;br /&gt;
     * @throws PatriusException &lt;br /&gt;
     * @throws URISyntaxException &lt;br /&gt;
     * @throws IOException &lt;br /&gt;
     */&lt;br /&gt;
    public static void main(String[] args) throws PatriusException, IOException, URISyntaxException {&lt;br /&gt;
&lt;br /&gt;
        // Patrius Dataset initialization (needed for example to get the UTC time&lt;br /&gt;
        PatriusDataset.addResourcesFromPatriusDataset() ;&lt;br /&gt;
&lt;br /&gt;
        // Recovery of the UTC time scale using a &amp;quot;factory&amp;quot; (not to duplicate such unique object)&lt;br /&gt;
        final TimeScale TUC = TimeScalesFactory.getUTC();&lt;br /&gt;
        &lt;br /&gt;
        // Date of the orbit given in UTC time scale)&lt;br /&gt;
        final AbsoluteDate date = new AbsoluteDate(&amp;quot;2000-06-21T12:00:00.000&amp;quot;, TUC);&lt;br /&gt;
        &lt;br /&gt;
        // Getting the frame with wich will defined the orbit parameters&lt;br /&gt;
        // As for time scale, we will use also a &amp;quot;factory&amp;quot;.&lt;br /&gt;
        final Frame CIRF = FramesFactory.getCIRF();&lt;br /&gt;
        &lt;br /&gt;
        // Initial orbit&lt;br /&gt;
        final double sma = 7200.e+3;&lt;br /&gt;
        final double exc = 0.01;&lt;br /&gt;
        final double per = sma*(1.-exc);&lt;br /&gt;
        final double apo = sma*(1.+exc);&lt;br /&gt;
        final double inc = FastMath.toRadians(98.);&lt;br /&gt;
        final double pa = FastMath.toRadians(0.);&lt;br /&gt;
        final double raan = FastMath.toRadians(90.);&lt;br /&gt;
        final double anm = FastMath.toRadians(0.);&lt;br /&gt;
        final double MU = Constants.WGS84_EARTH_MU;&lt;br /&gt;
        &lt;br /&gt;
        final ApsisRadiusParameters par = new ApsisRadiusParameters(per, apo, inc, pa, raan, anm, PositionAngle.MEAN, MU);&lt;br /&gt;
        final Orbit iniOrbit = new ApsisOrbit(par, CIRF, date);&lt;br /&gt;
&lt;br /&gt;
        // Sun ephemeris&lt;br /&gt;
        CelestialBody sunEphemeris = new MeeusSun();&lt;br /&gt;
        &lt;br /&gt;
        // Local times&lt;br /&gt;
        LocalTimeAngle localTime = new LocalTimeAngle(sunEphemeris);&lt;br /&gt;
        &lt;br /&gt;
        double tlt = localTime.computeTrueLocalTimeAngle(iniOrbit);&lt;br /&gt;
        double mlt = localTime.computeMeanLocalTimeAngle(iniOrbit);&lt;br /&gt;
        &lt;br /&gt;
        System.out.println(&amp;quot;TLT = &amp;quot;+angleToHour(tlt)+&amp;quot; h&amp;quot;+&amp;quot; (&amp;quot;+FastMath.toDegrees(tlt)+&amp;quot; deg)&amp;quot;);&lt;br /&gt;
        System.out.println(&amp;quot;MLT = &amp;quot;+angleToHour(mlt)+&amp;quot; h&amp;quot;+&amp;quot; (&amp;quot;+FastMath.toDegrees(mlt)+&amp;quot; deg)&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    /**&lt;br /&gt;
     * Method to transform local time given as an angle to local time in hours.&lt;br /&gt;
     * @param angle local time as an angle (rad)&lt;br /&gt;
     * @return      local time in hours&lt;br /&gt;
     */&lt;br /&gt;
    private static double angleToHour ( final double angle ) {&lt;br /&gt;
        &lt;br /&gt;
        double hour = 12. + angle*12./FastMath.PI;&lt;br /&gt;
        return hour;&lt;br /&gt;
        &lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>