Analytical inversion of general tridiagonal matrices | Synapse