detect upper bounds