<div dir="ltr">Dear PETSc --<div><br></div><div>I notice in the users manual that the C examples show</div><div><br></div><div>ierr = PetscInitialize(&argc,&args,(char*)0,help);if (ierr) return ierr;</div><div><br></div><div>at the start of main() and </div><div><br></div><div>ierr = PetscFinalize();<br>return ierr;</div><div><br></div><div>at the end of main().  Is this the deliberate, recommended style?  My understanding of these choices is that if PetscInitialize() fails then CHKERRQ(ierr) may not do the right thing, while if PetscFinalize() fails then that should be the result of main() (without any fiddling by CHKERRQ etc.).  Is this the correct understanding?</div><div><br></div><div>Thanks,</div><div><br>Ed</div><div><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>Ed Bueler<br>Dept of Mathematics and Statistics<br>University of Alaska Fairbanks<br>Fairbanks, AK 99775-6660<br>306C Chapman<br></div></div></div></div></div></div></div></div></div>