Simethicone is the active ingredient in most major anti-gas products. It works by weakening the surface tension of the gas bubbles that form in your digestive tract. This actually may make it easier to fart, but the idea is that you will be able to evacuate all the gas build-up, instead of it being stuck(causing you to feel bloated) or come out slowly, causing a prolonged period of flatulence.
Disclaimer: I am not a medical professional. Using this information is at your own risk.