This work presents a general state-space representation of a multi-machine, multi-order power system model, which may be used to carry out small-signal stability assessments. Computational software coded in MATLAB has been developed in order to find and analyse the solution of an arbitrary number of synchronous generators in the network. Each generator is represented by a pre-defined model. The model choice is tailored to fit the available data for each generator. The software has provisions for conducting power flow solutions and the calculation of the initial state that the generators keep prior to the disturbance. The state-space representation and the equivalent transfer function matrix of the system are generated automatically. Eigenvalue analysis may be carried out using the standard MATLAB functionality. The paper is one of a tutorial nature and in order to check on the sanity of the results given by the new software, two text-book networks have been examined. The results were also compared with those generated using commercial industrial-grade software. (C) 2013 Elsevier Inc. All rights reserved.