How to scientifically cut a cake