#perfectMatchings is self-reducible
To count all perfect matchings containing an edge $e = (x,y)$, simply remove both endpoints $x,y$. To count all perfect matching not containing the edge $e$, simply remove the edge.