How is Kirchhoff's law of current and voltage derived?

How is Kirchhoff's law of current and voltage derived?


The essence of Kirchhoff's law is the law of charge conservation in the case of steady current
One of the important equations is the continuity equation of current
That is, SJ * DS = - DQ / dt (the first s is the integral sign of the closed surface, j is the current density vector, * is the point multiplication of the vector, DS is the area element of the integrated closed surface, and DQ / DT is the change rate of the electric quantity in the closed surface with time)
It means that the current line of the current field has a head and a tail. Where the current line is emitted, the electric quantity of the positive charge decreases with time, and where the current lines converge, the electric quantity of the positive charge increases with time
For a steady current, if the current density does not change with time, there must be SJ * DS = - DQ / dt = 0, which is the closure of the steady current and the basis of Kirchhoff's law