I need to test equipment behaviour in the event that Windows hard hangs/freezes (e.g. frozen screen, no LEDs blinking, no reaction to inputs, including Ctrl+Alt+Del, etc.). In order to have enough experiments in a reasonably short time I need to initiate these hangs either programmatically or otherwise.
I am interested in Windows 10 in particular but any working way for other versions is appreciated.
Every search I've done on this topic not surprisingly brings me to discussions on how to eliminate these situations, not provoke them. So the question may seem odd enough.
Feedback: I've tried many of the recipes offered in answers and comments. First of all, I was not interested in crashes that bring BSoD (that's why I described a freeze, not a crash).
I must confess that Windows 10 64-bit showed good resistance to many of the ways. It copes with almost any CPU-load method (including fork-bomb, loops, etc.) quite well. Methods that raise immediate errors (most of NotMyFault hang methods) are handled by the OS with reboot or shutdown (which is not what I pursued). The best results were achieved by memory leak methods of NotMyFault — real freeze with no chance of reboot.
Finally, I was impressed by amount of documentation by Microsoft that talks about making Windows freeze. Looks like they know this part much better than the opposite (fighting freezes) ;-)