Model equations and solve for variables