public bool FINDTreeWithThreadConsiderationOfIntegrals(AddToTree.Tree Dummy, out float Quefiicent)
        {
            LinkListNodeClass Tracer = Node;
            bool Is = false;

            Quefiicent = 1;
            while (Tracer != null)
            {
                if (Tracer.CurrentAccess != null)
                {
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, Tracer.CurrentAccess))
                    {
                        Is = true;
                        //break;
                        Quefiicent = (float)System.Convert.ToDouble(Dummy.RightSideAccess.SampleAccess);
                    }
                }
                if (Tracer.CurrentAccess != null)
                {
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, Tracer.CurrentAccess))
                    {
                        Is         = true;
                        Quefiicent = (float)System.Convert.ToDouble(Dummy.LeftSideAccess.SampleAccess);
                        break;
                    }
                }
                Tracer = Tracer.NextAccess;
            }
            return(Is);
        }
 static AddToTree.Tree MinuseToPluSeconverterActionFx(AddToTree.Tree Dummy)
 {
     if (Dummy == null)
     {
         return(null);
     }
     try
     {
         if (Dummy.SampleAccess == "-")
         {
             if (Dummy.ThreadAccess.SampleAccess == "-")
             {
                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.RightSideAccess, Dummy))
                 {
                     Dummy.ThreadAccess.SampleAccess = "+";
                     AddToTree.Tree CONVERT = new AddToTree.Tree("*", false);
                     AddToTree.Tree Minuse  = new AddToTree.Tree("-1", false);
                     CONVERT.SetLefTandRightCommonlySide(Minuse, Dummy.CopyNewTree(Dummy.LeftSideAccess));
                     CONVERT.LeftSideAccess.ThreadAccess  = CONVERT;
                     CONVERT.RightSideAccess.ThreadAccess = CONVERT;
                     CONVERT.ThreadAccess = Dummy;
                     Dummy.LeftSideAccess = CONVERT;
                 }
             }
         }
     }
     catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
     MinuseToPluSeconverter.MinuseToPluSeconverterActionFx(Dummy.LeftSideAccess);
     MinuseToPluSeconverter.MinuseToPluSeconverterActionFx(Dummy.RightSideAccess);
     return(Dummy);
 }
        static private bool MulAndDivisionOnlySimplifierFindDivisionOperandIfIsDelettingFx(AddToTree.Tree Dummy, AddToTree.Tree NodeDeleted)
        {
            bool Is = false;

            if (Dummy == null)
            {
                return(Is);
            }
            if (MulAndDivisionOnlySimplifier.IsCurrentNodeMulOrDivisionOnly(Dummy))
            {
                if (!Is)
                {
                    if (Dummy.SampleAccess == "/")
                    {
                        if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, NodeDeleted))
                        {
                            AddToTree.Tree Num = new AddToTree.Tree("1", false);
                            Dummy.RightSideAccess = Num;
                            Dummy.RightSideAccess.LeftSideAccess  = Dummy.RightSideAccess;
                            Dummy.RightSideAccess.RightSideAccess = Dummy.RightSideAccess;
                            Is = true;
                        }
                    }
                }
            }
            Is = Is || MulAndDivisionOnlySimplifier.MulAndDivisionOnlySimplifierFindDivisionOperandIfIsDelettingFx(Dummy.LeftSideAccess, NodeDeleted);
            Is = Is || MulAndDivisionOnlySimplifier.MulAndDivisionOnlySimplifierFindDivisionOperandIfIsDelettingFx(Dummy.RightSideAccess, NodeDeleted);
            return(Is);
        }
        static AddToTree.Tree AddingSameUnderElementsSenderActionFx(AddToTree.Tree Node, AddToTree.Tree Dummy, ref bool CllingRightTrueLeftFalse, ref UknownIntegralSolver UIS)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            try
            {
                if ((IS.IsPluSinNode(Dummy)))
                {
                    CllingRightTrueLeftFalse = false;
                    Dummy.LeftSideAccess     = AddingSameUnderElements.AddingSameUnderElementsSenderActionFx(Node, Dummy.LeftSideAccess, ref CllingRightTrueLeftFalse, ref UIS);
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess.ThreadAccess, Dummy.ThreadAccess))
                    {
                        Dummy = Dummy.LeftSideAccess;
                    }
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            try
            {
                if ((IS.IsPluSinNode(Dummy)))
                {
                    CllingRightTrueLeftFalse = true;
                    Dummy.RightSideAccess    = AddingSameUnderElements.AddingSameUnderElementsSenderActionFx(Node, Dummy.RightSideAccess, ref CllingRightTrueLeftFalse, ref UIS);
                    //ERRORCORECTION6654444:The Deleting Unregular Plus Operator From Sin(x)^2 Integral:1394/4/6
                    if (Dummy.RightSideAccess.ThreadAccess != null && EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess.ThreadAccess, Dummy.ThreadAccess))
                    {
                        Dummy = Dummy.RightSideAccess;
                    }
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            if (Dummy.ThreadAccess != null)
            {
                if (!(((IS.IsMinuseOrPluse(Dummy.ThreadAccess.SampleAccess)))))
                {
                    return(Dummy);
                }
            }

            try
            {
                if ((Dummy.ThreadAccess == null) || (Dummy.ThreadAccess.SampleAccess == "+"))
                {
                    if (Dummy.SampleAccess == "/")
                    {
                        /*            if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.RightSideAccess, Dummy))
                         *              Dummy.ThreadAccess.LeftSideAccess = AddingSameUnderElements.AddingSameUnderElementsActionReciverFx(Node, Dummy.ThreadAccess.LeftSideAccess, Dummy,ref CllingRightTrueLeftFalse);
                         *          else
                         *              if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.LeftSideAccess, Dummy))
                         *                  Dummy.ThreadAccess.RightSideAccess = AddingSameUnderElements.AddingSameUnderElementsActionReciverFx(Node, Dummy.ThreadAccess.RightSideAccess, Dummy,ref CllingRightTrueLeftFalse);
                         */
                        Dummy.ThreadAccess = AddingSameUnderElements.AddingSameUnderElementsActionReciverFx(Node, Dummy.ThreadAccess, Dummy, ref CllingRightTrueLeftFalse, ref UIS);
                    }
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            return(Dummy);
        }
        public bool FINDTreeWithThreadConsideration(AddToTree.Tree Dummy)
        {
            LinkListNodeClass Tracer = Node;

            try
            {
            }
            catch (NullReferenceException k) { ExceptionClass.ExceptionClassMethod(k); }
            bool Is = false;

            while (Tracer != null)
            {
                if (Tracer.CurrentAccess != null)
                {
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy, Tracer.CurrentAccess))
                    {
                        Is = true;
                        break;
                    }
                }
                Tracer = Tracer.NextAccess;
            }

            return(Is);
        }
 static public AddToTree.Tree RecursiveIntegralAdditionFx(AddToTree.Tree Node, AddToTree.Tree Dummy, AddToTree.Tree MULTOW, float Queficient, AddToTreeTreeLinkList INTEGRALS, AddToTreeTreeLinkList ANSWER)
 {
     if (EqualToObject.IsEqualWithThreadConsiderationCommonly(MULTOW, Node))
     {
         Dummy = RecursiveIntegralAddition.RecursiveIntegralFxAdditionForLinearEquationOneDegrees(Node, Dummy, Queficient);
     }
     return(Dummy);
 }
示例#7
0
        static AddToTree.Tree FactorActivationActionFx(AddToTree.Tree Dummy, ref UknownIntegralSolver UIS)
        {
            //ERROR932875987 : Refer to page 301 :If The Non Copy of Dummy Passes to method the result of dummy become invalid.
            //AddToTree.Tree Factor = FactorActivation.GetBigestCommonFactor(Dummy.CopyNewTree(Dummy));
            AddToTreeTreeLinkList FactorLinkList = FactorActivation.GetBigestCommonFactor(Dummy.CopyNewTree(Dummy), ref UIS);
            bool Action = false;
            bool Mul    = false;

            if (!(FactorLinkList.ISEmpty()))
            {
                AddToTree.Tree Factor = new AddToTree.Tree(null, false);
                //ERROR293846210394 :The effection of Thread is not act on thread.
                //AddToTree.Tree Holder = Dummy.CopyNewTree(Dummy.ThreadAccess);
                //ERROCORECTION91827831294 :The thread validation is corrected.refer to page 335.
                AddToTree.Tree Holder = Dummy.ThreadAccess;

                bool LeftTrueRightFalse = false;
                try
                {
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.RightSideAccess, Dummy))
                    {
                        LeftTrueRightFalse = false;
                    }
                    else
                    {
                        LeftTrueRightFalse = true;
                    }
                }
                catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }

                Dummy.ThreadAccess = null;

                while (!(FactorLinkList.ISEmpty()))
                {
                    Factor = FactorLinkList.DELETEFromTreeFirstNode();
                    Dummy  = FactorActivation.FactorActivationDivActionFx(Dummy.CopyNewTree(Dummy), Factor, ref Action, ref Mul, FactorLinkList.CopyLinkList());
                }
                while (Dummy.ThreadAccess != null)
                {
                    Dummy = Dummy.ThreadAccess;
                }
                Dummy = Simplifier.SimplifierFxSimpler(Dummy, ref UIS);
                try
                {
                    if (!LeftTrueRightFalse)
                    {
                        Holder.RightSideAccess = Dummy;
                    }
                    else
                    {
                        Holder.LeftSideAccess = Dummy;
                    }
                }
                catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                Dummy.ThreadAccess = Holder;
            }
            return(Dummy);
        }
 static public bool IntegralRecursiveMulatFGFx(AddToTreeTreeLinkList MulAtFG, AddToTree.Tree Dummy, ref UknownIntegralSolver UIS)
 {
     AddToTree.Tree HOLDER = MulAtFG.DELETEFromTreeFirstNode();
     if (Dummy != null)
     {
         return(EqualToObject.IsEqualWithOutThreadConsiderationByDivision(HOLDER.CopyNewTree(HOLDER), Dummy.CopyNewTree(Dummy), ref UIS));
     }
     return(false);
 }
示例#9
0
        static AddToTree.Tree ConvertAllMinuseToPluseActionFx(AddToTree.Tree Dummy, ref UknownIntegralSolver UIS)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            int  INCREASE = 2147483647 / 3;
            bool SecOND   = true;

            try
            {
                UIS.SetProgressValue(UIS.progressBar5, 0);

                if ((Dummy.ThreadAccess.SampleAccess == "-") && (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.RightSideAccess, Dummy)))
                {
                    AddToTree.Tree ONE = new AddToTree.Tree("-1", false);
                    AddToTree.Tree ADD = new AddToTree.Tree("*", false);
                    //Dummy = Dummy.LeftSideAccess;
                    ADD.SetLefTandRightCommonlySide(Dummy.CopyNewTree(Dummy.LeftSideAccess), ONE);
                    ADD.LeftSideAccess.ThreadAccess  = ADD;
                    ADD.RightSideAccess.ThreadAccess = ADD;
                    Dummy = Dummy.ThreadAccess;
                    Dummy.SampleAccess   = "+";
                    Dummy.LeftSideAccess = ADD;
                    Dummy.LeftSideAccess.ThreadAccess = Dummy;
                    SecOND = false;
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            UIS.SetProgressValue(UIS.progressBar5, INCREASE + UIS.progressBar5.Value);

            try
            {
                if ((Dummy.SampleAccess == "-") && (SecOND))
                {
                    AddToTree.Tree ONE = new AddToTree.Tree("-1", false);
                    AddToTree.Tree ADD = new AddToTree.Tree("*", false);
                    ADD.SetLefTandRightCommonlySide(Dummy.CopyNewTree(Dummy.RightSideAccess), ONE);
                    ADD.LeftSideAccess.ThreadAccess  = ADD;
                    ADD.RightSideAccess.ThreadAccess = ADD;
                    Dummy.SampleAccess    = "+";
                    Dummy.RightSideAccess = ADD;
                    Dummy.RightSideAccess.ThreadAccess = Dummy;
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            UIS.SetProgressValue(UIS.progressBar5, 2147483647);
            Dummy.LeftSideAccess  = ConvertAllMinuseToPluse.ConvertAllMinuseToPluseActionFx(Dummy.LeftSideAccess, ref UIS);
            Dummy.RightSideAccess = ConvertAllMinuseToPluse.ConvertAllMinuseToPluseActionFx(Dummy.RightSideAccess, ref UIS);
            return(Dummy);
        }
示例#10
0
        static public bool IsEqualWithThreadConsiderationCommonly(AddToTree.Tree T1, AddToTree.Tree T2)
        {
            bool Is = false;

            if ((T1 == null) && (T2 == null))
            {
                return(true);
            }
            else
            if (!(((T1 != null) && (T2 != null))))
            {
                return(false);
            }
            try
            {
                //if ((T1.SampleAccess == T2.SampleAccess)&&(T1.NodeNumberAccess==T2.NodeNumberAccess))
                if (T1.SampleAccess == T2.SampleAccess)
                {
                    if ((T1.ThreadAccess == null) && (T2.ThreadAccess == null))
                    {
                        Is = true;
                    }
                    else
                    if (!(((T1.ThreadAccess != null) && (T2.ThreadAccess != null))))
                    {
                        Is = false;
                    }
                    else
                    if (T1.ThreadAccess.SampleAccess == T2.ThreadAccess.SampleAccess)
                    {
                        Is = true;
                    }
                }
                else
                {
                    Is = false;
                }
            }
            catch (NullReferenceException t)
            {
                ExceptionClass.ExceptionClassMethod(t);
            }
            if (!Is)
            {
                return(Is);
            }
            Is = Is && EqualToObject.IsEqualWithThreadConsiderationCommonly(T1.LeftSideAccess, T2.LeftSideAccess);
            Is = Is && EqualToObject.IsEqualWithThreadConsiderationCommonly(T1.RightSideAccess, T2.RightSideAccess);

            return(Is);
        }
示例#11
0
 static AddToTree.Tree ConvertExtraFactorsToone(AddToTree.Tree Dummy, AddToTree.Tree Factors, ref bool Action, bool Current)
 {
     if (Dummy == null)
     {
         return(Dummy);
     }
     if ((EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, Factors)) && (!Action) && (!Current))
     {
         Action = true;
         Dummy.SetLefTandRightCommonlySide(null, null);
         Dummy.SampleAccess = "1";
     }
     Dummy.LeftSideAccess  = FactorActivation.ConvertExtraFactorsToone(Dummy.LeftSideAccess, Factors, ref Action, Current);
     Dummy.RightSideAccess = FactorActivation.ConvertExtraFactorsToone(Dummy.RightSideAccess, Factors, ref Action, Current);
     return(Dummy);
 }
示例#12
0
        static bool ExistElementOnAllMulatedNodesAction(AddToTree.Tree Dummy, AddToTreeTreeLinkList MULATEDELEMENTS)
        {
            bool Is = false;

            AddToTree.Tree MuLnode = new AddToTree.Tree(null, false);
            while (!(MULATEDELEMENTS.ISEmpty()))
            {
                MuLnode = MULATEDELEMENTS.DELETEFromTreeFirstNode();
                if (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, MuLnode))
                {
                    Is = true;
                    break;
                }
            }
            return(Is);
        }
示例#13
0
        static AddToTree.Tree ArrangmentNumberAndX(AddToTree.Tree Dummy)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            if (Dummy.LeftSideAccess != null)
            {
                if (Dummy.RightSideAccess != null)
                {
                    if ((Dummy.SampleAccess == "*") || (Dummy.SampleAccess == "+"))
                    {
                        if (Dummy.ThreadAccess != null)
                        {
                            if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.LeftSideAccess, Dummy))
                            {
                                //if (IS.ISindependenceVaribaleOrNumber(Dummy.LeftSideAccess.SampleAccess))
                                //if (!IS.IsOperator(Dummy.LeftSideAccess.SampleAccess))
                                if (IS.IsDiv(Dummy.RightSideAccess.SampleAccess))
                                {
                                    Dummy.SetLefTandRightCommonlySide(Dummy.RightSideAccess, Dummy.LeftSideAccess);
                                }
                            }
                            else
                            if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.ThreadAccess.RightSideAccess, Dummy))
                            {
                                //if (IS.ISindependenceVaribaleOrNumber(Dummy.RightSideAccess.SampleAccess))
                                //if(!IS.IsOperator(Dummy.RightSideAccess.SampleAccess))
                                if (IS.IsDiv(Dummy.LeftSideAccess.SampleAccess))
                                {
                                    Dummy.SetLefTandRightCommonlySide(Dummy.RightSideAccess, Dummy.LeftSideAccess);
                                }
                            }
                        }

                        /*
                         * if (IS.ISindependenceVaribaleOrNumber(Dummy.LeftSideAccess.SampleAccess))
                         * Dummy.SetLefTandRightCommonlySide(Dummy.RightSideAccess, Dummy.LeftSideAccess);
                         */
                    }
                }
            }

            MulDivisionSorter.ArrangmentNumberAndX(Dummy.LeftSideAccess);
            MulDivisionSorter.ArrangmentNumberAndX(Dummy.RightSideAccess);
            return(Dummy);
        }
 static AddToTree.Tree SimplifierCommonSubFactorActionRightSideFx(AddToTree.Tree Dummy, AddToTree.Tree COMMONSUBFACTOR, ref bool END, AddToTreeTreeLinkList NOTFACTOR)
 {
     if (Dummy == null)
     {
         return(Dummy);
     }
     if (Dummy.SampleAccess != "*")
     {
         if (NOTFACTOR.FINDTreeWithOutThreadConsideration(Dummy))
         {
             return(Dummy);
         }
     }
     if (END)
     {
         return(Dummy);
     }
     try
     {   //ERROCRECTIOn98217487 :the last condition (Dummy.ThreadAccess.SampleAccess) is Div.
         if ((EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, COMMONSUBFACTOR) && (Dummy.ThreadAccess.SampleAccess == "*") || (Dummy.ThreadAccess.SampleAccess == "/")))
         {
             Dummy.SetLefTandRightCommonlySide(null, null);
             Dummy.SampleAccess = "1";
             END = true;
         }
         else
         if ((Dummy.ThreadAccess.SampleAccess == "^") && (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, COMMONSUBFACTOR)) && (IS.IsNumber(Dummy.ThreadAccess.RightSideAccess.SampleAccess)))
         {
             float NUM = (float)System.Convert.ToDouble(Dummy.ThreadAccess.RightSideAccess.SampleAccess);
             NUM = NUM - 1;
             if (NUM > 0)
             {
                 Dummy.ThreadAccess.RightSideAccess.SampleAccess = NUM.ToString();
             }
             else
             {
                 Dummy.SetLefTandRightCommonlySide(null, null);
                 Dummy.SampleAccess = "1";
             }
             END = true;
         }
     }
     catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
     Dummy.LeftSideAccess  = SimplifierCommonSubFactor.SimplifierCommonSubFactorActionRightSideFx(Dummy.LeftSideAccess, COMMONSUBFACTOR, ref END, NOTFACTOR);
     Dummy.RightSideAccess = SimplifierCommonSubFactor.SimplifierCommonSubFactorActionRightSideFx(Dummy.RightSideAccess, COMMONSUBFACTOR, ref END, NOTFACTOR);
     return(Dummy);
 }
示例#15
0
 static AddToTree.Tree CommonFactorCalcultor(AddToTree.Tree Dummy1, AddToTree.Tree Dummy2)
 {
     AddToTree.Tree Dummy = new AddToTree.Tree("*", false);
     Dummy1.ThreadAccess = null;
     Dummy2.ThreadAccess = null;
     if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy1, Dummy2))
     {
         Dummy = Dummy1;
     }
     else
     {
         Dummy.SetLefTandRightCommonlySide(Dummy1, Dummy2);
         Dummy.LeftSideAccess.ThreadAccess  = Dummy;
         Dummy.RightSideAccess.ThreadAccess = Dummy;
     }
     return(Dummy);
 }
        static AddToTree.Tree SimplifierCommonSubFactorActionLeftSideFx(AddToTree.Tree Dummy, AddToTree.Tree COMMONSUBFACTOR, ref bool END, AddToTreeTreeLinkList NOTFACTOR)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            if (Dummy.SampleAccess != "*")
            {
                if (NOTFACTOR.FINDTreeWithOutThreadConsideration(Dummy))
                {
                    return(Dummy);
                }
            }
            if (END)
            {
                return(Dummy);
            }
            if ((Dummy.ThreadAccess.SampleAccess == "*") && (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, COMMONSUBFACTOR)))
            {
                Dummy.SetLefTandRightCommonlySide(null, null);
                Dummy.SampleAccess = "1";
                END = true;
            }
            else
            if ((Dummy.ThreadAccess.SampleAccess == "^") && (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy.ThreadAccess.LeftSideAccess, COMMONSUBFACTOR)) && (IS.IsNumber(Dummy.ThreadAccess.RightSideAccess.SampleAccess)))
            {
                float NUM = (float)System.Convert.ToDouble(Dummy.ThreadAccess.RightSideAccess.SampleAccess);
                NUM = NUM - 1;
                if (NUM > 0)
                {
                    Dummy.ThreadAccess.RightSideAccess.SampleAccess = NUM.ToString();
                }
                else
                {
                    Dummy.SetLefTandRightCommonlySide(null, null);
                    Dummy.SampleAccess = "1";
                }
                END = true;
            }

            Dummy.LeftSideAccess  = SimplifierCommonSubFactor.SimplifierCommonSubFactorActionLeftSideFx(Dummy.LeftSideAccess, COMMONSUBFACTOR, ref END, NOTFACTOR);
            Dummy.RightSideAccess = SimplifierCommonSubFactor.SimplifierCommonSubFactorActionLeftSideFx(Dummy.RightSideAccess, COMMONSUBFACTOR, ref END, NOTFACTOR);
            return(Dummy);
        }
示例#17
0
        static public bool IsNotUpperPowerOfNodeInList(AddToTree.Tree Dummy, AddToTreeTreeLinkList AbaledFactors, ref float PowerExsistNumber)
        {
            bool Is = false;

            AddToTree.Tree AbaledNode = new AddToTree.Tree(null, false);
            bool           OPERATION  = false;

            while (!(AbaledFactors.ISEmpty()))
            {
                AbaledNode = AbaledFactors.DELETEFromTreeFirstNode();
                if (AbaledNode.SampleAccess == "^")
                {
                    if (Dummy.SampleAccess == "^")
                    {
                        if (IS.IsNumber(Dummy.RightSideAccess.SampleAccess))
                        {
                            if (IS.IsNumber(AbaledNode.RightSideAccess.SampleAccess))
                            {
                                if (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy.LeftSideAccess, AbaledNode.LeftSideAccess))
                                {
                                    float NumDummy  = (float)(System.Convert.ToDouble(Dummy.RightSideAccess.SampleAccess));
                                    float NumAbaled = (float)(System.Convert.ToDouble(AbaledNode.RightSideAccess.SampleAccess));
                                    if (NumAbaled < NumDummy)
                                    {
                                        Is = true;
                                    }
                                    PowerExsistNumber = NumAbaled;
                                    OPERATION         = true;
                                    break;
                                }
                            }
                        }
                    }
                }
            }
            if (AbaledFactors.ISEmpty() || (!OPERATION))
            {
                Is = true;
            }
            return(Is);
        }
示例#18
0
        static public bool IsEqualWithOutThreadConsiderationCommonly(AddToTree.Tree T1, AddToTree.Tree T2)
        {
            bool Is = false;

            if ((T1 == null) && (T2 == null))
            {
                return(true);
            }
            else
            if (!(((T1 != null) && (T2 != null))))
            {
                return(false);
            }
            try
            {
                //if ((T1.SampleAccess == T2.SampleAccess)&&(T1.NodeNumberAccess==T2.NodeNumberAccess))
                if (T1.SampleAccess == T2.SampleAccess)
                {
                    Is = true;
                }
                else
                if (IS.IsNumber(T1.SampleAccess) && IS.IsNumber(T2.SampleAccess) && (System.Math.Abs(System.Convert.ToDouble(T1.SampleAccess) - System.Convert.ToDouble(T2.SampleAccess)) < 0.001))
                {
                    Is = true;
                }
                else
                {
                    Is = false;
                }
            }
            catch (NullReferenceException t)
            {
                ExceptionClass.ExceptionClassMethod(t);
            }
            Is = Is && EqualToObject.IsEqualWithThreadConsiderationCommonly(T1.LeftSideAccess, T2.LeftSideAccess);
            Is = Is && EqualToObject.IsEqualWithThreadConsiderationCommonly(T1.RightSideAccess, T2.RightSideAccess);

            return(Is);
        }
        public AddToTree.Tree DELETEFromTreeFindedNode(AddToTree.Tree DummyToDeleted)
        {
            AddToTree.Tree RETURN = null;
            if (Node != null)
            {
                if (!ISEmpty())
                {
                    try
                    {
                        LinkListNodeClass Dummy = Node;

                        while ((Dummy != null) && (!(EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy.CurrentAccess, DummyToDeleted))))
                        {
                            Dummy = Dummy.NextAccess;
                        }
                        if (Dummy != null)
                        {
                            if (Dummy.NextAccess != null)
                            {
                                Dummy.NextAccess.ThreadAccess = Dummy.ThreadAccess;
                            }
                            Dummy = Dummy.NextAccess;
                        }
                        SetNode(Dummy);
                        CurrentSize--;
                    }
                    catch (NullReferenceException t)
                    {
                        ExceptionClass.ExceptionClassMethod(t);
                        //       System.Windows.Forms.MessageBox.Show("Invalide Deletion Finded Node.");
                    }
                }
            }
            else
            {
                CurrentSize = -1;
            }
            return(RETURN);
        }
        static public bool IntegralRecursiveMulatFPowerGFx(AddToTree.Tree Integral, AddToTree.Tree Dummy, ref UknownIntegralSolver UIS, ref float Queficient)
        {
            AddToTree.Tree HOLDER = new AddToTree.Tree(null, false);
            bool           Istrue = false;

            /*  while(!(MulAtFG.ISEmpty()))
             * {
             *    HOLDER = MulAtFG.DELETEFromTreeFirstNode();
             *
             *    if (HOLDER != null)
             */
            Istrue = EqualToObject.IsEqualWithOutThreadConsiderationByDivision(Integral, Dummy, ref UIS, ref Queficient);

            /*   else break;
             */
            if (Istrue)
            {
                return(Istrue);
            }

            //}
            return(false);
        }
 static private AddToTree.Tree FindAndIndicatingRecursiveIntegralsFxLinrearFx(AddToTree.Tree Node, AddToTree.Tree MULTOW, out bool IntegralA, out float Queficient)
 {
     if (MULTOW.SampleAccess == "*")
     {
         //if (INTEGRALS.FINDTreeWithThreadConsideration(MULTOW.LeftSideAccess))
         if (EqualToObject.IsEqualWithThreadConsiderationCommonly(MULTOW.LeftSideAccess, Node))
         {
             Queficient          = (float)System.Convert.ToDouble(MULTOW.RightSideAccess.SampleAccess);
             Queficient          = Queficient * (-1);
             MULTOW              = MULTOW.LeftSideAccess;
             MULTOW.ThreadAccess = null;
             IntegralA           = true;
         }
         else
         //if (INTEGRALS.FINDTreeWithThreadConsideration(MULTOW.RightSideAccess))
         if (EqualToObject.IsEqualWithThreadConsiderationCommonly(MULTOW.RightSideAccess, Node))
         {
             Queficient          = (float)System.Convert.ToDouble(MULTOW.LeftSideAccess.SampleAccess);
             Queficient          = Queficient * (-1);
             MULTOW              = MULTOW.RightSideAccess;
             MULTOW.ThreadAccess = null;
             IntegralA           = true;
         }
         else
         {
             IntegralA  = false;
             Queficient = 0;
         }
     }
     else
     {
         IntegralA  = false;
         Queficient = 0;
     }
     return(MULTOW);
 }
 static AddToTree.Tree SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(AddToTree.Tree Dummy, AddToTree.Tree ToSimplified, ref bool Suitable, ref bool MinuseTruePlusFalse, ref bool SimplifiedTrueOtherWiseFalse, ref float Num)
 {
     if (Dummy == null)
     {
         return(Dummy);
     }
     try
     {
         if (IS.IsMinuseOrPluse(Dummy.SampleAccess))
         {
             if (EqualToObject.IsEqual(Dummy.LeftSideAccess, ToSimplified))
             {
                 if (IS.IsNumber(Dummy.RightSideAccess.SampleAccess))
                 {
                     Num = (float)System.Convert.ToDouble(Dummy.RightSideAccess.SampleAccess);
                     try
                     {
                         if ((ToSimplified.ThreadAccess.ThreadAccess == null) && (Dummy.SampleAccess == "-"))
                         {
                             SimplifiedTrueOtherWiseFalse = true;
                             MinuseTruePlusFalse          = true;
                             //LOCATION81726487 :refer to page 265.
                             AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                             Dummy = Dummy.ThreadAccess;
                             if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                             {
                                 Dummy.RightSideAccess.SetLeftAndRightSide(null, null);
                                 Dummy.RightSideAccess.SampleAccess = null;
                             }
                             else
                             if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                             {
                                 //        Dummy.LeftSideAccess.RightSideAccess.ThreadAccess = Dummy;
                                 //      Dummy.LeftSideAccess = Dummy.LeftSideAccess.RightSideAccess;
                                 Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                 Dummy.LeftSideAccess.SampleAccess = null;
                             }
                             Suitable = true;
                             return(Dummy);
                         }
                         else
                         if ((ToSimplified.ThreadAccess.ThreadAccess != null) && (Dummy.ThreadAccess.SampleAccess == "-"))
                         {
                             if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "+") && (Dummy.ThreadAccess.SampleAccess == "-"))
                             {
                                 SimplifiedTrueOtherWiseFalse = true;
                                 MinuseTruePlusFalse          = true;
                                 //LOCATION81987526487 :refer to page 265.
                                 AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                                 Dummy = Dummy.ThreadAccess;
                                 if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                                 {
                                     Dummy.RightSideAccess.SetLeftAndRightSide(null, null);
                                     Dummy.RightSideAccess.SampleAccess = null;
                                 }
                                 else
                                 if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                                 {
                                     Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                     Dummy.LeftSideAccess.SampleAccess = null;
                                 }
                                 Suitable = true;
                                 return(Dummy);
                             }
                             else
                             if ((ToSimplified.ThreadAccess.ThreadAccess != null) && (Dummy.ThreadAccess.SampleAccess == "+"))
                             {
                                 if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "-") && (Dummy.ThreadAccess.SampleAccess == "+"))
                                 {
                                     SimplifiedTrueOtherWiseFalse = true;
                                     MinuseTruePlusFalse          = false;
                                     //LOCATION81987526487 :refer to page 265.
                                     AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                                     Dummy = Dummy.ThreadAccess;
                                     if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                                     {
                                         Dummy.RightSideAccess.SetLeftAndRightSide(null, null);
                                         Dummy.RightSideAccess.SampleAccess = null;
                                     }
                                     else
                                     if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                                     {
                                         Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                         Dummy.LeftSideAccess.SampleAccess = null;
                                     }
                                     Suitable = true;
                                     return(Dummy);
                                 }
                             }
                         }
                     }
                     catch (NullReferenceException t)
                     { }
                 }
                 else
                 if (EqualToObject.IsEqual(Dummy.RightSideAccess, ToSimplified))
                 {
                     if (IS.IsNumber(Dummy.LeftSideAccess.SampleAccess))
                     {
                         Dummy.RightSideAccess.SampleAccess = null;
                         try
                         {
                             Num = (float)System.Convert.ToDouble(Dummy.LeftSideAccess.SampleAccess);
                             if ((ToSimplified.ThreadAccess.ThreadAccess == null) && (Dummy.SampleAccess == "-"))
                             {
                                 SimplifiedTrueOtherWiseFalse = true;
                                 MinuseTruePlusFalse          = true;
                                 //LOCATION81726487 :refer to page 265.
                                 AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                                 Dummy = Dummy.ThreadAccess;
                                 if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                                 {
                                     Dummy.RightSideAccess.SetLeftAndRightSide(null, null);
                                     Dummy.RightSideAccess.SampleAccess = null;
                                 }
                                 else
                                 if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                                 {
                                     Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                     Dummy.LeftSideAccess.SampleAccess = null;
                                 }
                                 Suitable = true;
                                 return(Dummy);
                             }
                             else
                             if ((ToSimplified.ThreadAccess.ThreadAccess != null) && (Dummy.SampleAccess == "-"))
                             {
                                 if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "+") && (Dummy.SampleAccess == "-"))
                                 {
                                     SimplifiedTrueOtherWiseFalse = true;
                                     MinuseTruePlusFalse          = true;
                                     //LOCATION81987526487 :refer to page 265.
                                     AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                                     Dummy = Dummy.ThreadAccess;
                                     if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                                     {
                                         Dummy.RightSideAccess.LeftSideAccess.ThreadAccess = Dummy;
                                         Dummy.RightSideAccess = Dummy.RightSideAccess.LeftSideAccess;
                                     }
                                     else
                                     if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                                     {
                                         Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                         Dummy.LeftSideAccess.SampleAccess = null;
                                     }
                                     Suitable = true;
                                     return(Dummy);
                                 }
                                 else
                                 if ((ToSimplified.ThreadAccess.ThreadAccess != null) && (Dummy.SampleAccess == "+"))
                                 {
                                     if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "+"))
                                     {
                                         SimplifiedTrueOtherWiseFalse = true;
                                         MinuseTruePlusFalse          = false;
                                         //LOCATION81987526487 :refer to page 265.
                                         AddToTree.Tree HOLDER = Dummy.CopyTree(Dummy);
                                         Dummy = Dummy.ThreadAccess;
                                         if (EqualToObject.IsEqual(Dummy.RightSideAccess, HOLDER))
                                         {
                                             Dummy.RightSideAccess.SetLeftAndRightSide(null, null);
                                             Dummy.RightSideAccess.SampleAccess = null;
                                         }
                                         else
                                         if (EqualToObject.IsEqual(Dummy.LeftSideAccess, HOLDER))
                                         {
                                             Dummy.LeftSideAccess.SetLeftAndRightSide(null, null);
                                             Dummy.LeftSideAccess.SampleAccess = null;
                                         }
                                         Suitable = true;
                                         return(Dummy);
                                     }
                                 }
                             }
                         }
                         catch (NullReferenceException t)
                         { }
                     }
                 }
             }
         }
         else
         {
             return(Dummy);
         }
     }
     catch (NullReferenceException t)
     { }
     LocalSearchMinusPlusWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(Dummy.LeftSideAccess, ToSimplified, ref Suitable, ref MinuseTruePlusFalse, ref SimplifiedTrueOtherWiseFalse, ref Num);
     LocalSearchMinusPlusWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(Dummy.RightSideAccess, ToSimplified, ref Suitable, ref MinuseTruePlusFalse, ref SimplifiedTrueOtherWiseFalse, ref Num);
     return(Dummy);
 }
示例#23
0
        static private AddToTree.Tree TrasmisionActionHole(AddToTree.Tree Dummy)
        {
            //ERROR13107142 :This code cuased to an infinite loop.refer to page 182.
            if (Dummy == null)
            {
                return(Dummy);
            }
            TransmisionToDeleteingMinusPluse.TrasmisionActionHole(Dummy.LeftSideAccess);
            TransmisionToDeleteingMinusPluse.TrasmisionActionHole(Dummy.RightSideAccess);
            try
            {
                bool           ABLE          = false;
                AddToTree.Tree CurrentObject = Dummy;
                AddToTree.Tree NODE          = Dummy;
                AddToTree.Tree FIRST         = Dummy;
                while ((IS.IsOperator(FIRST.SampleAccess)) && (FIRST.SampleAccess != "/") && (FIRST.SampleAccess != "^") && (FIRST.ThreadAccess != null))
                {
                    FIRST = FIRST.ThreadAccess;
                }

                int DeepLeft = 0;
                while ((NODE.LeftSideAccess != null) && (IS.IsOperator(NODE.SampleAccess)) && (NODE.SampleAccess != "/") && (NODE.SampleAccess != "^"))
                {
                    NODE = NODE.LeftSideAccess;
                    DeepLeft++;
                }
                //ERRORCORECTION9872423784 :The ERRORCUASE713040 Correction.refer to page 182.
                if (NODE.LeftSideAccess != null)
                {
                    if (NODE.LeftSideAccess.LeftSideAccess != null)
                    {
                        ABLE = true;
                    }
                }

                if (ABLE)
                {
                    if (DeepLeft > 1)
                    {
                        AddToTree.Tree Last = NODE.CopyNewTree(NODE.ThreadAccess);

                        Dummy = Dummy.FINDTreeWithThreadConsideration(Dummy, FIRST);
                        AddToTree.Tree Holder = Dummy.RightSideAccess;
                        Dummy.SetLefTandRightCommonlySide(Dummy.LeftSideAccess, Last.LeftSideAccess);
                        Dummy.LeftSideAccess.ThreadAccess  = Dummy;
                        Dummy.RightSideAccess.ThreadAccess = Dummy;

                        while (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, Last))
                        {
                            Dummy = Dummy.LeftSideAccess;
                        }
                        Dummy.LeftSideAccess = Holder;

                        Dummy.LeftSideAccess.ThreadAccess  = Dummy;
                        Dummy.RightSideAccess.ThreadAccess = Dummy;
                        while ((Dummy.ThreadAccess != null) && (!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy, CurrentObject)))
                        {
                            Dummy = Dummy.ThreadAccess;
                        }
                    }
                }

                ABLE  = false;
                NODE  = Dummy;
                FIRST = Dummy;

                while ((IS.IsOperator(FIRST.SampleAccess)) && (FIRST.SampleAccess != "^") && (FIRST.SampleAccess != "/") && (FIRST.ThreadAccess != null))
                {
                    FIRST = FIRST.ThreadAccess;
                }

                int DeepRight = 0;
                while ((NODE.RightSideAccess != null) && (IS.IsOperator(NODE.SampleAccess)) && (NODE.SampleAccess != "/") && (NODE.SampleAccess != "^"))
                {
                    NODE = NODE.RightSideAccess;
                    DeepRight++;
                }
                //ERRORCORECTION9872423784 :The ERRORCUASE713040 Correction.refer to page 182.
                if (NODE.RightSideAccess != null)
                {
                    if (NODE.RightSideAccess.RightSideAccess != null)
                    {
                        ABLE = false;
                    }
                }

                if (ABLE)
                {
                    if (DeepRight > 1)
                    {
                        AddToTree.Tree Last = NODE.CopyNewTree(NODE.ThreadAccess);
                        Dummy = Dummy.FINDTreeWithThreadConsideration(Dummy, FIRST);
                        AddToTree.Tree Holder = Dummy.LeftSideAccess;
                        Dummy.SetLefTandRightCommonlySide(Last.RightSideAccess, Dummy.RightSideAccess);
                        Dummy.LeftSideAccess.ThreadAccess  = Dummy;
                        Dummy.RightSideAccess.ThreadAccess = Dummy;

                        while (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, Last))
                        {
                            Dummy = Dummy.RightSideAccess;
                        }
                        Dummy.RightSideAccess              = Holder;
                        Dummy.LeftSideAccess.ThreadAccess  = Dummy;
                        Dummy.RightSideAccess.ThreadAccess = Dummy;
                        while ((Dummy.ThreadAccess != null) && (!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy, CurrentObject)))
                        {
                            Dummy = Dummy.ThreadAccess;
                        }
                    }
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            return(Dummy);
        }
        static AddToTree.Tree SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(AddToTree.Tree Dummy, AddToTree.Tree ToSimplified, ref bool Suitable, ref bool MinuseTruePlusFalse, ref bool SimplifiedTrueOtherWiseFalse, ref float Num)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            AddToTree.Tree HOLDERCATCH = Dummy;
            try
            {
                if (IS.IsMinuseOrPluse(Dummy.SampleAccess))
                {
                    if ((EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess.RightSideAccess, ToSimplified.RightSideAccess)) && (IS.IsNumber(Dummy.LeftSideAccess.LeftSideAccess.SampleAccess)))
                    {
                        try
                        {
                            Num = (float)System.Convert.ToDouble(Dummy.LeftSideAccess.LeftSideAccess.SampleAccess);
                            //Dummy = Dummy.LeftSideAccess.RightSideAccess;
                            if ((ToSimplified.ThreadAccess == null) && (Dummy.SampleAccess == "-"))
                            {
                                SimplifiedTrueOtherWiseFalse = true;
                                MinuseTruePlusFalse          = true;
                                Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                Dummy.LeftSideAccess.SampleAccess = null;
                                //LOCATION81726487 :refer to page 265.
                                AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);

                                /*Dummy = Dummy.ThreadAccess;
                                 * if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 * {
                                 *  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *  Dummy.RightSideAccess.SampleAccess = null;
                                 * }
                                 * else
                                 *  if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 *  {
                                 *      //        Dummy.LeftSideAccess.RightSideAccess.ThreadAccess = Dummy;
                                 *      //      Dummy.LeftSideAccess = Dummy.LeftSideAccess.RightSideAccess;
                                 *      Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *      Dummy.LeftSideAccess.SampleAccess = null;
                                 *  }
                                 */
                                Suitable = true;
                                return(Dummy);
                            }
                            else
                            if ((ToSimplified.ThreadAccess != null) && (Dummy.SampleAccess == "-"))
                            {
                                if ((ToSimplified.ThreadAccess.SampleAccess == "+") && (Dummy.SampleAccess == "-"))
                                {
                                    SimplifiedTrueOtherWiseFalse = true;
                                    MinuseTruePlusFalse          = true;
                                    Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                    Dummy.LeftSideAccess.SampleAccess = null;
                                    //LOCATION81987526487 :refer to page 265.

                                    /*        AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                     *      Dummy = Dummy.ThreadAccess;
                                     *      if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                     *      {
                                     *          Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                     *          Dummy.RightSideAccess.SampleAccess = null;
                                     *      }
                                     *      else
                                     *          if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                     *          {
                                     *              Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                     *              Dummy.LeftSideAccess.SampleAccess = null;
                                     *          }
                                     */
                                    Suitable = true;
                                    return(Dummy);
                                }
                                else
                                if ((ToSimplified.ThreadAccess != null) && (Dummy.SampleAccess == "+"))
                                {
                                    if ((ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "+"))
                                    {
                                        SimplifiedTrueOtherWiseFalse = true;
                                        MinuseTruePlusFalse          = false;
                                        Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                        Dummy.LeftSideAccess.SampleAccess = null;
                                        //LOCATION81987526487 :refer to page 265.

                                        /*AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                         * Dummy = Dummy.ThreadAccess;
                                         * if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                         * {
                                         *  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                         *  Dummy.RightSideAccess.SampleAccess = null;
                                         * }
                                         * else
                                         *  if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                         *  {
                                         *      Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                         *      Dummy.LeftSideAccess.SampleAccess = null;
                                         *  }
                                         */
                                        Suitable = true;
                                        return(Dummy);
                                    }
                                    else
                                    if ((ToSimplified.ThreadAccess != null) && (Dummy.SampleAccess == "-"))
                                    {
                                        if ((ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "-"))
                                        {
                                            SimplifiedTrueOtherWiseFalse = true;
                                            MinuseTruePlusFalse          = true;
                                            Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                            Dummy.LeftSideAccess.SampleAccess = null;
                                            //LOCATION81987526487 :refer to page 265.

                                            /*        AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                             *      Dummy = Dummy.ThreadAccess;
                                             *      if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                             *      {
                                             *          Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                             *          Dummy.RightSideAccess.SampleAccess = null;
                                             *      }
                                             *      else
                                             *          if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                             *          {
                                             *              Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                             *              Dummy.LeftSideAccess.SampleAccess = null;
                                             *          }
                                             */
                                            Suitable = true;
                                            return(Dummy);
                                        }
                                    }
                                }
                            }
                        }

                        /*if (SimplifiedTrueOtherWiseFalse)
                         *  Dummy = Dummy.ThreadAccess;
                         * else
                         *  Dummy = Dummy.ThreadAccess.ThreadAccess;
                         * }
                         */
                        catch (NullReferenceException t) { Dummy = HOLDERCATCH;
                                                           ExceptionClass.ExceptionClassMethod(t); }
                    }
                    else
                    if ((EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess.RightSideAccess, ToSimplified.RightSideAccess)) & (IS.IsNumber(Dummy.RightSideAccess.LeftSideAccess.SampleAccess)))
                    {
                        //Dummy.RightSideAccess.SampleAccess = null;
                        try
                        {
                            Num = (float)System.Convert.ToDouble(Dummy.RightSideAccess.LeftSideAccess.SampleAccess);
                            //Dummy = Dummy.RightSideAccess.RightSideAccess;
                            if ((ToSimplified.ThreadAccess == null) && (Dummy.SampleAccess == "-"))
                            {
                                SimplifiedTrueOtherWiseFalse = true;
                                MinuseTruePlusFalse          = true;
                                Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                Dummy.RightSideAccess.SampleAccess = null;
                                //LOCATION81726487 :refer to page 265.

                                /*AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 * Dummy = Dummy.ThreadAccess;
                                 * if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 * {
                                 *  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *  Dummy.RightSideAccess.SampleAccess = null;
                                 * }
                                 * else
                                 *  if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 *  {
                                 *      Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *      Dummy.LeftSideAccess.SampleAccess = null;
                                 *  }
                                 */
                                Suitable = true;
                                return(Dummy);
                            }
                            else
                            if ((((ToSimplified.ThreadAccess != null))) && (ToSimplified.ThreadAccess.SampleAccess == "+") && (Dummy.SampleAccess == "-"))
                            {
                                SimplifiedTrueOtherWiseFalse = true;
                                MinuseTruePlusFalse          = true;
                                //LOCATION81987526487 :refer to page 265.

                                /*        AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 *      Dummy = Dummy.ThreadAccess;
                                 *      if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 *      {
                                 *          Dummy.RightSideAccess.LeftSideAccess.ThreadAccess = Dummy;
                                 *          Dummy.RightSideAccess = Dummy.RightSideAccess.LeftSideAccess;
                                 *      }
                                 *      else
                                 *          if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 *          {
                                 *              Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *              Dummy.LeftSideAccess.SampleAccess = null;
                                 *          }
                                 */
                                Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                Dummy.RightSideAccess.SampleAccess = null;
                                Suitable = true;
                                return(Dummy);
                            }
                            else
                            if ((((ToSimplified.ThreadAccess != null))) && (ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "+"))
                            {
                                SimplifiedTrueOtherWiseFalse = true;
                                MinuseTruePlusFalse          = false;
                                //LOCATION81987526487 :refer to page 265.

                                /*                AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 *              Dummy = Dummy.ThreadAccess;
                                 *              if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 *              {
                                 *                  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *                  Dummy.RightSideAccess.SampleAccess = null;
                                 *              }
                                 *              else
                                 *                  if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 *                  {
                                 *                      Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *                      Dummy.LeftSideAccess.SampleAccess = null;
                                 *                  }
                                 */
                                Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                Dummy.RightSideAccess.SampleAccess = null;
                                Suitable = true;
                                return(Dummy);
                            }
                            else

                            if ((((ToSimplified.ThreadAccess != null))) && (ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "-"))
                            {
                                SimplifiedTrueOtherWiseFalse = true;
                                MinuseTruePlusFalse          = true;
                                //LOCATION81987526487 :refer to page 265.

                                /*AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 * Dummy = Dummy.ThreadAccess;
                                 * if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 * {
                                 *  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *  Dummy.RightSideAccess.SampleAccess = null;
                                 * }
                                 * else
                                 *  if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 *  {
                                 *      Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 *      Dummy.LeftSideAccess.SampleAccess = null;
                                 *  }
                                 */
                                Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                Dummy.RightSideAccess.SampleAccess = null;
                                Suitable = true;
                                return(Dummy);
                            }

                            /*if (SimplifiedTrueOtherWiseFalse)
                             *  Dummy = Dummy.ThreadAccess;
                             * else
                             *  Dummy = Dummy.ThreadAccess.ThreadAccess;
                             */
                        }
                        catch (NullReferenceException t)
                        {
                            ExceptionClass.ExceptionClassMethod(t);
                            Dummy = HOLDERCATCH;
                        }
                    }
                }
                else
                {
                    return(Dummy);
                }
            }
            catch (NullReferenceException t)
            { ExceptionClass.ExceptionClassMethod(t); }
            LocalSearchMinusPlusWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(Dummy.LeftSideAccess, ToSimplified, ref Suitable, ref MinuseTruePlusFalse, ref SimplifiedTrueOtherWiseFalse, ref Num);
            LocalSearchMinusPlusWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtLeft(Dummy.RightSideAccess, ToSimplified, ref Suitable, ref MinuseTruePlusFalse, ref SimplifiedTrueOtherWiseFalse, ref Num);
            return(Dummy);
        }
        static AddToTree.Tree SuitableToSimplifierLocalThatDivIsLocatedAtUp(AddToTree.Tree Dummy, AddToTree.Tree ToSimplified, ref bool Suitable, ref bool MulTrueDivFalse, ref bool SimplifiedTrueOtherWiseFalse, ref float Num, ref bool RETURNED)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            if (RETURNED)
            {
                return(Dummy);
            }
            try
            {
                if (IS.IsMul(Dummy.SampleAccess))
                {
                    //if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, ToSimplified))
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, ToSimplified.RightSideAccess))
                    {
                        if (IS.IsNumber(Dummy.LeftSideAccess.SampleAccess))
                        {
                            Num = (float)System.Convert.ToDouble(Dummy.LeftSideAccess.SampleAccess);
                            try
                            {
                                if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "/") && (Dummy.SampleAccess == "*"))
                                {
                                    RETURNED = true;
                                    SimplifiedTrueOtherWiseFalse = true;
                                    MulTrueDivFalse = true;
                                    Dummy.SetLefTandRightCommonlySide(null, null);
                                    Dummy.SampleAccess = "1";
                                    Suitable           = true;
                                    return(Dummy);
                                }
                            }
                            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                        }

                        /*else
                         * {  //ERRORCORECTION13175402 :Considerable.
                         *  RETURNED = true;
                         *  SimplifiedTrueOtherWiseFalse = true;
                         *  MulTrueDivFalse = true;
                         *  Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                         *  Dummy.RightSideAccess.SampleAccess = "1";
                         *  Suitable = true;
                         *  Num = 1;
                         *  return Dummy;
                         * }
                         */
                    }
                    else
                    if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, ToSimplified.RightSideAccess))
                    {
                        if (IS.IsNumber(Dummy.RightSideAccess.SampleAccess))
                        {
                            Num = (float)System.Convert.ToDouble(Dummy.RightSideAccess.SampleAccess);
                            try
                            {
                                if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "/") && (Dummy.ThreadAccess.SampleAccess == "*"))
                                {
                                    RETURNED = true;
                                    SimplifiedTrueOtherWiseFalse = true;
                                    MulTrueDivFalse = true;
                                    Dummy.SetLefTandRightCommonlySide(null, null);
                                    Dummy.SampleAccess = "1";
                                    Suitable           = true;
                                    return(Dummy);
                                }
                            }
                            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                        }

                        /*else
                         * {//ERRORCORECTION13175402 :Considerable.
                         *  SimplifiedTrueOtherWiseFalse = true;
                         *  MulTrueDivFalse = true;
                         *  Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                         *  Dummy.LeftSideAccess.SampleAccess = "1";
                         *  Suitable = true;
                         *  Num = 1;
                         *  return Dummy;
                         * }*/
                    }
                }
                else
                {
                    RETURNED = true;
                    return(Dummy);
                }
            }
            catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
            LocalSearchMulDivionWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatDivIsLocatedAtUp(Dummy.LeftSideAccess, ToSimplified, ref Suitable, ref MulTrueDivFalse, ref SimplifiedTrueOtherWiseFalse, ref Num, ref RETURNED);
            LocalSearchMulDivionWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatDivIsLocatedAtUp(Dummy.RightSideAccess, ToSimplified, ref Suitable, ref MulTrueDivFalse, ref SimplifiedTrueOtherWiseFalse, ref Num, ref RETURNED);
            return(Dummy);
        }
 static AddToTree.Tree SuitableToSimplifierLocalThatDivIsLocatedAtDown(AddToTree.Tree Dummy, AddToTree.Tree ToSimplified, ref bool Suitable, ref bool MulTrueDivFalse, ref bool SimplifiedTrueOtherWiseFalse, ref float Num, ref bool RETURNED)
 {
     if (Dummy == null)
     {
         return(Dummy);
     }
     if (RETURNED)
     {
         return(Dummy);
     }
     try
     {
         if (IS.IsMul(Dummy.SampleAccess))
         {
         }
         else
         if (IS.IsDiv(Dummy.SampleAccess))
         {
             if ((EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, ToSimplified.RightSideAccess)) && (IS.IsNumber(Dummy.LeftSideAccess.SampleAccess)))
             {
                 Num = (float)System.Convert.ToDouble(Dummy.LeftSideAccess.SampleAccess);
                 try
                 {
                     if ((ToSimplified.ThreadAccess.ThreadAccess.SampleAccess == "*") && (Dummy.SampleAccess == "/"))
                     {
                         RETURNED = true;
                         SimplifiedTrueOtherWiseFalse = true;
                         MulTrueDivFalse = false;
                         Dummy.SetLefTandRightCommonlySide(null, null);
                         Dummy.SampleAccess = "1";
                     }
                 }
                 catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                 Suitable = true;
             }
             else
             if ((EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess.LeftSideAccess, ToSimplified.RightSideAccess)) && (IS.IsMul(Dummy.RightSideAccess.SampleAccess) && (Dummy.SampleAccess == "/")))
             {        //ERRORCORECTION9812737 Private state for Page 292.
                 try
                 {
                     if ((ToSimplified.ThreadAccess.SampleAccess == "*"))
                     {
                         RETURNED = true;
                         SimplifiedTrueOtherWiseFalse = true;
                         MulTrueDivFalse = false;
                         Dummy.RightSideAccess.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                         Dummy.RightSideAccess.LeftSideAccess.SampleAccess = "1";
                         Num = 1;
                     }
                 }
                 catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
             }
             else
             {
                 Suitable = false;
                 return(Dummy);
             }
         }
         else
         {
             RETURNED = true;
             return(Dummy);
         }
     }
     catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
     LocalSearchMulDivionWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatDivIsLocatedAtDown(Dummy.LeftSideAccess, ToSimplified, ref Suitable, ref MulTrueDivFalse, ref SimplifiedTrueOtherWiseFalse, ref Num, ref RETURNED);
     LocalSearchMulDivionWithNumberMulatedEqualSimplifier.SuitableToSimplifierLocalThatDivIsLocatedAtDown(Dummy.RightSideAccess, ToSimplified, ref Suitable, ref MulTrueDivFalse, ref SimplifiedTrueOtherWiseFalse, ref Num, ref RETURNED);
     return(Dummy);
 }
示例#27
0
        private AddToTree.Tree Solver()
        {
            UknownIntegralSolver UNKNOWN = this;

            this.SetProgressValue(progressBar1, 0);

            int INCREASE = 2147483647 / 10;

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);


            //ERRORCUASE1715 :ERRROR cause of ERROR317142.the copy operation is not valid.
            //ERROR3175 :Error in data structure .
            //ERRORCAUSE0981243  ;The cause ERROR3175 of  is at here.Error on copy tree.refer to page 177.
            if (Enterface.SenderAccess.AutoSenderAccess.NodeAccess.SampleAccess == null && Enterface.SenderAccess.AutoSenderAccess != null)
            {
                Enterface.SenderAccess.AutoSenderAccess.NodeAccess = new AddToTree.Tree(Enterface.SenderAccess.AutoSenderAccess.CurrentStirngAccess, false);
            }
            AddToTree.Tree Copy = Enterface.SenderAccess.AutoSenderAccess.NodeAccess.CopyNewTree(Enterface.SenderAccess.AutoSenderAccess.NodeAccess);
            //Copy = TransmisionToDeleteingMinusPluse.TrasmisionToDeleteingMinusPluseFx(Copy);
            //ERROR918243 :The error at splitation.refer to page 176.
            //Copy = TransmisionToDeleteingMinusPluse.TrasmisionToDeleteingMinusPluseFx(Copy);

            AddToTree.Tree CopyNode = null;
            CopyNode = Copy.CopyNewTree(Copy);
            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            Copy = DeleteingMinusPluseTree.DeleteingMinusPluseFx(Copy);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            Copy = Spliter.SpliterFx(Copy, ref UNKNOWN);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            Copy = Simplifier.ArrangmentForSpliter(Copy);
            //ERROR30175541  :SIMPLIFIER HAS CUASED TO SOME ERRRO.refer to page 176.
            //ERROR312317 & ERRROR317140 :Error in simplification.refer to page 182.

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            //Copy = Simplifier.SimplifierFx(Copy,ref UNKNOWN);
            //ERROR30174213  :The Simplified is invalid here.refer to page 180.
            //Copy = Derivasion.DerivasionOfFX(Copy);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            Copy = Integral.IntegralOfFX(Copy, ref UNKNOWN);

            /*int i = 0;
             * while (true)new AddToTree.Tree(null, false);
             * {
             *  //Copy = Integral.DervisionI(i, Copy);
             *  //ERROR981273987 :The error at derivation.refer to page 205.
             *   Copy = Derivasion.DerivasionOfFX(Copy);
             *  //ERROR3017181920 :refer to page 188.
             *
             *  Copy=Simplifier.SimplifierFx(Copy);
             *  i++;
             * }
             */

            //LOCATION13174253. refer to page 208.
            //ERROR3070405060 :The error is here.refer to page 220.
            //int NUM1 = Integral.NumberOfElements(Copy);
            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            int NUM1 = Integral.NumberOfElements(Copy);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            Copy = Simplifier.SimplifierFx(Copy, ref UNKNOWN);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            int NUM2 = Integral.NumberOfElements(Copy);

            this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);

            //Copy = RoundTree.RoundTreeMethod(Copy,0);

            Copy.ThreadAccess = null;
            Thread t = new Thread(new ThreadStart(Verifing));

            t.Start();
            //ERRORCORECTION6646464654643211:The Verification Return Valid result:1394/4/9
            if (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Simplifier.SimplifierFx(RoundTree.RoundTreeMethod(ChangeFunction.ChangeFunctionFx(Derivasion.DerivasionOfFX(Copy.CopyNewTree(Copy), ref UNKNOWN), ref UNKNOWN), RoundTree.MaxFractionalDesimal(CopyNode)), ref UNKNOWN), CopyNode))
            {
                t.Abort();
                SetLableValue(label17, "Verifing finished.Integral Answer Calculated is :");
                MessageBox.Show("Verify OK");
            }
            else
            {
                t.Abort();
                SetLableValue(label17, "Verifing finished.Integral Answer Calculated is :");
                MessageBox.Show("Verify Failed.");
            }

            return(Copy);

            //this.SetProgressValue(progressBar1, this.progressBar1.Value + INCREASE);
        }
示例#28
0
        static AddToTree.Tree RepeatedlyDeletedAction(AddToTree.Tree Dummy)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            DeleteingMinusPluseTree.RepeatedlyDeletedAction(Dummy.LeftSideAccess);
            DeleteingMinusPluseTree.RepeatedlyDeletedAction(Dummy.RightSideAccess);

            AddToTree.Tree Current    = Dummy;
            AddToTree.Tree CurrentTow = Dummy.LeftSideAccess;

            if (CurrentTow != null)
            {
                while (IS.IsMinuseOrPluse(Dummy.SampleAccess))
                {
                    if (CurrentTow != null)
                    {
                        while (IS.IsMinuseOrPluse(CurrentTow.SampleAccess))
                        {
                            if (((Dummy.SampleAccess == "+") && (CurrentTow.SampleAccess == "-"))
                                ||
                                ((Dummy.SampleAccess == "-") && (CurrentTow.SampleAccess == "+")))
                            {
                                if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, CurrentTow.RightSideAccess))
                                {
                                    //Dummy = Dummy.FINDTreeWithThreadConsideration(Dummy,Dummy);
                                    String A = Dummy.SampleAccess;
                                    if (Dummy != null)
                                    {
                                        if (Dummy.ThreadAccess == null)
                                        {
                                            Dummy = Dummy.LeftSideAccess;
                                            Dummy.ThreadAccess = null;
                                        }
                                        else
                                        {
                                            Dummy.ThreadAccess.LeftSideAccess = Dummy.LeftSideAccess;
                                            Dummy.LeftSideAccess.ThreadAccess = Dummy.ThreadAccess;
                                        }
                                    }
                                    if (A == "+")
                                    {
                                        while ((!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, CurrentTow.RightSideAccess)) && (Dummy.SampleAccess != "-"))
                                        {
                                            Dummy = Dummy.LeftSideAccess;
                                        }
                                    }

                                    if (A == "-")
                                    {
                                        while ((!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, CurrentTow.RightSideAccess)) && (Dummy.SampleAccess != "+"))
                                        {
                                            Dummy = Dummy.LeftSideAccess;
                                        }
                                    }
                                    //Dummy = Dummy.FINDTreeWithThreadConsideration(Dummy, CurrentTow);

                                    if (Dummy.ThreadAccess == null)
                                    {
                                        Dummy = Dummy.LeftSideAccess;
                                        Dummy.ThreadAccess = null;
                                    }
                                    else
                                    {
                                        Dummy.ThreadAccess.LeftSideAccess = Dummy.LeftSideAccess;
                                        Dummy.LeftSideAccess.ThreadAccess = Dummy.ThreadAccess;
                                    }
                                    //if (Dummy.ThreadAccess != null)
                                    //Dummy.ThreadAccess.LeftSideAccess = Dummy.LeftSideAccess;
                                    //Dummy = AddToTree.Tree.DeleteTree(Dummy, CurrentTow);
                                    CurrentTow = Dummy.LeftSideAccess;
                                }
                            }
                            CurrentTow = CurrentTow.LeftSideAccess;
                        }
                    }
                    Dummy      = Dummy.LeftSideAccess;
                    CurrentTow = Dummy.LeftSideAccess;
                }
            }
            //Dummy= Dummy;
            while ((!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy, Current)) && (Dummy.ThreadAccess != null))
            {
                Dummy = Dummy.ThreadAccess;
            }
            CurrentTow = Dummy.RightSideAccess;

            if (CurrentTow != null)
            {
                while (IS.IsMinuseOrPluse(Dummy.SampleAccess))
                {
                    if (CurrentTow != null)
                    {
                        while (IS.IsMinuseOrPluse(CurrentTow.SampleAccess))
                        {
                            if (((Dummy.SampleAccess == "+") && (CurrentTow.SampleAccess == "-"))
                                ||
                                ((Dummy.SampleAccess == "-") && (CurrentTow.SampleAccess == "+")))
                            {
                                if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, CurrentTow.LeftSideAccess))
                                {
                                    //Dummy = Dummy.FINDTreeWithThreadConsideration(Dummy, Dummy);
                                    String A = Dummy.SampleAccess;
                                    if (Dummy.ThreadAccess == null)
                                    {
                                        Dummy = Dummy.RightSideAccess;
                                        Dummy.ThreadAccess = null;
                                    }
                                    else
                                    {
                                        Dummy.ThreadAccess.RightSideAccess = Dummy.RightSideAccess;
                                        Dummy.RightSideAccess.ThreadAccess = Dummy.ThreadAccess;
                                    }

                                    if (A == "+")
                                    {
                                        while ((!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, CurrentTow.LeftSideAccess)) && (Dummy.SampleAccess != "-"))
                                        {
                                            Dummy = Dummy.RightSideAccess;
                                        }
                                    }

                                    if (A == "-")
                                    {
                                        while ((!EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, CurrentTow.RightSideAccess)) && (Dummy.SampleAccess != "+"))
                                        {
                                            Dummy = Dummy.RightSideAccess;
                                        }
                                    }

                                    if (Dummy.ThreadAccess == null)
                                    {
                                        Dummy = Dummy.RightSideAccess;
                                        Dummy.ThreadAccess = null;
                                    }
                                    else
                                    {
                                        Dummy.ThreadAccess.RightSideAccess = Dummy.RightSideAccess;
                                        Dummy.RightSideAccess.ThreadAccess = Dummy.ThreadAccess;
                                    }
                                }
                            }
                            CurrentTow = CurrentTow.RightSideAccess;
                        }
                    }
                    Dummy      = Dummy.RightSideAccess;
                    CurrentTow = Dummy.RightSideAccess;
                }
            }
            return(Dummy);
        }
示例#29
0
 static AddToTree.Tree SuitableToSimplifierLocalThatToSimplifiedLocatedAtRight(AddToTree.Tree Dummy, AddToTree.Tree ToSimplified, out bool Suitable, out bool MinuseTruePlusFalse, out bool SimplifiedTrueOtherWiseFalse)
 {
     if (Dummy == null)
     {
         Suitable                     = false;
         MinuseTruePlusFalse          = false;
         SimplifiedTrueOtherWiseFalse = false;
         return(Dummy);
     }
     try
     {
         if (IS.IsMinuseOrPluse(Dummy.SampleAccess))
         {
             if (Dummy.FINDTreeWithThreadConsideration(ToSimplified, Dummy.LeftSideAccess) == null)
             {
                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, ToSimplified))
                 {
                     try
                     {
                         if ((ToSimplified.ThreadAccess.SampleAccess == "+") && (Dummy.SampleAccess == "-"))
                         {
                             SimplifiedTrueOtherWiseFalse = true;
                             MinuseTruePlusFalse          = true;
                             //LOCATION81726487 :refer to page 265.
                             AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                             Dummy = Dummy.ThreadAccess;
                             if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                             {
                                 Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 Dummy.RightSideAccess.SampleAccess = null;
                             }
                             else
                             if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                             {
                                 Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 Dummy.LeftSideAccess.SampleAccess = null;
                             }
                         }
                         else
                         if ((ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.ThreadAccess.SampleAccess == "+"))
                         {
                             SimplifiedTrueOtherWiseFalse = true;
                             MinuseTruePlusFalse          = false;
                             //LOCATION81987526487 :refer to page 265.
                             AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                             Dummy = Dummy.ThreadAccess;
                             if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                             {
                                 Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                 Dummy.RightSideAccess.SampleAccess = null;
                             }
                             else
                             if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                             {
                                 Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                 Dummy.LeftSideAccess.SampleAccess = null;
                             }
                         }
                     }
                     catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                 }
                 else
                 if (Dummy.FINDTreeWithThreadConsideration(ToSimplified, Dummy.RightSideAccess) == null)
                 {
                     if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, ToSimplified))
                     {
                         try
                         {
                             if ((ToSimplified.ThreadAccess.SampleAccess == "+") && (Dummy.SampleAccess == "-"))
                             {
                                 SimplifiedTrueOtherWiseFalse = true;
                                 MinuseTruePlusFalse          = true;
                                 //LOCATION81726487 :refer to page 265.
                                 AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 Dummy = Dummy.ThreadAccess;
                                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 {
                                     Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                     Dummy.RightSideAccess.SampleAccess = null;
                                 }
                                 else
                                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 {
                                     Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                     Dummy.LeftSideAccess.SampleAccess = null;
                                 }
                             }
                             else
                             if ((ToSimplified.ThreadAccess.SampleAccess == "-") && (Dummy.SampleAccess == "+"))
                             {
                                 SimplifiedTrueOtherWiseFalse = true;
                                 MinuseTruePlusFalse          = false;
                                 //LOCATION81987526487 :refer to page 265.
                                 AddToTree.Tree HOLDER = Dummy.CopyNewTree(Dummy);
                                 Dummy = Dummy.ThreadAccess;
                                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.RightSideAccess, HOLDER))
                                 {
                                     Dummy.RightSideAccess.SetLefTandRightCommonlySide(null, null);
                                     Dummy.RightSideAccess.SampleAccess = null;
                                 }
                                 else
                                 if (EqualToObject.IsEqualWithThreadConsiderationCommonly(Dummy.LeftSideAccess, HOLDER))
                                 {
                                     Dummy.LeftSideAccess.SetLefTandRightCommonlySide(null, null);
                                     Dummy.LeftSideAccess.SampleAccess = null;
                                 }
                             }
                         }
                         catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
                     }
                 }
             }
             Suitable = true;
         }
         else
         {
             Suitable                     = false;
             MinuseTruePlusFalse          = false;
             SimplifiedTrueOtherWiseFalse = false;
             return(Dummy);
         }
     }
     catch (NullReferenceException t) { ExceptionClass.ExceptionClassMethod(t); }
     LocalSearchMinusPlusEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtRight(Dummy.LeftSideAccess, ToSimplified, out Suitable, out MinuseTruePlusFalse, out SimplifiedTrueOtherWiseFalse);
     LocalSearchMinusPlusEqualSimplifier.SuitableToSimplifierLocalThatToSimplifiedLocatedAtRight(Dummy.RightSideAccess, ToSimplified, out Suitable, out MinuseTruePlusFalse, out SimplifiedTrueOtherWiseFalse);
     return(Dummy);
 }
示例#30
0
        static AddToTree.Tree SplitationAllowedCalculator(AddToTree.Tree Dummy, AddToTree.Tree UNDER, ref UknownIntegralSolver UIS)
        {
            if (Dummy == null)
            {
                return(Dummy);
            }
            if ((Dummy.ThreadAccess.SampleAccess == "/") || (Dummy.ThreadAccess.SampleAccess == "*"))
            {
                AddToTreeTreeLinkList ELEMENTS = FactorActivation.GetBigestCommonFactor(UNDER.CopyNewTree(UNDER), ref UIS);

                AddToTree.Tree UNDERDummy = new AddToTree.Tree(null, false);

                while (!(ELEMENTS.ISEmpty()))
                {
                    UNDERDummy = ELEMENTS.DELETEFromTreeFirstNode();
                    if ((Dummy.SampleAccess == "+") && (IS.IsPluSinNode(UNDERDummy)) && (EqualToObject.IsEqualWithOutThreadConsiderationCommonly(Dummy, UNDERDummy)))
                    {
                        Dummy.SplitableAccess = false;
                    }
                }
            }
            else
            {
                return(Dummy);
            }
            Dummy.LeftSideAccess  = SplitationAllowed.SplitationAllowedCalculator(Dummy.LeftSideAccess, UNDER, ref UIS);
            Dummy.RightSideAccess = SplitationAllowed.SplitationAllowedCalculator(Dummy.RightSideAccess, UNDER, ref UIS);
            return(Dummy);
        }