Divides Single Lens solution into more generic functions.