CPU core calculation

How is the metric 'CPU Utilization by Cores' calculated in Site24x7 Linux Monitoring?

The metric  'CPU Utilization by Cores' can be viewed under the CPU tab ( Server > Server Monitor > Servers > click on a monitor > CPU ) for a Linux server monitor in Site24x7. 


Command Executed:

Sample Output:

Explanation:
corename -- UserModeTime -- NiceTime -- SystemModeTime -- IdleTime -- IOWaitTime -- InterruptServicingTime -- SoftirqsServicingTime -- OtherOsVirtualEnvTime -- GuestOsVirtualCpuRunTime -- NicedGuestRunTime

Metric Calculation Formula:
For each CPU core, the below formula will be executed to get the CPU core utilization:

coreCpuTotalTime = UserModeTime+NiceTime+SystemModeTime+IdleTime-IOWaitTime+InterruptServicingTime+SoftirqsServicingTime-OtherOsVirtualEnvTime+GuestOsVirtualCpuRunTime+NicedGuestRunTime

coreCpuUsage = UserModeTime+SystemModeTime

coreUtilizationPercent = round((((coreCpuUsage)/coreCpuTotalTime)*100),2)

Know how the total CPU usage calculated for a Linux server monitor.