modify codes according to warnings given by MATLAB editor
put END in writepdb
support for JCP format