Several linear programming (LP) software, such as HIS GRTMPS, Aspen PIMS, and Bonner & Moore RPMS, are available and extensively employed in the refineries and petrochemical plants so far. These packages change the world of refinery planning by introducing a full featured LP modeling system that run on a personal computer and using spreadsheets as the user interface. In previous paper, we have studied the LP principles in terms of the relevant matrix development of refining model, blending model and transportation model as well as the single-refinery LP model. The aim of this study is to further investigate the multi-refineries and multi-terminals LP model. In this paper, we have also discussed the optimal crude selection and the optimal transportation mode. In addition, because of the popularity of –29 –GRTMPS, this package will be used in this study.