First draft of Jacobi's method