Added modules for adaptive sampling of 1D and 2D functions.