petsc to matlab
    Matthew Knepley 
    knepley at mcs.anl.gov
       
    Thu Mar  2 14:56:04 CST 2006
    
    
  
billy at dem.uminho.pt writes:
       What goes wrong?
            Matt
> How can I save the matrix in PETSc and load it in matlab?
>
> I tried this but it does not work:
>
>
>   PetscViewer view;
>
>   PetscViewerCreate (PETSC_COMM_WORLD, &view);
>
>   PetscViewerSetFormat (view, PETSC_VIEWER_ASCII_MATLAB);
>
>   PetscViewerAsciiOpen(PETSC_COMM_WORLD, "matrix.mat", &view);
>   
>   MatView(A, view);
>
>   PetscViewerDestroy(view);
>
>
>
> Billy.
>
>
>
-- 
"Failure has a thousand explanations. Success doesn't need one" -- Sir Alec Guiness
    
    
More information about the petsc-users
mailing list