ok the foam in radiator and the low compression numbers even when cold would certainly make me think head gasket or head. Were the two cylinders reading 40 next to each other? And where were the 2 cylinders reading 90 relative to the two reading 40? You said everything looked good with gasket and head. Did this thing have a major overheat at any point that could have possibly warped the head? I realize that is a bit far fetched but those numbers are weird. Was there any anti-freeze in the cylinders when you pulled the head?
Since you didn't say this I assume you didn't do it... Did you repeat the compression test after putting everything back together and if so what are the results? After doing a normal compression test and getting results squirt some 30 weight oil into the plug holes and repeat the test just to see if the results vary. Just to see if it is rings or valves. I would assume valves based on everything that has been done but just for kicks and grins see what the variations are if any.
Since it is all back together now. Remove #1 plug. Bump the engine until your finger gets blown off. Assuming there is even enough compression for you to feel it... Look at the timing mark and see where it is realtive to zero. 5 degrees BTDC is probably what you want to start or there abouts. Then remove the distributor cap and make sure it is pointing at number one. Also verify that your wires match the following: