s="o">=</span> <span class="n">e_x</span> <span class="o">+</span> <span class="n">e_c</span>
    <span class="n">E_xc</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">dot</span><span class="p">(</span><span class="n">e_xc</span><span class="p">,</span> <span class="n">n</span><span class="p">)</span> <span class="o">*</span> <span class="n">s</span><span class="o">.</span><span class="n">dx</span>
    <span class="n">E_x</span> <span class="o">=</span> <span 