I ran a couple tests yesterday including Prime95 stress tests and MemTest; however all passed and I still have no idea why the iMac froze/screeched. I ended up going back to the Apple store again, and they gave me store credit. It looks like I'll be heading towards the MBP line now, I guess I wasn't meant to have an iMac. Oh well- thanks for everything guys, I appreciate it.
I think this is also due to bad RAM...
I've had this problem with my wife's 2011 21" iMac in which I upgraded the HD to an SSD and added (2) 4GB sticks about 8 months ago. My kids watch videos on it all the time and then it randomly makes that extremely loud repeating firecracker noise which freaks them out and makes then run away in different directions! (have to admit seeing that is funny as hell).
The system reboots after 15 seconds of that horrible sound and all is good again until the next time. Tt usually happens 3 or more times a week. But, more often then the horrible sound, the system will suddenly just reboot itself maybe once a day.
Anyways I've tried troubleshooting this issue for a while; reinstall the OS, zapped PRAM, did a AHT (all checks passed) and even tried booting off an external HD for a while and it still happens.
Just yesterday I removed the (2) 4GB RAM sticks I purchased from DMS, datamem.com for this model and so far, it hasn't occurred.
Someone I know in a business had the same exact issue with their iMacs that had 3rd party RAM upgrades.
Well, I'll declare victory in 1-2 weeks if I don't hear that noise or don't get the silent random reboots.