Bug fix. Issue calculating correct lmax.