static double form_volume(double length_a, double length_b, double length_c) { return length_a * length_b * length_c; } static double Iq(double q, double sld, double solvent_sld, double length_a, double length_b, double length_c) { const double mu = 0.5 * q * length_b; // Scale sides by B const double a_scaled = length_a / length_b; const double c_scaled = length_c / length_b; // outer integral (with gauss points), integration limits = 0, 1 double outer_total = 0; //initialize integral for( int i=0; i