From Mr.Webster:
"If the word begins with a vowel sound, use an, such as in "an honorable man," and with spoken acronyms like "an FBI agent." Words like historic, with a pronounced "H," can use either a or an. In the eternal, and generally fruitless, quest to find some way to make English make sense, many people look for simple rules to apply to our language.