The Relation Between Structure and Function in Brain Networks