This would have to be based on the context of the sentence. For instance: "The dog was kept in a cage with no food or water." would be just as offensive as saying "The dog was kept in an enclosure with no food or water." Or if you stated that "The tiger looked happy and content in his enclosure, cage, or pen.' You would feel a different feeling there. The word "cage" is not inherently negative
A cage is fully enclosed. Top, bottom, four walls, usually with bars.
A pen has walls, but not a ceiling. Generally you think of non-dangerous animals in a pen, like sheep.
An enclosure is less defined. Many zoos have large enclosures: a pit on the side with the animal, a wall or fence to keep out the visitors, and could comprise several acreas.
Yes, that is pretty much how I would describe them too. The fact our definitions match is reason enough for me to consult no more web dictionaries. Thanks
A cage would always have 6 enclosed sides. A pen would have an open top. If a cage has bars, the bars would be vertical. In a pen the bars are usually horizontal.
In a farm setting you would have pens rather than cages, except for small animals like rabbits and chickens. For dangerous animals and animals that can easily climb you would have cages, since in a pen the top is open.