Actual source code: ex164.c


  2: static char help[] = "Tests MatConvert() from SeqDense to SeqAIJ \n\n";

  4: #include <petscmat.h>

  6: int main(int argc, char **args)
  7: {
  8:   Mat      A, C;
  9:   PetscInt n = 10;

 12:   PetscInitialize(&argc, &args, (char *)0, help);
 13:   MatCreateSeqDense(PETSC_COMM_WORLD, n, n, NULL, &A);
 14:   MatConvert(A, MATSEQDENSE, MAT_INITIAL_MATRIX, &C);
 15:   MatView(C, NULL);
 16:   MatDestroy(&A);
 17:   MatDestroy(&C);
 18:   PetscFinalize();
 19:   return 0;
 20: }

 22: /*TEST

 24:    test:

 26: TEST*/