[petsc-users] Questions abt ex22f

TAY wee-beng zonexo at gmail.com
Sun Apr 22 16:21:19 CDT 2012


On 22/4/2012 10:02 PM, Matthew Knepley wrote:
> On Sun, Apr 22, 2012 at 3:55 PM, TAY wee-beng <zonexo at gmail.com 
> <mailto:zonexo at gmail.com>> wrote:
>
>     Hi,
>
>     I changed the vs2008 and linux source code to
>     VecView(x,PETSC_VIEWER_STDOUT_WORLD,ierr) but the results for both
>     outputs are 0 and 0.0416667 (except for one value which is
>     0.0833333) respectively.
>
>
> It looks to me like there is a bug in KSPSetUp(). 
> The DMKSPGetContext() is returning a null struct,
> so the RHS is never formed, and the Mat is formed by the default call 
> to DMComputeJacobian. What
> is intended here with KSPDM?
Hi,

So is there a way to fix the bug? What can be done to get it working? Is 
this the only fortran example which solve the laplacian equation using 
multigrid ?

Thanks!
>
>    Matt
>
>     Yours sincerely,
>
>     TAY wee-beng
>
>
>     On 22/4/2012 9:35 PM, Jed Brown wrote:
>>     On Sun, Apr 22, 2012 at 14:30, TAY wee-beng <zonexo at gmail.com
>>     <mailto:zonexo at gmail.com>> wrote:
>>
>>         Sorry for the mistake. I tried again, changing to "call
>>         VecView(x,0,ierr)"
>>
>>         but still got the same error:
>>
>>
>>     0 has the wrong type. Use VecView(x,PETSC_VIEWER_STDOUT_WORLD,ierr)
>
>
>
>
> -- 
> What most experimenters take for granted before they begin their 
> experiments is infinitely more interesting than any results to which 
> their experiments lead.
> -- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120422/112a285b/attachment.htm>


More information about the petsc-users mailing list