Get Processor Utilization Percentage
Get-WmiObject win32_processor -ComputerName $computer | Measure-Object -property LoadPercentage -Average | 
    Select @{Label = "Computer"; Expression = {$computer}},@{Label = "CpuUsage"; Expression = {$_.Average}}
Details
Returns the total percentage of process ultization on your local or remote system.

Example
PS C:\> $computer = 'localhost'
>> Get-WmiObject win32_processor -ComputerName $computer | Measure-Object -property LoadPercentage -Average |
>>     Select @{Label = "Computer"; Expression = {$computer}},@{Label = "CpuUsage"; Expression = {$_.Average}}


Computer  CpuUsage
--------  --------
localhost       15

  |  |  
Get Memory Utilization Percentage
Get-WmiObject Win32_OperatingSystem -ComputerName $computer | Select @{Label = "Computer"; Expression = {$computer}},
    @{Label = "MemoryUsage"; Expression = {100 - [math]::Round(($_.FreePhysicalMemory/$_.TotalVisibleMemorySize)*100,0)}}
Details
Returns the total percentage of memory ultization on your local or remote system.

Example
PS C:\> $computer = 'localhost'
>> Get-WmiObject Win32_OperatingSystem -ComputerName $computer | Select @{Label = "Computer"; Expression = {$computer}},
>>     @{Label = "MemoryUsage"; Expression = {100 - [math]::Round(($_.FreePhysicalMemory/$_.TotalVisibleMemorySize)*100,0)}}


Computer  MemoryUsage
--------  -----------
localhost          69

  |  |