A man who thrust his elbow into a doctor attempting to treat him in a Belfast hospital has been jailed for four months.