Well, I may have solved the problem. I got the computer back from the shop yesterday afternoon, with a new HD and a clean install of Windows 10. The HD was nearly 6 years old and their testing machine showed so many bad sectors that they stopped the test.
So I thought new HD and clean install of Windows, that should fix it. But I still had the problem. I thought, OK, it has to be the motherboard, the CPUs, or the RAM. I had run BurninTest a few times and it showed no problem. I ran one complete pass of MemTest86 (3+ hours) and it didn't show a problem. But today I left it for a little over an hour, and when I came back it was doing 5 beeps/flashes. I looked up the beep error code and it was a memory error. Even though BurninTest and Memtest86 didn't find a problem, I took out all RAM and put in 8 sticks of different RAM (leaving 4 slots empty for now).
Now, 2 hours and 42 minutes later, the problem has not reappeared, and it has never gone this long w/o it. So if it goes overnight without the problem, I think it is fixed.