cleaned up, outsource cvx computation to util file