<div>Hi,</div>
<div> </div>
<div>I'm advancing my solution thru each time step. So after each time step, it'll be called again</div>
<div> </div>
<div>call PCHYPRESetType(pc,'boomeramg',ierr)<br> <br>call PCSetType(pc,'hypre',ierr)</div>
<div> </div>
<div>I tried to call "call PCHYPRESetType(pc,'boomeramg',ierr)" once during the entire run and it's ok. Is it supposed to be so?</div>
<div> </div>
<div>Thanks</div>
<p> </p>
<div><br><br> </div>
<div><span class="gmail_quote">On 5/22/07, <b class="gmail_sendername">Satish Balay</b> <<a href="mailto:balay@mcs.anl.gov">balay@mcs.anl.gov</a>> wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">you are probably doing this inside a loop. check the code.<br><br>satish<br><br>On Tue, 22 May 2007, Ben Tay wrote:
<br><br>> Sorry to trouble you ppl again.<br>><br>> The 1st step worked but subsequently I got the error msg:<br>><br>> --------------------- Error Message ------------------------------------<br>> [0]PETSC ERROR: Operation done in wrong order!
<br>> [0]PETSC ERROR: Cannot set the HYPRE preconditioner type once it has been<br>> set!<br>><br>> I have used :<br>><br>> call PCHYPRESetType(pc,'boomeramg',ierr)<br>><br>> call PCSetType(pc,'hypre',ierr)
<br>><br>><br>> I changed the 2 order but it still can't work.<br>><br>> Thanks again<br>><br>><br>><br>><br>><br>><br>> On 5/22/07, Ben Tay <<a href="mailto:zonexo@gmail.com">zonexo@gmail.com
</a>> wrote:<br>> ><br>> > Ops.... how careless. Thanks again.<br>> ><br>> > On 5/22/07, Barry Smith <<a href="mailto:bsmith@mcs.anl.gov">bsmith@mcs.anl.gov</a>> wrote:<br>> > ><br>
> > ><br>> > > pcsettype<br>> > ><br>> > ><br>> > > On Tue, 22 May 2007, Ben Tay wrote:<br>> > ><br>> > > > Sorry I got this error during linking:<br>> > > >
<br>> > > > petsc_sub.o(.text+0x20c): In function<br>> > > `petsc_sub_mp_petsc_solver_pois_':<br>> > > > /nfs/home/enduser/g0306332/ns2d_c/petsc_sub.F:125: undefined reference<br>> > > to
<br>> > > > `pcsetype_'<br>> > > ><br>> > > > Did I miss out something?<br>> > > ><br>> > > > Thanks<br>> > > ><br>> > > ><br>> > > > On 5/22/07, Satish Balay <
<a href="mailto:balay@mcs.anl.gov">balay@mcs.anl.gov</a>> wrote:<br>> > > > ><br>> > > > > use:<br>> > > > ><br>> > > > > call PCSetType(pc,'hypre',ierr)
<br>> > > > > call PCHYPRESetType(pc,'boomeramg',ierr)<br>> > > > ><br>> > > > > Satish<br>> > > > ><br>> > > > > On Tue, 22 May 2007, Ben Tay wrote:
<br>> > > > ><br>> > > > > > Hi,<br>> > > > > ><br>> > > > > > presently I am using ./a.out -pc_type hypre -pc_hypre_type<br>> > > boomeramg to
<br>> > > > > use<br>> > > > > > hypre.<br>> > > > > ><br>> > > > > > However, I have 2 matrix to solve and now I only want one of them<br>> > > to use
<br>> > > > > > hypre, while the other use jacobi + bcgs.<br>> > > > > ><br>> > > > > > for the solver using hypre,<br>> > > > > ><br>> > > > > > initially it's just:
<br>> > > > > ><br>> > > > > > call PCSetType(pc,PCLU,ierr) - direct solver<br>> > > > > ><br>> > > > > > I now changed to<br>> > > > > >
<br>> > > > > > call PCSetType(pc,hypre,ierr)<br>> > > > > ><br>> > > > > > call PCHYPRESetType(pc,boomeramg,ierr)<br>> > > > > ><br>> > > > > > However, I got the error msg:
<br>> > > > > ><br>> > > > > > fortcom: Error: petsc_sub.F, line 125: This name does not have a<br>> > > type,<br>> > > > > and<br>> > > > > > must have an explicit type. [HYPRE]
<br>> > > > > > call PCSetType(pc,hypre,ierr)<br>> > > > > ><br>> > > > > > Sorry I don't really understand the eg. hyppilut.c since my<br>> > > knowledge of
<br>> > > > > the<br>> > > > > > c language is very basic.<br>> > > > > ><br>> > > > > > So how should I set the options to use hypre?<br>> > > > > >
<br>> > > > > > Thank you.<br>> > > > > ><br>> > > > ><br>> > > > ><br>> > > ><br>> > ><br>> > ><br>> ><br>><br><br>
</blockquote></div><br>