Optimizing smart manufacturing systems using digital twin