/span>

    <span class="keyword">if</span> ( i &gt; idz )

        <span class="comment">% Mean velocity value for the ZUPT window time</span>
        vel_m = mean (vel_e(i-idz:i , :));

        <span class="comment">% If mean velocity value is under the ZUPT threshold velocity...</span>
        <span class="keyword">if</span> (abs(vel_m) &lt; vor_dme.zupt_th)

            <span class="comment">% Current attitude is equal to the mean of previous attitudes</span>
            <span class="comment">% inside t