no longer reallocates buffer if only beta value is changed