If your system has booted into the operating system when this happens, consider starting up into safe mode (repeatedly press F8 when the computer starts or check your computer's manual). From here, run virus scans to ensure it's not caused by a virus. If it isn't, then do a system restore and hopefully this will solve the problem.
If it doesn't solve the problem - or if your computer restarts/turns off before the operating system loads - it might be a hardware problem (in this case, possibly with your power supply unit or system fans). If so, look into getting the computer repaired as necessary.

Templateify

Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae abtore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit