added optim to check unboundness, Edward Cai