update side intersection math and pull out into a function