Nerves. The pericardium is inflamed when there is pericarditis. There are nerves that connect to the pericardium. So just as you might get pain in an inflamed joint, the inflammation of the pericaridum causes pain. Medications that help such joint pain are also useful for the pain of pericarditis.