Partitioning on a mpiaij matrix

LECAS Dimitri dimitri.lecas at c-s.fr
Mon Feb 12 10:44:03 CST 2007



----- Original Message -----
From: Barry Smith <bsmith at mcs.anl.gov>
Date: Monday, February 12, 2007 2:42 pm
Subject: Re: Partitioning on a mpiaij matrix

> 
>  It is convertfrom, not convert you need to check.
> 
>  In src/mat/impls/adj/mpi/mpiadj.c MatCreate_MPIAdj
> there is the line
>  ierr                = PetscMemcpy(B-
> >ops,&MatOps_Values,sizeof(struct _MatOps));CHKERRQ(ierr);
> in the MatOps_Values above it there is 
> /*60*/ 0,
>       MatDestroy_MPIAdj,
>       MatView_MPIAdj,
>       MatConvertFrom_MPIAdj,
>       0,
> 
> Therefor the conversion function convertfrom MUST be in the matrix 
> ops table
> when the convert is called. But it is not for you, how is this 
> possible?
> 
>   Barry
> 

I made some progress but it's not very comprehensible

It's seems there is a problem with parmetis. When i compile petsc
without parmetis, this line don't give an error.

CALL Matconvert(mat,MATMPIADJ,MAT_INITIAL_MATRIX,mat2,ierr)
CHKERRQ(ierr)

With mat created with  
CALL MatCreateMPIAIJ (PETSC_COMM_WORLD, partTab(rk+1), partTab(rk+1), N,
N, 30  , PETSC_NULL_INTEGER, 30, PETSC_NULL_INTEGER, mat, ierr)

But, when petsc is compiled with parmetis, the call to MatConvert give
the error 
[0]PETSC ERROR: No support for this operation for this object type!
[0]PETSC ERROR: Mat type mpiadj!

-- 
Dimitri Lecas




More information about the petsc-users mailing list