Abstract
Scilab/Xcos is a graphical modeling and simulation environment for hybrid dynamic systems. It provides a graphical editor which allows representing models with block diagrams. While each block represents a computational function, links specify the data and event flow. However, as the number of the blocks and the links increases, the Xcos schema can quickly become messy and difficult to read. In this paper, we present an approach for automatically updating the layout of an Xcos schema by manipulating the links and the split blocks, so that the diagrams can be kept well-presented and readable. In this approach, we update the link styles with an optimal route and then, rearrange the positions of blocks. The proposed approach is exemplified with sample Xcos models. In addition to providing the automatic layout capability to the Scilab/Xcos user, an application programming interface is also specified for the Scilab/Xcos developer who want to further enhance the provided feature set.