Escape % symbols
Cleanup file close
Create write_sp.m
write_sp.m is functional
Create lin2dec.m
lin2dec.m is functional