Total core in my enviroment

Is there an easy way to get the total # or course used and total number of cores available in my entire environment?