Before you bath your cat, give him/her a very thoughor grooming, allll over. Specifically if it's a long hair, try to use a shedding shampoo, so a lot of loose hairs will fall out in the bath, instead of mixing in once it dries to form knots and matts.
After bathing, when they are about half dry, groom them again very well.
With a long haired cat, I think it's best to groom them every day. But I personally wouldn't go any less than 1-3 times a week, or your just asking for matts.
Work from the neck down, and you can do the face if you want. Use a brush/comb that they like, some brushes, specifically slicker brushes can hurt their skin and cause them to get well, really grumpy!
Groom them when they seem in a good mood, don't over do it, or start grooming them when they are sleepy, or sleeping.
For people who have a hard time grooming cats, and don't want to shave them. For me, if you can't persuade them into doing it after time, then just do it very QUICKLY with a light comb, it's better than nothing. If you can even just get a couple swipes down their body every day, it will be better than nothing.
I have other approches, but I don't know your cats attitudes so I can't recommend them to everyone.