Code used to explore the end correction of a spherically baffled piston
The files are as follows:
end_correction_spherically_baffled_piston.m: function to calcualte the end correction of a spherically baffled piston
legendrep.m: function to calculate the Legendre polynomials
fig_1_diagram.m: creates the diagram of Fig. 1
fig_2_spherically_baffled_piston_end_correction.m: creates Fig. 2
fig_3_end_correction_comparison.m: creates Fig. 3
sup_1_expansion_approximations.m: evaluates the validity of Eq. (14) in place of Eq. (5)
sup_2_discrete_summation2integral.m: evaluate the validity of the discrete sum to continuous integral approximation
sup_3_end_correction_minimum.m: finds the minimum value of the end correction