internal double FindMaximum(Key from, Key to) { if (Predicates.LessOrEqual(from, From) && Predicates.LessOrEqual(To, to)) { return(Maximum); } if (Predicates.Less(to, From) || Predicates.More(from, To)) { return(double.NegativeInfinity); } if ((null != FirstChild) && (null != SecondChild)) { double first = FirstChild.FindMaximum(from, to); double second = SecondChild.FindMaximum(from, to); double result = Math.Max(first, second); return(result); } if (Predicates.LessOrEqual(from, To)) { return(Close); } if (Predicates.MoreOrEqual(to, From)) { return(Open); } return(double.NegativeInfinity); }