Save as is before too much restructuring
Tidied up and added general plane object + intersection function.