If the edges of a graph are labelled in a certain special way, it is possible to enumerate all the directed paths of the graph by inverting a matrix with elements from a field.