Porting the petsc calls to C++

As requested I've taken a look at the petsc call.

This patch set actually does two things (bad, I know). One patch (08cc2f3) basically removes the C relics from the call_petsc.c file and uses C++ features to do  the same. A nice consequence is that most should be easier to read, and it's way shorter.

The second and third, 239973e and 7818675 respectively, cleans up some minor errors and should be pretty self explanatory.

The final patch, f8bceea, is an optional take on the petsc interface from C++. The comments should really explain the issue, but the short version is that the petsc interface is awful and I've tried to fix some parts of it. It's in its own patch so it will be easier to merge/not merge/revert. Long term some better solution would be nice.