Exemple #1
0
        public bool Evaluate(AgGatorPluginResultEvalEngineModel result)
        {
            if (result != null)
            {
                double eccAno = this.m_eccAno.Evaluate(result);
                double mass   = this.m_mass.Evaluate(result);

                double alphaS0 = this.m_AlphaS0.Evaluate(result);
                double alphaS1 = this.m_AlphaS1.Evaluate(result);
                double alphaS2 = this.m_AlphaS2.Evaluate(result);
                double betaS1  = this.m_BetaS1.Evaluate(result);
                double betaS2  = this.m_BetaS2.Evaluate(result);

                double FS = alphaS0 + alphaS1 * Math.Cos(eccAno) + alphaS2 * Math.Cos(2 * eccAno)
                            + betaS1 * Math.Sin(eccAno) + betaS2 * Math.Sin(2 * eccAno);

                //error on FR,W,S <=0

                if (FS < 0)
                {
                    FS = Math.Abs(FS);
                }
                else
                {
                    FS = 0;
                }

                double thrust = FS * mass;

                result.SetThrustAndIsp(thrust, Isp);
            }

            return(true);
        }
Exemple #2
0
        public bool Evaluate(AgGatorPluginResultEvalEngineModel result)
        {
            if (result != null)
            {
                //Debug.WriteLine(" Evaluate( " + this.GetHashCode() + " )");

                double eccAno = this.m_eccAno.Evaluate(result);
                double mass   = this.m_mass.Evaluate(result);

                double alphaW0 = this.m_AlphaW0.Evaluate(result);
                double alphaW1 = this.m_AlphaW1.Evaluate(result);
                double alphaW2 = this.m_AlphaW2.Evaluate(result);
                double betaW1  = this.m_BetaW1.Evaluate(result);
                double betaW2  = this.m_BetaW2.Evaluate(result);

                double FW = alphaW0 + alphaW1 * Math.Cos(eccAno) + alphaW2 * Math.Cos(2 * eccAno) +
                            betaW1 * Math.Sin(eccAno) + betaW2 * Math.Sin(2 * eccAno);
                //error on FR,W,S <=0

                if (FW < 0)
                {
                    FW = Math.Abs(FW);
                }
                else
                {
                    FW = 0;
                }

                double thrust = FW * mass;

                result.SetThrustAndIsp(thrust, Isp);
            }

            return(true);
        }
Exemple #3
0
        public bool Evaluate(AgGatorPluginResultEvalEngineModel result)
        {
            if (result != null)
            {
                double eccAno = this.m_eccAno.Evaluate(result);
                double mass   = this.m_mass.Evaluate(result);

                double alphaR0 = this.m_AlphaR0.Evaluate(result);
                double alphaR1 = this.m_AlphaR1.Evaluate(result);
                double alphaR2 = this.m_AlphaR2.Evaluate(result);
                double betaR1  = this.m_BetaR1.Evaluate(result);

                double FR = alphaR0 + alphaR1 * Math.Cos(eccAno) + alphaR2 * Math.Cos(2 * eccAno) +
                            betaR1 * Math.Sin(eccAno);

                //error on FR,W,S < 0
                //The thrust will error on negative in STK
                if (FR < 0)
                {
                    FR = Math.Abs(FR);
                }
                else
                {
                    FR = 0;
                }

                double thrust = FR * mass;

                result.SetThrustAndIsp(thrust, Isp);
            }
            return(true);
        }
Exemple #4
0
        public bool Evaluate(AgGatorPluginResultEvalEngineModel result)
        {
            if (result != null)
            {
                double eccAno = this.m_eccAno.Evaluate(result);
                double mass   = this.m_mass.Evaluate(result);

                // Output is given in m/s^2
                double alphaS0 = this.m_AlphaS0.Evaluate(result);
                double alphaS1 = this.m_AlphaS1.Evaluate(result);
                double alphaS2 = this.m_AlphaS2.Evaluate(result);
                double betaS1  = this.m_BetaS1.Evaluate(result);
                double betaS2  = this.m_BetaS2.Evaluate(result);

                double FS = alphaS0 + alphaS1 * Math.Cos(eccAno) + alphaS2 * Math.Cos(2 * eccAno)
                            + betaS1 * Math.Sin(eccAno) + betaS2 * Math.Sin(2 * eccAno);

                //error on FR,W,S <=0

                if (FS < 0)
                {
                    FS = 0;
                }

                //Debug.WriteLine(" Evaluate( " + this.GetHashCode() + " )");
                double thrust = FS * mass;

                result.SetThrustAndIsp(thrust, Isp);
            }

            return(true);
        }
Exemple #5
0
        public bool Evaluate(AgGatorPluginResultEvalEngineModel result)
        {
            if (result != null)
            {
                double mass = this.m_mass.Evaluate(result);

                double eccAno = this.m_eccAno.Evaluate(result);

                double alphaR0 = this.m_AlphaR0.Evaluate(result);
                double alphaR1 = this.m_AlphaR1.Evaluate(result);
                double alphaR2 = this.m_AlphaR2.Evaluate(result);
                double betaR1  = this.m_BetaR1.Evaluate(result);

                //Debug.WriteLine(" Evaluate( " + this.GetHashCode() + " )");

                //Debug.WriteLine("Alpha0: {0}\nAlpha1: {1}\nAlpha2: {2}\nAlpha3: {3}\nEccAno: {4}",
                // alphaR0, alphaR1, alphaR2, betaR1, eccAno);

                double FR = alphaR0 + alphaR1 * Math.Cos(eccAno) + alphaR2 * Math.Cos(2 * eccAno) +
                            betaR1 * Math.Sin(eccAno);
                //error on FR,W,S < 0

                if (FR < 0)
                {
                    FR = 0;
                }

                double thrust = FR * mass;

                result.SetThrustAndIsp(thrust, Isp);
            }
            return(true);
        }