Algorithmic Inference of Cellular Reaction Pathways and Protein Secondary Structure