I am making the assumption that you are using Windows XP. What you would want to do is open control panel. Once in control panel double click the Administrative Tools icon. When the screen switches to this find the Event Viewer icon and double click it. Look thru this list for times when your computer has mysteriously shut off and on (here I am assuming you mean Restarted by itself). There should be a line in the Event Viewer telling you which process caused the restart and give u a Event ID number. After finding the Event ID, go to this url: http://support.microsoft.com/default.aspx?scid=fh;EN-US;KBHOWTO and in the search line type in the Event ID you have identified.
If you are unfamiliar with any or all of this feel free to contact me directly via email at zanthor@sbcglobal.net and I will gladly help you decipher/troubleshoot your problem further.

Zanthor