added small changes to getMaximumWellDepth