Esempio n. 1
0
        /// <summary>
        /// Method to return the Maximum value out of the MaxPos and MaxNeg keys. Used for <see cref="HeatMapMode.SpecialCase"/>
        /// </summary>
        /// <param name="_opChannel"></param>
        /// <param name="_resultsToEvaluate"></param>
        /// <returns></returns>
        public double ReturnMaxValue(string _opChannel, BatchRunResults _resultToEvaluate)
        {
            if (_resultToEvaluate.OutputChannels[_opChannel]["MaxPos"] > Math.Abs(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg"]))
            {
                return(_resultToEvaluate.OutputChannels[_opChannel]["MaxPos"]);
            }
            else if (_resultToEvaluate.OutputChannels[_opChannel]["MaxPos"] < Math.Abs(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg"]))
            {
                return(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg"]);
            }

            return(0);
        }
Esempio n. 2
0
        /// <summary>
        /// Method to compare the Most Positive and Most Negative value of Force that an Output Channel experiences when subject to Motion and return the Most Negative or Most Positive whichever is greater when the motion is divided into intervals of 10.
        /// </summary>
        /// <param name="_motionPercentage"></param>
        /// <param name="_opChannel"></param>
        /// <param name="_resultToEvaluate"></param>
        /// <returns></returns>
        public double ReturnMaxValue(int _motionPercentage, string _opChannel, BatchRunResults _resultToEvaluate)
        {
            if (_resultToEvaluate.OutputChannels[_opChannel]["MaxPos" + _motionPercentage] > Math.Abs(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg" + _motionPercentage]))
            {
                return(_resultToEvaluate.OutputChannels[_opChannel]["MaxPos" + _motionPercentage]);
            }
            else if (_resultToEvaluate.OutputChannels[_opChannel]["MaxPos" + _motionPercentage] < Math.Abs(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg" + _motionPercentage]))
            {
                return(_resultToEvaluate.OutputChannels[_opChannel]["MaxNeg" + _motionPercentage]);
            }

            return(0);
        }