Edit and compile if you like:
% Author: Izaak Neutelings (March 2021)% page 8 https://archive.org/details/StaticAndDynamicElectricity% https://tex.stackexchange.com/questions/56353/extract-x-y-coordinate-of-an-arbitrary-point-on-curve-in-tikz% https://tex.stackexchange.com/questions/412899/tikz-calculate-and-store-the-euclidian-distance-between-two-coordinates\documentclass[border=3pt,tikz]{standalone}\usepackage{physics}\usepackage{bm}\usetikzlibrary{3d}\usepackage{tikz,pgfplots}\usetikzlibrary{calc}\usetikzlibrary{intersections}\usetikzlibrary{decorations.markings}\tikzset{>=latex} % for LaTeX arrow head\pgfplotsset{compat=1.13}\usepackage{xcolor}\colorlet{Ecol}{orange!90!black}\colorlet{EcolFL}{orange!80!black}\tikzstyle{charge+}=[very thin,top color=red!50,bottom color=red!90!black,shading angle=20]\tikzstyle{charge-}=[very thin,top color=blue!50,bottom color=blue!80,shading angle=20]\tikzset{EFieldLine/.style={thick,EcolFL,decoration={markings,mark=at position #1 with {\arrow{latex}}},postaction={decorate}},EFieldLine/.default=0.5,EFielLineArrow/.style args = {#1}{EcolFL,decoration={markings,mark=at position 0.5 with {\arrow[rotate=#1]{latex}}},postaction={decorate}}}\makeatletter\newcommand{\xy}[3]{% % FIND X, Y\tikz@scan@one@point\pgfutil@firstofone#1\relax\edef#2{\the\pgf@x}%\edef#3{\the\pgf@y}%}\makeatother\newcommand{\EFielLineArrow}[2]{ % ELECTRIC FIELD LINE ARROW\pgfkeys{/pgf/fpu,/pgf/fpu/output format=fixed} % for calculation between -1*10^324 and +1*10^324\pgfmathsetmacro{\x}{#1/28.45pt}\pgfmathsetmacro{\y}{#2/28.45pt}\pgfmathsetmacro{\U}{\Q*((\y+\a)^2+(\x)^2)^(3/2)}\pgfmathsetmacro{\V}{\q*((\y-\a)^2+(\x)^2)^(3/2)}
Click to download: electric_field_image_charge_plane.tex • electric_field_image_charge_plane.pdf
Open in Overleaf: electric_field_image_charge_plane.tex