class="o">&gt;=</span> <span class="n">q_break_cycle</span><span class="p">)</span> <span class="ow">and</span> <span class="p">(</span><span class="n">diff_g</span><span class="p">[</span><span class="o">-</span><span class="mi">1</span><span class="p">]</span> <span class="o">&lt;=</span> <span class="p">(</span><span class="mi">2</span> <span class="o">*</span> <span class="n">num_regimes</span> <span class="o">*</span> <span class="n">T</span> <span class="o">//</span> <span class="mi">100</span><span c