Both alternating current and direct current are measured in amperes. But how is the ampere defined for an alternating current?
An ac current changes direction with the source frequency and the attractive force would average to zero. Thus, the ac ampere must be defined in terms of some property that is independent of the direction of current. Joule’s heating effect is such property and hence it is used to define rms value of ac.