a href="https://www.mcs.anl.gov/petsc/petsc-current/src/ksp/ksp/tutorials/ex50.c.html#line21">the source code</a></li>
</ul>

<p>DO THE FOLLOWING:</p>
<ul>
  <li> Compile src/ksp/ksp/tutorials/ex50.c
    <pre>
      cd petsc/src/ksp/ksp/tutorials
      make ex50
  </pre>
  </li>
  <li> Run a 1 processor example with a 3x3 mesh and view the matrix assembled
    <pre>
     mpiexec -n 1 ./ex50  -da_grid_x 4 -da_grid_y 4 -mat_view     <a href="https://www.mcs.anl.gov/petsc/petsc-current/src/ksp/ksp/tutorials/ou