<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Fri, Jul 20, 2018 at 8:01 AM Pierpaolo Minelli <<a href="mailto:pierpaolo.minelli@cnr.it">pierpaolo.minelli@cnr.it</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
in my code I have to solve both a system in the field of real numbers and in the field of complex numbers.<br>
My approach has been as follows.<br>
First I configured PETSc with the --with-scalar-type=complex option.<br>
Using this option I have unfortunately lost the possibility to use the two preconditioners ML and Hypre.<br>
I later created two subspaces of Krylov and tried to solve the two systems as I used to when solving the only equation in the real numbers field.<br>
In order to correctly solve the system in the field of real numbers I had to transform the coefficients from real to complex with an imaginary part equal to zero.<br>
<br>
Is there a possibility to use a different and better approach to solve my problem?<br>
<br>
Perhaps an approach where you can continue to use ML and Hypre for system solving in the real numbers field or where you don't need to use complex numbers when real numbers would actually suffice?<br></blockquote><div><br></div><div>Yes, any linear system in complex numbers can be converted to a system twice as large in real numbers. So far,</div><div>I think this is the best way to handle it, especially the elliptic ones.</div><div><br></div><div> Thanks,</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thanks in advance<br>
<br>
Pierpaolo<br>
<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div>