A FLAC3D code generator written in MATLAB