Hi, I am trying to solve a linear system where Ay=x and A is a 5x5 matrix stored in a binary file called 'square' and x=[1;1;1;1;1]
I am trying to display the matrix A, and the vectors x(rhs) and y(soln) in that order to standard output. On running my code on a single processor the answer returned is accurate. But on using 2 processors I get weird error messages PART of which says [0]PETSC ERROR: [1]PETSC ERROR: --------------------- Error Message ------------------------------------ [1]PETSC ERROR: Nonconforming object sizes! [1]PETSC ERROR: Mat mat,Vec x: global dim 5 10! Also somehow the vector x gets displayed TWICE when run on two processes. A however gets displayed ONCE (as it should!!) I am attaching the output I get when I run on 1 process and the when I run the same code on 2 processes. please let me know where I could be going wrong. (1) This is what I get on running on ONE process: (Here system is solved successfully) gaurish108 at gaurish108-laptop:~/Desktop$ $PETSC_DIR/$PETSC_ARCH/bin/mpiexec -n 1 ./ex4 -f square 1.5761308167754828e-01 1.4188633862721534e-01 6.5574069915658684e-01 7.5774013057833345e-01 7.0604608801960878e-01 9.7059278176061570e-01 4.2176128262627499e-01 3.5711678574189554e-02 7.4313246812491618e-01 3.1832846377420676e-02 9.5716694824294557e-01 9.1573552518906709e-01 8.4912930586877711e-01 3.9222701953416816e-01 2.7692298496088996e-01 4.8537564872284122e-01 7.9220732955955442e-01 9.3399324775755055e-01 6.5547789017755664e-01 4.6171390631153941e-02 8.0028046888880011e-01 9.5949242639290300e-01 6.7873515485777347e-01 1.7118668781156177e-01 9.7131781235847536e-02 Process [0] 1 1 1 1 1 KSPGetIterationNumber 5 KSPGetResidualNorm 0.000000 Process [0] -0.810214 2.33178 -1.31131 1.09323 1.17322 gaurish108 at gaurish108-laptop:~/Desktop$ %-------------------------------------------------------------------- This is what I get on running on TWO processes: (2) gaurish108 at gaurish108-laptop:~/Desktop$ $PETSC_DIR/$PETSC_ARCH/bin/mpiexec -n 2 ./ex4 -f square 1.5761308167754828e-01 1.4188633862721534e-01 6.5574069915658684e-01 7.5774013057833345e-01 7.0604608801960878e-01 9.7059278176061570e-01 4.2176128262627499e-01 3.5711678574189554e-02 7.4313246812491618e-01 3.1832846377420676e-02 9.5716694824294557e-01 9.1573552518906709e-01 8.4912930586877711e-01 3.9222701953416816e-01 2.7692298496088996e-01 4.8537564872284122e-01 7.9220732955955442e-01 9.3399324775755055e-01 6.5547789017755664e-01 4.6171390631153941e-02 8.0028046888880011e-01 9.5949242639290300e-01 6.7873515485777347e-01 1.7118668781156177e-01 9.7131781235847536e-02 Process [0] 1 1 1 1 1 Process [1] 1 1 1 1 1 [0]PETSC ERROR: [1]PETSC ERROR: --------------------- Error Message ------------------------------------ [1]PETSC ERROR: Nonconforming object sizes! [1]PETSC ERROR: Mat mat,Vec x: global dim 5 10! [1]PETSC ERROR: ------------------------------------------------------------------------ [1]PETSC ERROR: Petsc Release Version 3.1.0, Patch 5, Mon Sep 27 11:51:54 CDT 2010 [1]PETSC ERROR: See docs/changes/index.html for recent updates. [1]PETSC ERROR: See docs/faq.html for hints about trouble shooting. [1]PETSC ERROR: --------------------- Error Message ------------------------------------ [0]PETSC ERROR: Nonconforming object sizes! [0]PETSC ERROR: Mat mat,Vec x: global dim 5 10! [0]PETSC ERROR: See docs/index.html for manual pages. [1]PETSC ERROR: ------------------------------------------------------------------------ [1]PETSC ERROR: ./ex4 on a linux-gnu named gaurish108-laptop by gaurish108 Mon Jan 17 23:49:18 2011 [1]PETSC ERROR: Libraries linked from /home/gaurish108/Desktop/ResearchMeetings/SUPERPETS/petsc-3.1-p5/linux-gnu-c-debug/lib [1]PETSC ERROR: Configure run at Sat Nov 13 20:34:38 2010 [1]PETSC ERROR: Configure options --with-cc=gcc --with-fc=gfortran --download-f-blas-lapack=1 --download-mpich=1 --download-superlu_dist=1 --download-parmetis=1 --with-superlu_dist=1 --with-parmetis=1 [1]PETSC ERROR: ------------------------------------------------------------------------ [1]PETSC ERROR: MatMultTranspose() line 1947 in src/mat/interface/matrix.c [1]PETSC ERROR: KSPSolve_CGNE() line 103 in src/ksp/ksp/impls/cg/cgne/cgne.c [1]PETSC ERROR: KSPSolve() line 396 in src/ksp/ksp/interface/itfunc.c [1]PETSC ERROR: main() line 78 in src/mat/examples/tutorials/ex4.c application called MPI_Abort(MPI_COMM_WORLD, 60) - process 1[cli_1]: aborting job: application called MPI_Abort(MPI_COMM_WORLD, 60) - process 1 [0]0:Return code = 0, signaled with Interrupt [0]1:Return code = 60 gaurish108 at gaurish108-laptop:~/Desktop$ -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20110117/2551b3ab/attachment.htm>
