Hi barneycalhoun,
This gets asked every once in a while. It’s not difficult to cut foam to size using an electric knife and all you need is an electric carving knife and a straight edge for a guide and just go carefully and slowly and move the knife in one direction (not a sawing motion). The length of the blade should be longer than the thickness of the layer you are cutting. You can also see some pictures here of a home setup that was used to make some more complex cuts using an electric knife.
I would not recommend using a table saw.
Good luck!
Phoenix