Licking the air can be the result of a couple of things.
I think it's very possible that your dog could be experiencing discomfort in her stomach, due to something minor like an upset stomach or due to something more serious like bloat.
Neurological damage or abnormalitites can also cause a dog to lick the air. It can result from an injury, or a birth defect, but unfortunately, neurological deficits are really something that have to be diagnosed at a vet - there's little you can do at home to diagnose or treat a problem such as that.
But, as I mentioned above, licking and biting at the air, the carpet, and the dog's own body is often a sign of stomach discomfort and this can be helped at home. It's related to the same instinct that makes dogs eat grass when their stomach feels sour. Unfortunately, some dogs will make their situation worse with all of this licking, because they'll end up swallowing air as they do this. Vomiting is often seen after the onset of these behaviors. Theoretically, if your dog has gastritis or another chronic condition that causes stomach upset, this behavior may be seen regularly, as you describe.
You're going to want to examine your dog before you do anything. Look at your dog's gums - if they're pale or white, get to the vet asap. Her temperature should be between 101 and 102 degrees. Other signs to look for are related to distress - it can include excessive drooling, weakness, pacing, refusing to sit in certain positions, shallow breaths. (See a list of even more symptoms in the bloat article link below). If she does not appear to be in distress - just uncomfortable, you can proceed with helping her at home. If she does appear distressed, get her to the vet asap.
To help your dog with stomach discomfort at home, you can begin by applying a warm compress, or a heating pad on low, to her stomach. This will relax the muscles of the stomach and your dog. After 20-30 minutes of the warm compress, you can rub your dog's stomach - I know it sounds silly, but it really works wonders. (If your dog is too antsy to apply a warm compress, you can begin with this step instead) Rub in a circular motion from the area just below her rib cage to the area just above her genitals. You can do this for 15 minutes - or a bit longer if she's calming, but not entirely calmed.
You can also try giving a little bit of pepto bismol. With the liquid, you'll give 1 teaspoon (10 ml total) for each ten pounds of body weight twice daily. In the beginning, you can half that dose and give it four times instead. For more in treating your dog with pepto, visit: http://www.petplace.com/drug-library/bismuth-subsalicylate-pepto-bismol-kaopectate/page1.aspx
If treating her for a stomach upset seems to help, you may want to try keeping her on a bland food for a couple of days. Cottage cheese, plain white rice with plain boiled hamburger meat or chicken are good foods for an upset stomach. This should be fed in several small meals throughout the day, rather than in one or two large meals.
Here's an article on bloat and what to look for - even if it's not the situation with your dog, it's good information to have committed to memory.
Also, one additional possibility to consider: Is it possible your dog has been exposed to a toxin? Or to a substance that she's not ever been exposed to before (such as a new air freshener or household chemical)? An allergic reaction could cause nausea (which would cause licking of the air and carpet) and licking of the dog's own body. Other symptoms that could suggest an allergy include facial and body swelling, hives, itchy skin, biting at the dog's own feet, and difficulty breathing.
If you suspect a toxin, neurological damage, or if treating him for an upset stomach doesn't help, you may want to bring her to the vet for an exam.
I hope our dog is feeling better soon! Let me know if there's anything else I can do to help.
****Please ACCEPT if my answer was helpful!****