A framework for modeling and analyzing cyber-physical systems using statistical model checking