|Picture in public domain.|
Cats are more territorial while dogs are more concerned about the person and where the person is than specific territory. The territorial instincts of a cat results in more stress when space is invaded with the consequential barrier to learning. I can vouch for this personally. Not in relation to cat and dog but cat to cat. My cat is very defensive and quiet. She gives way to bigger strays that come in (Timmy a large boy cat) but attacks a smaller cat than invades her territory (Pippa - a small female) - see Three Stray Cats.
She is distinctly typically territorial and can suffer from stress. The invasion of her space by time share cats coming in the cat flap concerns me and I am working on it. That said, when cats are in place in their territory (our home) and young enough (aged 6 months or less) and a dog of less than one year of age is introduced to the cat they can learn to get on fine. In fact they can learn the body language of the other animal even though it is not like theirs.
For example, when a cat wags her tail it can be a sign of agitation but for a dog it can indicate a friendly attitude. This difference appears to have been noted in the cats and dogs that were part of the research project that was carried out by authors Neta-Li Feuerstein and Joseph Terkel. Also, in well socialized cats and dogs, when they great each other they use the Eskimo kiss, smelling the other at the nose rather than the rear end. My cat does this to me as we are beautifully socialized!
In a household where the people would like to integrate cat and dog companion animals it would seem that a degree of advanced planning is the preferred route to take into account the fact that cats are less flexible than dogs and that their period of most productive learning is shorter at 6 months rather than one year for dogs.