More math and the code basically goes away.