change pattern to adapt all three rates cases