This paper describes the implementation of a MATLAB program based on the Object Oriented Programming paradigm for linear‐elastic analysis of one‐dimensional element models using a conventional displacement‐based procedure. The main objective is the development of an educational tool on matrix structural analysis with a didactic and well‐documented open source code, which allows any user to implement new procedures with relative simplicity. The LESM (Linear Elements Structure Model) program can handle different types of analysis models, such as 2D/3D frames and trusses, and grillages. In addition, both Euler‐Bernoulli and Timoshenko theories for bending behavior of beam elements are considered. The OOP class architecture was devised for generically handling these different types of analyses models and element types. The MATLAB script codes of all classes and methods of LESM, including its documentation, are available in its site (www.tecgraf.puc-rio.br/lesm).