## 2 Theory: Rank-1 Polarimetric Contrast Enhancement for Ship Detection
### Quad-Polarimetric Case  
The data contained at each pixel of a quad-pol image can be expressed using a target vector \(\mathbf{k}\) as follows [32]:  
\[\mathbf{k}=\left[S_{HH},\sqrt{2}S_{VH},S_{VV}\right]^{T} \tag{1}\]  
where the superscript \(T\) denotes transposition. The values \(S_{PQ}\) represent the single-look complex (SLC) data at the polarimetric channel measured by transmitting polarization \(P\) and receiving polarization \(Q\). In this expression, reciprocity is assumed (i.e., \(S_{VH}=S_{HV}\)), and the \(\sqrt{2}\) factor is used to preserve the total received power. From the SLC data, the polarimetric covariance matrix is estimated, resulting in the following:  
\[\mathbf{C}=\langle\mathbf{k}\cdot\mathbf{k}^{\ast T}\rangle= \begin{bmatrix} \langle S_{HH}S_{HH}^{\ast}\rangle&\sqrt{2}\langle S_{HH}S_{VH}^{\ast}\rangle &\langle S_{HH}S_{VV}^{\ast}\rangle\\ \sqrt{2}\langle S_{VH}S_{HH}^{\ast}\rangle&2\langle S_{VH}S_{VH}^{\ast}\rangle &\sqrt{2}\langle S_{VH}S_{VV}^{\ast}\rangle\\ \langle S_{VV}S_{HH}^{\ast}\rangle&\sqrt{2}\langle S_{VV}S_{VH}^{\ast}\rangle &\langle S_{VV}S_{VV}^{\ast}\rangle\end{bmatrix} , \tag{2}\]  
where \({}^{\ast}\) denotes complex conjugate, and \(\langle\cdot\rangle\) is the estimation operator, which is implemented using a speckle filter (e.g., a spatial low-pass filter). Once the covariance matrix \(\mathbf{C}\) is estimated for each pixel, the algorithm starts by applying an eigenvector expansion of the covariance matrix, which always has real, non-negative eigenvalues, and orthogonal eigenvectors as shown in the following equation:  
\[\mathbf{C}=\sum_{i=1}^{3}\lambda_{i}\mathbf{e}_{i}\mathbf{e}_{i}^{\ast T}, \qquad\text{with}\qquad\lambda_{1}\geq\lambda_{2}\geq\lambda_{3}. \tag{3}\]  
where \(\lambda_{i}\) are the eigenvalues, and \(\mathbf{e}_{i}\) denote the eigenvectors. The first step of the algorithm consists in computing a new complete image which corresponds to the rank-1 covariance matrix formed by using only the largest eigenvalue/eigenvector obtained in (3), i.e.,  
\[\mathbf{C}_{1}=\lambda_{1}\mathbf{e}_{1}\mathbf{e}_{1}^{\ast T}=\mathbf{k}_{ 1}\mathbf{k}_{1}^{\ast T} \tag{4}\]  
The second step of the method consists in selecting a reference pixel or patch (group of pixels) located in the area that we want to remove or mitigate, e.g., on the sea surface for a ship detection application. The orthogonality of the eigenvectors implies that the first eigenvector of the reference pixel, \(\mathbf{e}_{1}^{ref}\), defines an orthogonal space, which is formed by the second and third eigenvectors, i.e., \(\mathbf{e}_{2}^{ref}\) and \(\mathbf{e}_{2}^{ref}\). In the quad-pol case, the geometrical interpretation is simple: the orthogonal space is a two-dimensional plane formed by the second and third eigenvectors. Within that plane, one can measure the radar response provided by any linear unitary combination of the two eigenvectors--i.e.,  
\[\mathbf{n}(\theta,\delta)=\cos\theta\mathbf{e}_{2}^{ref}+\sin\theta e^{i \delta}\mathbf{e}_{3}^{ref} \tag{5}\]  
where \(\theta\) and \(\delta\) are two angles used to cover any possible combination, and \(j=\sqrt{-1}\). In fact, it is possible to find the maximum received echo (backscattered power) at each pixel of the rest of the image (outside the reference patch) by properly selecting these two angles. The optimum values of these two angles are as follows [31]:  
\[\delta_{\text{opt}}= \arg\left(z_{3}z_{2}^{*}\right) \tag{6}\] \[\tan 2\theta_{\text{opt}}= \frac{2\text{Re}\left(z_{2}z_{3}^{*}e^{-j\delta}\right)}{\left( \left|z_{2}\right|^{2}-\left|z_{3}\right|^{2}\right)}=\frac{2\left|z_{2} \right|\left|z_{3}\right|}{\left(\left|z_{2}\right|^{2}-\left|z_{3}\right|^{2 }\right)} \tag{7}\]  
where \(z_{2}\) and \(z_{3}\) are the projections of the second and third eigenvectors of the reference patch onto the rank-1 value of the pixel (see Equation (4)).