<div>Dear all,</div>
<div> </div>
<div> I'm trying to solve the magnetic induction equation on a 3D finite element mesh. </div>
<div> I'm coding the following:</div>
<div> </div>
<div> call TSCreate (petsc_comm_world, ts_mhd, ierpetsc) <br /><br /> call TSSetIFunction ( ts_mhd, res_mhd, residual_mag, <br /> @ PETSC_NULL_OBJECT, ierpetsc ) <br /> <br /> call TSSetSolution( ts_mhd, Bmagnetic_pet, ierpetsc )<br /> <br /> call TSGetSNES (ts_mhd, snes_mhd, ierpetsc )<br /> <br /> call MatCreateSNESMF ( snes_mhd, J_mf, ierpetsc ) <br /><br /> call TSSetMaxSNESFailures ( ts_mhd,-1,ierpetsc )<br /> <br /> call SNESSetJacobian ( snes_mhd, J_mf, M_mhd,<br /> @ PETSC_NULL_FUNCTION, PETSC_NULL_OBJECT, ierpetsc )<br /> <br /> call TSSetFromOptions ( ts_mhd, ierpetsc )</div>
<div> </div>
<div> call TSSolve ( ts_mhd, PETSC_NULL_OBJECT, ierpetsc) </div>
<div> </div>
<div> and I run with the following options:</div>
<div> </div>
<div> -ts_dt 1.0e-2<br /> -ts_type beuler<br /> -ts_final_time 1.0<br /> -ts_view</div>
<div> </div>
<div> But, when my code reaches TSSolve it gives an error:</div>
<div> </div>
<div> ERROR: [0 mhdsol] Segmentation fault - (Invalid memory reference)<br /><br data-mce-bogus="1" /></div>
<div> Any ideas or suggestions on what to do?</div>
<div> </div>
<div> Regards,</div>
<div> </div>
<div> Kostas</div>