_{How is impedance calculated in a circuit?}

|Z| = √(R^2 + (Xl - Xc)^2)

Where R is the resistance, Xl is the inductive reactance, and Xc is the capacitive reactance. The phase angle of the impedance can be determined using the tangent of the phase shift between voltage and current.