Changed the gradient function to match the symmetric portion of the bilinear code.
Made it so that the IsQuad variable is set to true for cross quadratic terms.
Removed some old commented out code.
Removed a couple of commented out lines.
Fixed the cross-quadratic bugs and errors. Now matches John's calculations.