Example #1
0
        public void SimpleTest(double first, double expected)
        {
            Sinx   calculator = new Sinx();
            double result     = calculator.Doit(first);

            Assert.AreEqual(expected, result, 0.000001);
        }
Example #2
0
        public INode CreateSinX()
        {
            Console.WriteLine("-------------------");
            Console.WriteLine("įveskite skaičių a: ");
            string input = Console.ReadLine();
            var    a     = Double.Parse(input);

            Console.WriteLine("įveskite skaičių b: ");
            input = Console.ReadLine();
            var b = Double.Parse(input);

            Console.WriteLine("-------------------");
            var newItem = new Sinx(riba, a, b);

            newItem.Degree = accuracy;;
            newItem.CalculateExtansion();
            equation += ("sin(" + a + "x" + "+" + b + ")");
            Console.Write(equation);
            return(newItem);
        }