Printing

De Wiki
Aller à : navigation, rechercher

Once the propogation done, it is possible to use some utilities methods to print results or store them in some files.

Printing results

First, we can use the printSV() method as in this example :

    test.printSV("BEGIN", iniOrbit, FramesFactory.getEME2000(), mm);
    final SpacecraftState sc = test.propagateInSlaveMode();
    test.printSV("END", sc.getOrbit(), FramesFactory.getEME2000(), mm);

This will display something like that ...

BEGIN
Frame          EME2000
Mass (kg)      1000.0    
T (h)          1.4917487906426035       
A (km)         6628.137000000006        
Ex             8.881784197001211E-16    
Ey             -8.542591124194022E-23   
Inc (deg)      51.59999810577826        
Raan (deg)     7.714051151482253E-6     
X (km)         6628.136999999962        
Y (km)         4.69158061035269E-4      
Z (km)         -5.339771250296284E-4    
Vx (km/s)      1.4865627172522409E-7    
Vy (km/s)      4.816905268016365        
Vz (km/s)      6.077421519614858        

END
Date (TAI)     2010-01-01T13:48:07.345  
Frame          EME2000                  
Mass (kg)      1000.0                   
T (h)          1.3468381128010898       
A (km)         6191.624504771174        
Ex             -0.06671952301093685     
Ey             -0.0300290461308641      
Inc (deg)      51.59999810577824        
Raan (deg)     7.714051168045088E-6     
X (km)         2163.0125242789236       
Y (km)         3798.414653291644        
Z (km)         4792.405891341955        
Vx (km/s)      -7.343036365577201       
Vy (km/s)      1.3329935495415233       
Vz (km/s)      1.6818204305631719       

Storing results

Another solution is to store results in ASCII VTS files when PSIMU is in master mode:

    final Psimu psimu = new Psimu(iniOrbit, EARTH, integrationData, assembly, mm, forces, manSeq, seqAtt);
 
    final OutputConfig output = new OutputConfig(FramesFactory.getEME2000(), LOFType.LVLH, 86400.);        
    psimu.propagateInMasterMode(output, null);
 
    psimu.saveVTSFiles("OUTPUT_JPSIMU", "test");

The last line of code will create VTS files (VTS_EPH_test.txt, VTS_EVE_test.txt and VTS_ATT_test.txt).