Find Intervals of Concavity for Functions