cleanup refine_mesh code in core.cc

Avoid initializing unused vectors, cleaner SolutionTransfer code,
formatting.
Merge pull request #128 from tjhei/core_cc_formatting

cleanup refine_mesh code in core.cc