Some alternative biofuels, produced by microbial ecosystems, are presently studied with the aim of limiting the unreasoned resource consumption of energetic resources, and greenhouse gases emissions which modify the climate. In this thesis we have considered bioreactors based on oleaginous microalgae, and on anaerobic bacterial ecosystems which degrade wastes and produce methane. The aims of these works were to better understand these processes and to improve their performances. First we have developed and studied models of microalgal cultures in photobioreactors, in which algal pigments cause strong light attenuation. For anaerobic digestion we have used an existing model. By rigorous mathematical analysis of these models, we proposed strategies for optimizing their productivity. Then the study of natural selection between several microbial species, in these two ecosystems, leads to the protection of the species which wins the competition. And finally we showed how it's possible in each ecosystem to control competition and drive natural selection, in order to advantage species which efficient characteristics, inducing better performances.