Solve for f 6f+9g=3g+f