<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>Hi,</p>
    <p>I need to use DMDACreate3d to create objects da and da_psr which
      have 2 different sizes:</p>
    <p>call
DMDACreate3d(MPI_COMM_WORLD,DM_BOUNDARY_NONE,DM_BOUNDARY_NONE,DM_BOUNDARY_NONE,DMDA_STENCIL_STAR,size_x,size_y,&<br>
      <br>
             
size_z,one,PETSC_DECIDE,PETSC_DECIDE,one,stencil_width,lx,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,da_p,ierr)</p>
    <p><br>
    </p>
    <p>call
DMDACreate3d(MPI_COMM_WORLD,DM_BOUNDARY_NONE,DM_BOUNDARY_NONE,DM_BOUNDARY_NONE,DMDA_STENCIL_STAR,size_x_psr,size_y_psr,&<br>
      <br>
             
size_z_psr,one,PETSC_DECIDE,PETSC_DECIDE,one,stencil_width,lx,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,da_p_psr,ierr)</p>
    <p><br>
    </p>
    <p>size_x/y/z_psr is actually half of size_x/y/z</p>
    <p>However, running the 2nd line gave error:</p>
    <p>[0]PETSC ERROR: Arguments are incompatible<br>
      [0]PETSC ERROR: Ownership ranges sum to 76 but global dimension is
      38<br>
      [0]PETSC ERROR: See
      <a class="moz-txt-link-freetext" href="http://www.mcs.anl.gov/petsc/documentation/faq.html">http://www.mcs.anl.gov/petsc/documentation/faq.html</a> for trou<br>
      ble shooting.</p>
    <p>size_x is 76 but size_x_prs is 38.</p>
    <p>So do I need to create 2 comm (MPI communicator) if I need to
      create da_p_psr? are using different values of
      size_x_psr,size_y_psr, size_z_psr not enough?</p>
    <div class="moz-signature">-- <br>
      <p>Thank you very much.<br>
        <br>
        Yours sincerely,<br>
        <br>
        ================================================<br>
        TAY Wee-Beng 郑伟明 (Zheng Weiming)<br>
        Personal research webpage: <font color="#3366ff"><u><a class="moz-txt-link-freetext" href="http://tayweebeng.wixsite.com/website">http://tayweebeng.wixsite.com/website</a></u></font><br>
        Youtube research showcase: <u><font color="#3366ff"><a class="moz-txt-link-freetext" href="https://goo.gl/PtvdwQ">https://goo.gl/PtvdwQ</a></font></u><br>
        linkedin: <u><font color="#3366ff"><a class="moz-txt-link-freetext" href="https://www.linkedin.com/in/tay-weebeng">https://www.linkedin.com/in/tay-weebeng</a></font></u><br>
        ================================================<br>
      </p>
    </div>
  </body>
</html>