<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">Hello,<DIV><BR class="khtml-block-placeholder"></DIV><DIV>I think VC is ok for editing (maybe), but PETSc and mpich are easier to work with in the command line. You might save yourself some headache. Just paste your file into a plain text.cpp and put it in a directory such as your desktop. Then cd to your desktop and compile from the command line. I promise your life will be simpler in the long term.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>best,</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Chris</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR><DIV><DIV>On Oct 25, 2006, at 10:18 PM, Yixun Liu wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Hi,</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"></FONT> </DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Can I think that if I set -np 100, but only have 2 actually, the size will be 100?</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Another question,</SPAN></FONT><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">I run the progarm from VC++6.0 instead of command line. How to make the program run on 2 processors?</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"></FONT> </DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Best,</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"></FONT> </DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Yixun</SPAN></FONT></DIV><BLOCKQUOTE style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px"><DIV style="FONT: 9pt 宋体; font-family: 宋体; "><SPAN class="Apple-style-span" style="font-family: 宋体; ">----- Original Message -----</SPAN></DIV><DIV style="BACKGROUND: #e4e4e4; FONT: 9pt 宋体; font-color: black; font-family: 宋体; "><B style="font-family: 宋体; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: 宋体; font-weight: bold; ">From:</SPAN></B><SPAN class="Apple-style-span" style="font-family: 宋体; "> </SPAN><A title="knepley@gmail.com" href="mailto:knepley@gmail.com"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); font-family: 宋体; -khtml-text-decorations-in-effect: underline; ">Matthew Knepley</SPAN></A><SPAN class="Apple-style-span" style="font-family: 宋体; "></SPAN></DIV><DIV style="FONT: 9pt 宋体; font-family: 宋体; "><B style="font-family: 宋体; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: 宋体; font-weight: bold; ">To:</SPAN></B><SPAN class="Apple-style-span" style="font-family: 宋体; "> </SPAN><A title="petsc-users@mcs.anl.gov" href="mailto:petsc-users@mcs.anl.gov"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); font-family: 宋体; -khtml-text-decorations-in-effect: underline; ">petsc-users@mcs.anl.gov</SPAN></A><SPAN class="Apple-style-span" style="font-family: 宋体; "></SPAN></DIV><DIV style="FONT: 9pt 宋体; font-family: 宋体; "><B style="font-family: 宋体; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: 宋体; font-weight: bold; ">Sent:</SPAN></B><SPAN class="Apple-style-span" style="font-family: 宋体; "> Thursday, October 26, 2006 9:47 AM</SPAN></DIV><DIV style="FONT: 9pt 宋体; font-family: 宋体; "><B style="font-family: 宋体; font-weight: bold; "><SPAN class="Apple-style-span" style="font-family: 宋体; font-weight: bold; ">Subject:</SPAN></B><SPAN class="Apple-style-span" style="font-family: 宋体; "> Re: about MPI_Comm_size(PETSC_COMM_WORLD,&amp;size)</SPAN></DIV><DIV><BR></DIV>On 10/25/06,<SPAN class="Apple-converted-space"> </SPAN><B class="gmail_sendername"><SPAN class="Apple-style-span" style="font-weight: bold; ">Yixun Liu</SPAN></B><SPAN class="Apple-converted-space"> </SPAN>&lt;<A href="mailto:yxliu@fudan.edu.cn"><SPAN class="Apple-style-span" style="color: rgb(0, 0, 238); -khtml-text-decorations-in-effect: underline; ">yxliu@fudan.edu.cn</SPAN></A>&gt; wrote:<DIV><SPAN class="gmail_quote"></SPAN><BLOCKQUOTE class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: rgb(204,204,204) 1px solid"><DIV bgcolor="#ffffff"><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Hi,</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"></FONT> </DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">My computer is a standare dual processors PC of Dell corp., but after calling   ierr = PI_Comm_size(PETSC_COMM_WORLD,&amp;size), I find the size is one. Is it correct?</SPAN></FONT></DIV></DIV></BLOCKQUOTE><DIV><BR>MPI only knows what mpiruns tells it. You ran the exampe with -np 1. If you use -np 2, then it will have size 2.<BR><BR>  Matt<BR></DIV><BR><BLOCKQUOTE class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: rgb(204,204,204) 1px solid"><DIV bgcolor="#ffffff"><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Best,</SPAN></FONT></DIV><DIV><FONT face="Bookman Old Style"></FONT> </DIV><DIV><FONT face="Bookman Old Style"><SPAN class="Apple-style-span" style="font-family: Bookman Old Style; ">Yixun</SPAN></FONT></DIV></DIV></BLOCKQUOTE></DIV>--<SPAN class="Apple-converted-space"> </SPAN><BR>"Failure has a thousand explanations. Success doesn't need one" -- Sir Alec Guiness</BLOCKQUOTE><BR class="Apple-interchange-newline"></SPAN></BLOCKQUOTE></DIV><BR><DIV> <SPAN class="Apple-style-span" style="border-collapse: separate; border-spacing: 0px 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-align: auto; -khtml-text-decorations-in-effect: none; text-indent: 0px; -apple-text-size-adjust: auto; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px; "><DIV>Chris Harden</DIV><DIV>Graduate Assistant</DIV><DIV>School of Computational Science</DIV><DIV>Florida State University</DIV><DIV>446-B Dirac Science Library</DIV><DIV>Tallahassee, Florida 32306-4120</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Voice: 850.644.3442</DIV><DIV>E-mail: <A href="mailto:charden@scs.fsu.edu">charden@scs.fsu.edu</A></DIV><DIV><A href="http://www.scs.fsu.edu/~charden/">http://www.scs.fsu.edu/~charden/</A></DIV><BR class="Apple-interchange-newline"></SPAN> </DIV><BR></DIV></BODY></HTML>