<div class="gmail_quote">On Wed, Mar 14, 2012 at 11:27, Mark F. Adams <span dir="ltr"><<a href="mailto:mark.adams@columbia.edu">mark.adams@columbia.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im"><blockquote type="cite">The matrix is asymmetric. Does this require the setting of an option?<br></blockquote><div><br></div></div><div>Yes: -pc_gamg_sym_graph</div><div></div></blockquote></div><br><div>
Mark, I don't like this name. First, it's imperative in the sense that it's describing a procedure for fixing something rather than declarative (stating some property of the problem). Second, there is already a way to state symmetry, MatSetOption():</div>
<div><br></div><div><div> Options Describing Matrix Structure:</div><div>+ MAT_SPD - symmetric positive definite</div><div>- MAT_SYMMETRIC - symmetric in terms of both structure and value</div><div>. MAT_HERMITIAN - transpose is the complex conjugation</div>
<div>. MAT_STRUCTURALLY_SYMMETRIC - symmetric nonzero structure</div><div>- MAT_SYMMETRY_ETERNAL - if you would like the symmetry/Hermitian flag</div><div> you set to be kept with all future use of the matrix</div>
<div> including after MatAssemblyBegin/End() which could</div><div> potentially change the symmetry structure, i.e. you </div><div> KNOW the matrix will ALWAYS have the property you set.</div>
</div><div><br></div><div><br></div><div>Is there a reason you can't just use this information? If you have multiple methods for handling nonsymmetric structure, then I would suggest using PetscOptionsList() or PetscOptionsEnum() to select which to use.</div>