applxperience
The OP is talking about regular audio output.
I don't think an audio output can get a speaker to work without obvious polarity reversal. The cone NEEDS to be pulled back in EVERY period (or whatever you call each sine of the wave). It won't go back by the sole suspension's (spider) tension, whose reaction is thousands of times slower than most of audible frequencies.
Maybe some other pre-amplified stage of an analog signal might be always positive, (or the "line-out" jack? ) but he output that could be used to zap anything, the usually 5Volt one, IS amplified and intended for a speaker.
Now, that makes it AC as seen by some EEs, as per what I just read, but doesn't have anything to do with the AC input of the computer, and it will be enough prevented by keeping the wave 50% off as Dr Clark describes (which you do on the waveform in the computer).
Time Ago I also researched about sound cards and at the end it was too expensive to get one that covers all the frequencies I want, and this one seemed the best option.
https://www.sparkfun.com/products/11394
But since I never got the software for the Raspberry Pi I wanted to use to control it, (or I lack of the time to get into linux programming) I rather bought an used frequency generator.
Any info you can provide me to use my frequency generator to generate healthy frequencies will be appreciated :)
Good luck.