ss="keyword">end</span>
</pre><pre class="codeinput"><span class="keyword">function</span> [f, df] = conT0(m, policy, s)                                  <span class="comment">% dMdm</span>
<span class="keyword">if</span> nargout &lt; 2
    M = policy.fcn(policy, m, s);
<span class="keyword">else</span>
    [M, S, C, dMdm] = policy.fcn(policy, m, s);
    df = dMdm;
<span class="keyword">end</span>
f = M;

<span class="keyword">function</span> [f, df] = conT1(m, policy, s)                                  <s