Start updating code.
Fix Jacobian adjustment and rename vars for clarity.