Solution (source code)

= Solution

Use $c=1$ and the mostly-plus <Minkowski metric> fixed in part <1/a>. The <electromagnetic four-potential> and its covariant form are
$$
A^\mu=(\phi,A_x,A_y,A_z),\qquad A_\mu=(-\phi,A_x,A_y,A_z).
$$
Define the <electromagnetic field tensor> by $F_{\mu\nu}=\partial_\mu A_\nu-\partial_\nu A_\mu$. Since $\mathbf E=-\nabla\phi-\partial_t\mathbf A$ and $\mathbf B=\nabla\times\mathbf A$,
$$
\boxed{F_{\mu\nu}=\begin{pmatrix}
0&-E_x&-E_y&-E_z\\
E_x&0&B_z&-B_y\\
E_y&-B_z&0&B_x\\
E_z&B_y&-B_x&0
\end{pmatrix}.}
$$
Raising both indices changes the signs of its time-space entries. The lower-index signs agree with <General Relativity by David Tong>[Section 2.4.2, equation (2.87), the explicit electromagnetic two-form]{ref}; the signature and index placement must be kept consistent.

For a passive boost to a frame moving with $v\widehat{\mathbf x}$, transform the <tensor> as
$$
F'^{\mu\nu}=\Lambda^\mu{}_{\rho}\Lambda^\nu{}_{\sigma}F^{\rho\sigma},\qquad
\Lambda=\begin{pmatrix}\gamma&-\gamma v&0&0\\-\gamma v&\gamma&0&0\\0&0&1&0\\0&0&0&1\end{pmatrix}.
$$
For example, $F'^{02}=\gamma F^{02}-\gamma vF^{12}=\gamma(E_y-vB_z)$ and $F'^{12}=\gamma(B_z-vE_y)$. Reading off all entries gives
$$
\boxed{\begin{aligned}
E'_x&=E_x,& E'_y&=\gamma(E_y-vB_z),&E'_z&=\gamma(E_z+vB_y),\\
B'_x&=B_x,& B'_y&=\gamma(B_y+vE_z),&B'_z&=\gamma(B_z-vE_y).
\end{aligned}}
$$
For an arbitrary boost <velocity> $\mathbf v$, rotational covariance gives the <Lorentz transformation of electromagnetic fields>
$$
\boxed{\begin{aligned}
\mathbf E'&=\gamma(\mathbf E+\mathbf v\times\mathbf B)
-\frac{\gamma^2}{\gamma+1}\mathbf v(\mathbf v\cdot\mathbf E),\\
\mathbf B'&=\gamma(\mathbf B-\mathbf v\times\mathbf E)
-\frac{\gamma^2}{\gamma+1}\mathbf v(\mathbf v\cdot\mathbf B).
\end{aligned}}
$$
Here all velocities are in $c=1$ units. Equivalently the parallel components are unchanged and the perpendicular components have the cross-product expressions multiplied by $\gamma$.