Exemplo n.º 1
0
        public CalculationResultModel ValueInProof(double alcoholStrengt)
        {
            _calculationValidation.CanNotBeZero(alcoholStrengt, "Alcohol Strengt");

            double Proof = (alcoholStrengt * 1.753) - 100;

            return(_resultCreation.SetResult(Proof, calculationModel.ValueInProofUnit, "Value In Proof"));
        }
Exemplo n.º 2
0
        public CalculationResultModel Heat_Mass(double energy, double heat, double aVATemperature)
        {
            _calculationValidation.LessThanZero(
                new List <double> {
                energy, heat, aVATemperature
            },
                new List <string>
            {
                "Energy", "Heat", "AVATemperature"
            });
            _calculationValidation.CanNotBeZero(heat, aVATemperature, "Heat", "AVG Temperature");

            double Mass = energy / (heat * aVATemperature);

            return(_resultCreation.SetResult(Mass, specificHeat.EnergyFormula, "Mass", specificHeat.MassUnit));
        }