Classical Mechanics from a Resource Constraint: Newton's Laws, Gravitation, and the Lagrangian Formulation from the Budget Equation and a Cubic-Lattice Substrate | Synapse