Exemplo n.º 1
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsDensityConcentrationCalculator());
     Calculators.Add(new fsPorosityCalculator());
     Calculators.Add(new fsPermeabilityCalculator());
     Calculators.Add(new fsRm0Hce0Calculator());
     AddCakeFormationCalculator();
 }
Exemplo n.º 2
0
 private Thermo1CalculatorMgr()
 {
     Calculators.Add(new A117VcCalculator().Create());
     Calculators.Add(new A117FullModuleCalculator().Create());
     Calculators.Add(new A147VcCalculator().Create());
     Calculators.Add(new A147FullModuleCalculator().Create());
     Calculators.Add(new X1311Calculator().Create());
 }
Exemplo n.º 3
0
 protected override void AddCakeFormationCalculator()
 {
     Calculators.Add(new fsBeltFiltersWithReversibleTraysCalculator());
 }
Exemplo n.º 4
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(m_calculator);
 }
Exemplo n.º 5
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsPermeabilityCalculator());
 }
Exemplo n.º 6
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsDensityConcentrationCalculator());
 }
Exemplo n.º 7
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsDensityConcentrationCalculator());
     Calculators.Add(new fsPorosityCalculator());
     Calculators.Add(new fsLaboratoryFiltrationCalculator());
 }
Exemplo n.º 8
0
 protected override void AddCakeFormationCalculator()
 {
     Calculators.Add(new fsContinuousNonModularBeltFilterCalculator());
 }
Exemplo n.º 9
0
        public void CorrectAdditionResult(int a, int b, int expected)
        {
            var result = Calculators.Add(a, b);

            Assert.AreEqual(expected, result);
        }
Exemplo n.º 10
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsRfFromCakeSaturationCalculator());
 }
Exemplo n.º 11
0
        //Print Button
        private void BEqual_Click(object sender, RoutedEventArgs e)
        {
            if (printed == true)
            {
            }                        // if has been printed dont print again

            else if (operation == "+")
            {
                result         = (Calculators.Add(number1, number2));
                Resultbox.Text = result.ToString();
                FullText.Text += $" {number2} = {result}";
            }
            else if (operation == "-")
            {
                result         = (Calculators.Subtract(number1, number2));
                Resultbox.Text = result.ToString();
                FullText.Text += $" {number2} = {result}";
            }
            else if (operation == "*")
            {
                result         = (Calculators.Multiply(number1, number2));
                Resultbox.Text = result.ToString();
                FullText.Text += $" {number2} = {result}";
            }
            else if (operation == "/")
            {
                if (number2 == 0)
                {
                    Resultbox.Text = "Cannot divide by 0"; //this way you are ready to add the second number
                }
                else
                {
                    result         = (Calculators.Divide(number1, number2));
                    Resultbox.Text = result.ToString();
                    FullText.Text += $" {number2} = {result}";
                }
            }
            else if (operation == "%")
            {
                result         = (Calculators.Modulus(number1, number2));
                Resultbox.Text = result.ToString();
                FullText.Text += $" {number2} = {result}";
            }
            else if (operation == "^")
            {
                result         = (Calculators.PowerOf(number1, number2));
                Resultbox.Text = result.ToString();
                FullText.Text += $" {number2} = {result}";
            }
            else if (operation == "^ 2")
            {
                result         = Calculators.PowerOfTwo(number1);
                Resultbox.Text = result.ToString();
                FullText.Text += $" = {result}";
            }
            else if (operation == "sqrt(0)")
            {
                result         = Calculators.Root(number2);
                Resultbox.Text = $"sqrt({number2}) = {result}";
                FullText.Text  = $"sqrt({number2}) = {result}";
            }

            printed = true;
        }
Exemplo n.º 12
0
 protected override void InitializeCalculators()
 {
     Calculators.Add(new fsCakeWashingCalculator());
 }