%
%  oa_power_function.m  ver 1.2  by Tom Irvine
%
%  The script calculates the overall level for a sound power level
%  or any other function expressed in terms of dB.
%
%  The input is a 1D array of dB values
%
%  The output oadB is the overall level in dB.
%
%
function[oadB]=oa_power_function(dB)

p = 1e-12 * 10.^(dB / 10);
oadB = 10 * log10(norm(p) / 1e-12);
