Thanks.<div><br></div><div>Best,</div><div>Xin<br><br><div class="gmail_quote">On Wed, Aug 15, 2012 at 6:45 PM, Lisandro Dalcin <span dir="ltr"><<a href="mailto:dalcinl@gmail.com" target="_blank">dalcinl@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 15 August 2012 14:13, Xin Zhao <<a href="mailto:sean.null@gmail.com">sean.null@gmail.com</a>> wrote:<br>
> Dear all,<br>
><br>
> What I need is just to solve a very easy linear ODE.<br>
><br>
> u_t = Au<br>
><br>
> A is sparse and constant.<br>
><br>
> But I didn't find a counterpart of TSSetMatrices in petsc4py for this.<br>
> It is strange because petsc4py can handle much harder problems.<br>
><br>
<br>
</div></div>TSSetMatrices() is no longer supported in petsc-3.3. You have to<br>
rewrite your problem in implicit nonlinear form, and ask TS to solve a<br>
linear problem. You still have to code your IFunction and IJacobian in<br>
Python, use the PETSc C implementations TSComputeIFunctionLinear() and<br>
TSComputeIJacobianConstant() and translate to Python.<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
--<br>
Lisandro Dalcin<br>
---------------<br>
CIMEC (INTEC/CONICET-UNL)<br>
Predio CONICET-Santa Fe<br>
Colectora RN 168 Km 472, Paraje El Pozo<br>
3000 Santa Fe, Argentina<br>
Tel: <a href="tel:%2B54-342-4511594" value="+543424511594">+54-342-4511594</a> (ext 1011)<br>
Tel/Fax: <a href="tel:%2B54-342-4511169" value="+543424511169">+54-342-4511169</a><br>
</font></span></blockquote></div><br></div>