Write boundary types into the output file so a current state can be reconstructed.
Fixed syntax error