MatConvert with same+reuse+inplace

Barry Smith bsmith at mcs.anl.gov
Tue Feb 5 15:51:34 CST 2008


   Lisandro,

     I added the code

   if ((reuse == MAT_REUSE_MATRIX) && (issame || sametype))  
PetscFunctionReturn(0);

   do you think this will handle the cases appropriately.

    Barry

On Feb 5, 2008, at 12:49 PM, Lisandro Dalcin wrote:

> What is the expected behavior of the following, assuming option
> '-matconvert_type' is not given?
>
> MatConvert(A, MATSAME, MAT_REUSE_MATRIX, &A)
>
> Should it be a no-op? I have to ask because if that is the case, It
> seems the current code is broken. I'm missing something?
>
> -- 
> Lisandro Dalcín
> ---------------
> Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
> Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
> Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
> PTLC - Güemes 3450, (3000) Santa Fe, Argentina
> Tel/Fax: +54-(0)342-451.1594
>




More information about the petsc-dev mailing list