Dev

Some small changes plus some min/max error.