//****************************************************************************** //** SCATMECH: Polarized Light Scattering C++ Class Library //** //** File: allrough.cpp //** //** Thomas A. Germer //** Sensor Science Division, National Institute of Standards and Technology //** 100 Bureau Dr. Stop 8443; Gaithersburg, MD 20899-8443 //** Phone: (301) 975-2876 //** Email: thomas.germer@nist.gov //** //****************************************************************************** #include "allrough.h" using namespace std; namespace SCATMECH { void Correlated_Roughness_Stack_BRDF_Model:: setup() { Roughness_BRDF_Model::setup(); model.set_lambda(lambda); model.set_type(type); model.set_substrate(substrate); model.set_psd(psd); model.set_stack(stack); } JonesMatrix Correlated_Roughness_Stack_BRDF_Model:: jones() { SETUP(); JonesMatrix J=JonesZero(); for (int layer=0; layer<=stack->get_n(); ++layer) { model.set_this_layer(layer); J = J + model.Jones(thetai,thetas,phis,rotation); } return J; } void Uncorrelated_Roughness_Stack_BRDF_Model:: setup() { Roughness_BRDF_Model::setup(); model.set_lambda(lambda); model.set_type(type); model.set_substrate(substrate); model.set_psd(psd); model.set_stack(stack); } MuellerMatrix Uncorrelated_Roughness_Stack_BRDF_Model:: mueller() { SETUP(); MuellerMatrix M=MuellerZero(); for (int layer=0; layer<=stack->get_n(); ++layer) { model.set_this_layer(layer); M = M + model.Mueller(thetai,thetas,phis,rotation); } return M; } void Growth_Roughness_Stack_BRDF_Model:: setup() { Roughness_BRDF_Model::setup(); model.set_lambda(lambda); model.set_type(type); model.set_substrate(substrate); model.set_psd(psd); model.set_stack(stack); } // // Growth_Roughness_Stack_BRDF_Model uses the film growth model described in // E. Spiller, D. Stearns, M. Krumrey, J. Appl. Phys. 74(1), 107-118 (1993), // with some modifications: // (1) the intrinsic infinite-thickness roughness of all // coating interfaces are the same. This is treated as such because the // software would be too complicated, as there is no high index, low index assumptions // in dielectric_stack. // (2) the replication factor has an extra parameter, the spatial frequency exponent, which // described in the paper is 2. // // The substrate PSD function is given by the Roughness_Stack_BRDF_Model::psd, while // the intrinsic infinite-thickness roughness is given by intrinsic. // MuellerMatrix Growth_Roughness_Stack_BRDF_Model:: mueller() { SETUP(); int N = stack->get_n(); double fx,fy; Bragg_Frequency(fx,fy); double qpow = pow(4*sqr(pi)*(sqr(fx)+sqr(fy)),exponent/2.); double nu = pow(relaxation,exponent-1.); double fourpisqr = 4.*sqr(pi); double PSDsub = psd->psd(fx,fy); double FTsub = sqrt(PSDsub); double PSDint0 = intrinsic->psd(fx,fy); double FTint0 = sqrt(PSDint0); vector a(N); vector PSDint(N); for (int i=0; iget_t()[i]; // The replication factor between the layers... a[i] = exp(-argument); // The intrinsic roughness of the layer... PSDint[i] = PSDint0*(1.-sqr(a[i])); } vector J(N+1); for (int i=0; i<=N; ++i) { model.set_this_layer(i); // The Jones matrix for scattering by the layer, per unit surface roughness... J[i] = model.Jones(thetai,thetas,phis,rotation)/FTsub; } // Cross power spectral density matrix... vector > covar(N+1,vector(N+1)); // First the diagonal elements (the power spectra)... for (int i=0; i<=N; ++i) { covar[i][i] = 0.; for (int j=0; j<=i; ++j) { double aprod=1; for (int k=j; k