Use below one line statement to get the App pool status on specific server in a farm. $name variable contains the fully qualified domain name of the server. Below example get the details of IIS application pool named "SharePoint Web Services Root".
$name = "<insert Server FQDN>";
$aps=Invoke-Command -ComputerName $name {Import-Module WebAdministration; Get-ChildItem IIS:\AppPools | where{$_.Name -eq "SharePoint Web Services Root"}}
$name = "<insert Server FQDN>";
$aps=Invoke-Command -ComputerName $name {Import-Module WebAdministration; Get-ChildItem IIS:\AppPools | where{$_.Name -eq "SharePoint Web Services Root"}}