Optimization of enhanced oil recovery operations in unconventional reservoirs