 var i;
    for(i = 0; i <= 100; i++) // max iterations = 100
    {
        if(length_of(prev_x - cur_x, prev_y - cur_y) < end_step_length)
            break;  // done
        prev_x = cur_x;
        prev_y = cur_y;
        if(i % 2 == 0){
            cur_x = projected_x(prev_x, prev_y, solver_1_eq_1[0], solver_1_eq_1[1], solver_1_eq_1[2]);
            cur_y = projected_y(prev_x, prev_y, solver_1_eq_1[0], solver_1_eq_1[1], solver_1_eq_1[2]);
        }else{
            cur_x = projected_x(prev_x, prev_y, sol