CreateFrames 4.5.1

De Patrius
Version datée du 17 août 2020 à 08:51 par Admin (discussion | contributions) (Page créée avec « <syntaxhighlight lang="java"> public class CreateFrames { public static void main(String[] args) throws PatriusException, IOException, URISyntaxException { /... »)
(diff) ← Version précédente | Version actuelle (diff) | Version suivante → (diff)
Aller à la navigation Aller à la recherche
public class CreateFrames {

    public static void main(String[] args) throws PatriusException, IOException, URISyntaxException {

        // Patrius Dataset initialization (needed for example to get the UTC time)
        PatriusDataset.addResourcesFromPatriusDataset() ;
        
        // GCRF frame
        final Frame gcrf = FramesFactory.getGCRF();
        
        // Recovery of the UTC time scale using a "factory" (not to duplicate such unique object)
        final TimeScale TUC = TimeScalesFactory.getUTC();
        
        // Date of the orbit given in UTC time scale)
        final AbsoluteDate date = new AbsoluteDate("2010-01-01T12:00:00.000", TUC);
        
        // H0-n frame : n = 9s and reference longitude = 5 degrees
        final Frame h0n = FramesFactory.getH0MinusN("Test", date, 9, FastMath.toRadians(5.));

        // Printing frame informaton
        System.out.println();
        System.out.println("GCRF name: "+gcrf.getName());
        System.out.println("H0-n name: "+h0n.getName());

    }
    
}