Updated some of the JavaDoc.
Added two TODO comments.
Added brackets to the math formulas for clarity.