This ignores the fact that Iran was a key U.S. ally under the Shah and when the Islamic Revolution happened the United States immediately did an about-face and has been extremely hostile to Iran ever since. We supported the Axis of Evil Dictator Saddam Hussein (oops, that was more than 20 years ago, I'm not supposed to mention it because it never ever happened) against Iran in the Iran-Iraq war because we wanted Khomeini out.
Come on, has everybody already forgotten that we invaded Iraq because of "bulletproof evidence" that Saddam had an advanced WMD program? And then that justification for invading sort of just... fell off to the wayside when we occupied the country and picked apart the guts of his regime, and it turned out there weren't any WMD's, and the intelligence turned out to be fake?
The United States wants regime change, they're just putting pressure on Iran. The Islamic Republic came into power on a wave of anti-Western (well, more like anti-Western-imperialism) sentiment and has distinguished itself to its people by not bowing to Western pressure, even under sanction. It is entirely plausible that they're committed to pursuing nuclear energy in the face of American pressure simply because they don't want to be seen to buckle to American demands.