Move max_wavenumber to initState