Determine if mode J(fj țs) exists where fj = jǻf and țs = s ǻ ț, 
loop: 1 <= j <= N 
 Calculate Mlocal
 loop: |s| <= Mlocal
```

```
 Determine if mode J(j,s) exists 
 end 
end 