Then you aren't using a matrix-free method at all. Just don't call SNESSetJacobian and it will be done for you. Are you using a DM? If not, you will also need to create a MatFDColoring. The easiest way to do that, if you don't have a structured mesh, is to assemble the nonzero pattern of your operator.<br>
<br><div class="gmail_quote">On Wed, Oct 10, 2012 at 3:44 PM, <span dir="ltr"><<a href="mailto:panourg@mech.upatras.gr" target="_blank">panourg@mech.upatras.gr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Is exactly the same.<br>
<br>
Kostas<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
<br>
<br>
<br>
<br>
> On Wed, Oct 10, 2012 at 3:32 PM, <<a href="mailto:panourg@mech.upatras.gr">panourg@mech.upatras.gr</a>> wrote:<br>
><br>
>> Dear all<br>
>><br>
>> I have a non-linear system which i want to solve it with matrix free<br>
>> method. However i must form the whole proconditioning matrix using<br>
>> finite<br>
>> differences and coloring method.<br>
>><br>
><br>
> How is the preconditioning matrix different from the actual operator?<br>
><br>
><br>
>><br>
>> I can set the function F() of non-linear system (i take the notation F()<br>
>> from documentation).<br>
>><br>
>> Could you send me exactly the commands and the order of it which i must<br>
>> use or an apt example for that?<br>
>><br>
>> I have looked for that in internet but i could not find any suitable<br>
>> example.<br>
>><br>
>> Kostas<br>
>><br>
>> Thanks<br>
>><br>
>><br>
><br>
<br>
</div></div></blockquote></div><br>