Added get_beam_width function