ADD: single polygon to raster
ADD: optimization framework
ADD: complete optimization module
FIX: fmin seems better