Circuit theory approach to stability and passivity analysis of nonlinear dynamical systems