|I am sorry I can't give you a simple easy and cheap solution. I suspect it is mechanically defective. |
One does what you are doing. Try to find repeatable diagnostic tests to help narrow down the problem. In you case, even if you did figure out what is wrong you may not be able to fix it.
One thing you can look at is maybe how the electric connection is. Could it be the loose part? Could the jack in the computer be broken or defective?
I guess it could be that the problem is actually the screen going off and it looks like the power shuts down.
In almost all cases you are kind of stuck thinking about some used hand me down or a new one. I would not suggest that you buy a used computer. It would be simply more trouble.
It might be that for what you need, a $300 or so laptop may suffice.
1/3 of highway deaths are caused by drunks. The rest are by people who can't drive any better than a drunk.