Custom mode calculation