AveragedEquinoctialWithMeanAngle.java

  1. /* Copyright 2020-2024 Exotrail
  2.  * Licensed to CS GROUP (CS) under one or more
  3.  * contributor license agreements.  See the NOTICE file distributed with
  4.  * this work for additional information regarding copyright ownership.
  5.  * CS licenses this file to You under the Apache License, Version 2.0
  6.  * (the "License"); you may not use this file except in compliance with
  7.  * the License.  You may obtain a copy of the License at
  8.  *
  9.  *   http://www.apache.org/licenses/LICENSE-2.0
  10.  *
  11.  * Unless required by applicable law or agreed to in writing, software
  12.  * distributed under the License is distributed on an "AS IS" BASIS,
  13.  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14.  * See the License for the specific language governing permissions and
  15.  * limitations under the License.
  16.  */
  17. package org.orekit.propagation.conversion.averaging.elements;

  18. /**
  19.  * Immutable class containing values of averaged equinoctial elements from any applicable theory
  20.  * (with MEAN as {@link org.orekit.orbits.PositionAngleType}).
  21.  *
  22.  * @author Romain Serra
  23.  * @see AveragedOrbitalElements
  24.  * @since 12.1
  25.  */
  26. public class AveragedEquinoctialWithMeanAngle implements AveragedOrbitalElements {

  27.     /** Averaged semi-major axis in arbitrary theory. */
  28.     private final double averagedSemiMajorAxis;
  29.     /** Averaged equinoctial ex in arbitrary theory. */
  30.     private final double averagedEquinoctialEx;
  31.     /** Averaged equinoctial ey in arbitrary theory. */
  32.     private final double averagedEquinoctialEy;
  33.     /** Averaged hx in arbitrary theory. */
  34.     private final double averagedHx;
  35.     /** Averaged hy in arbitrary theory. */
  36.     private final double averagedHy;
  37.     /** Averaged mean longitude argument in arbitrary theory. */
  38.     private final double averagedMeanLongitudeArgument;

  39.     /**
  40.      * Constructor.
  41.      * @param averagedSemiMajorAxis semi-major axis
  42.      * @param averagedEquinoctialEx equinoctial ex
  43.      * @param averagedEquinoctialEy equinoctial ey
  44.      * @param averagedHx hx
  45.      * @param averagedHy hy
  46.      * @param averagedMeanLongitudeArgument mean longitude argument
  47.      */
  48.     public AveragedEquinoctialWithMeanAngle(final double averagedSemiMajorAxis,
  49.                                             final double averagedEquinoctialEx,
  50.                                             final double averagedEquinoctialEy,
  51.                                             final double averagedHx,
  52.                                             final double averagedHy,
  53.                                             final double averagedMeanLongitudeArgument) {
  54.         this.averagedSemiMajorAxis = averagedSemiMajorAxis;
  55.         this.averagedEquinoctialEx = averagedEquinoctialEx;
  56.         this.averagedEquinoctialEy = averagedEquinoctialEy;
  57.         this.averagedHx = averagedHx;
  58.         this.averagedHy = averagedHy;
  59.         this.averagedMeanLongitudeArgument = averagedMeanLongitudeArgument;
  60.     }

  61.     /** {@inheritDoc} */
  62.     @Override
  63.     public double[] toArray() {
  64.         return new double[] { averagedSemiMajorAxis, averagedEquinoctialEx, averagedEquinoctialEy,
  65.             averagedHx, averagedHy, averagedMeanLongitudeArgument };
  66.     }

  67.     /**
  68.      * Getter for the averaged semi-major axis.
  69.      * @return semi-major axis.
  70.      */
  71.     public double getAveragedSemiMajorAxis() {
  72.         return averagedSemiMajorAxis;
  73.     }

  74.     /**
  75.      * Getter for the averaged equinoctial ex.
  76.      * @return ex
  77.      */
  78.     public double getAveragedEquinoctialEx() {
  79.         return averagedEquinoctialEx;
  80.     }

  81.     /**
  82.      * Getter for the averaged equinoctial ey.
  83.      * @return ey
  84.      */
  85.     public double getAveragedEquinoctialEy() {
  86.         return averagedEquinoctialEy;
  87.     }

  88.     /**
  89.      * Getter for the averaged hx.
  90.      * @return hx
  91.      */
  92.     public double getAveragedHx() {
  93.         return averagedHx;
  94.     }

  95.     /**
  96.      * Getter for the averaged hy.
  97.      * @return hy
  98.      */
  99.     public double getAveragedHy() {
  100.         return averagedHy;
  101.     }

  102.     /**
  103.      * Getter for the averaged mean longitude argument.
  104.      * @return mean longitude argument
  105.      */
  106.     public double getAveragedMeanLongitudeArgument() {
  107.         return averagedMeanLongitudeArgument;
  108.     }
  109. }