# `CpRVI` (Compact-pol Radar Vegetation Index)

This functionality computes the compact-pol radar vegetation index for compact polarimetric SAR data. The required input and the computed output are as follows:

    input : input_C2_folder, window_size
    output: CpRVI.bin

The formulation of the CpRVI is as follows:

\[\begin{split}\text{CpRVI}=\left(1-\dfrac{3}{2}\text{GD}_{\text{ID}}\right)\Big(\frac{p}{q}\Big)^{2(\frac{3}{2}\text{GD}_{\text{ID}})}\\ p=\text{min\{SC,OC\}},q=\text{max\{SC,OC\}}\\ \text{SC}=\frac{S_0-S_3}{2};\qquad{}\text{OC}=\frac{S_0+S_3}{2};\\ S_0=\text{C11+C22};\qquad{}S_1=\text{C11-C22};\\ S_2=\text{C12+C21};\qquad{}S_3=\pm\text{j(C12-C21)}\\\end{split}\]

where, \(\text{GD}_\text{ID}\) is the geodesic distance between Kennaugh matrices (\(\mathbf{K}\)) of the observed and the ideal depolarizer, \(p, q\) are minimum and maximum values of \(\text{SC}\) and \(\text{OC}\) which are functions of stocks parameters (\(S_0\), \(S_1\), \(S_2\), and \(S_3\)). A detailed explanation of CpRVI is available in [[6]](#6).