An electric dipole is an object which has positive electric charge on one end and a negative on the other end.
Electric field intensity E at a point is defined as the electric force acting on a unit charge kept at that point.
By Coulomb's law, E1=q4πϵ0r21
Here q is the positive charge of the dipole, r1 is its distance from the given point on the axis and ϵ0 is the electric permitivity of air or vacuum.
Similarly for the negative charge, E2=−q4πϵ0r22
By adding both the equations, we get,
E=q4πϵ0×1r21−r22
This is the final equation.