Erased the hard drive and reinstalled, but iMac is still shutting itself down
My iMac was repeatedly shutting down and trying to restart itself.
I opened Disk Utility using an install disk to repair the hard drive. That worked for a little while, and then it started shutting itself off again. Every time I repaired the disk, it didn't stay repaired for very long.
I finally, after making sure everything was backed up, I erased my HD and reinstalled OS X Snow Leopard. I checked the disk with Disk Utility and it said it was ok. It worked fine for several hours, but then it shut itself down again. (I don't any files on the internal hard drive except applications; I keep all my files, on my two externals.)
I'm at a loss. Is there something else I can do or is my computer just dying?
iMac, Mac OS X (10.6.3)