A Distributed Optimal Control Model Applied to COVID-19 Pandemic