Metabolic pathway analysis based on the concept of elementary flux mode is a valuable tool for reconstruction of bacterial metabolisms and in predicting optimal conversion yields in biotechnology. However, pathway analysis of large and highly entangled metabolic networks meets the problem of combinatorial explosion of possible routes across the networks. Here we propose a method for coping with this problem by suitably classifying metabolites as external or internal. External metabolites are considered to have buffered concentrations while internal metabolites have to fulfil a balance condition at steady state. For many substances such as nutrients and excreted products, there are biochemical reasons to classify them as external. In addition, other substances (especially at central branching points) can operationally be considered external in order to avoid combinatorial explosion. We suggest to find such a classification of metabolites that minimizes the number of elementary flux modes (pathways). This is motivated by the objectives of finding such a description of the system that reduces as much as possible the amount of necessary data and of removing the ambiguity and arbitrariness in the classification of metabolites in an automated, systematic way. For networks of moderate size, the solution to this combinatorial minimization problem can be found by exhaustive search. To tackle also larger systems, a stochastic optimization program based on the Metropolis algorithm was developed. Both methods are applied, for illustration, to several reaction schemes including a larger network representing glutathione metabolism.