3D milling demo: extracted tool profile functions to separate file