# MATLAB procedures for retrieving particle density, retrieving dry complex refractive index, retrieving hygroscopic growth factor, and fitting multimodal size distributions from measured data

The following files are included in this archive: (1) cal_rho.m, (2) MieKernal.m, (3) S_e.m, (4) m_g_ret.m, and (5) fit_SD.m. Each procedure includes a description of the purpose of the procedure, a description of the required inputs and outputs of each procedure, and the required MATLAB toolboxes. NOTE: Procedures 1, 2, 3, and 4 require the Mie forward model MATLAB functions (C. Mätzler May, 2002). These procedures were designed for MATLAB 2021a and some require the machine learning, statistics and/or parallel computing MATLAB toolboxes.

The cal_rho.m code is used to compute the density (i.e., rho) of the particles measured within the overlapping measurement region of an aerodynamic particle sizer (APS) and a laser aerosol spectrometer (LAS).

The MieKernal.m code is used to generate a dry scattering and absorption efficiency lookup table (i.e., Qf).

The S_e.m code is used to generate the covariance matrix (covM) of 6 optical coefficient measurements that are correlated by the correlation factor (i.e., cr).

The m_g_ret.m code is used to retrieve both total dry complex refractive index (i.e., m_d,t = n_d,t + k_d,t) and hygroscopicity (i.e., kappa). Calculated total ambient extinction coefficient at 550 nm (i.e., Cwe) and retrieved total growth factor (i.e., g) at the given relative humidity (RH) are also provided as part of the of the final output (i.e., op). The "S_e.m" function is required to generate the covariance matrix and "MieKernal.m" must be used to generate the dry scattering and absorption efficiency lookup table (i.e., Qf) for the data set.

The fit_SD.m code iteratively fits a measured total size resolved lognormal aerosol concentration (i.e., n_o) to a multimodal lognormal model and outputs the fitted modal number concentration (i.e., Nj), geometric standard deviation (i.e., sgj), and geometric mean diameter (i.e., Dgj). This code was created using the outline and guidelines provided by Hussein et al. (2005).