function tx = linzerocross(cross_index,signal_array,ts)
% this function linearly approximates the zero cross X coordinate from the
% Y coordinates closest to zero
dy = abs(signal_array(cross_index)-signal_array(cross_index-1));
dx = ts;

tx = (double(cross_index)-3) * dx + dx*(1-abs(double(signal_array(cross_index)))/dy);
end

