[Trilinos-Users] time cost by AztecOO::Iterate(int MaxIters, double Tolerance)

Henian Xia xiahenian at gmail.com
Thu Mar 31 13:18:11 MDT 2011


Hi Siva,
Thank you for your reply. Yes, I did use a preconditioner by calling
"(*solver).SetAztecOption(AZ_precond, AZ_Jacobi);" and I didn't call the
ConstructPreconditioner() before calling Iterate.

Can the time to compute the preconditioner be scaled? In my simulation, it
seems that typically it will take 7 seconds to calculate the preconditioner
no matter how many CPUs are used. More often, even more than 10 seconds are
used to compute the preconditioner when using 960 cpus, while the iteration
takes only about 10s too using 960 cpus. Is this result reasonable to you
please?

Thanks,
Henian
On Thu, Mar 31, 2011 at 2:51 PM, Siva Rajamanickam <srajama at sandia.gov>wrote:

>  Are you using Aztec's native preconditioners ? If yes, then do you call
> ConstructPreconditioner() before calling Iterate. If you don't do that then
> Aztec computes the preconditioner in the first iteration and your *timeUsedByCallingIterate
> *might include that cost as well.
>
> Siva
>
> Henian Xia wrote:
>
> Hello everyone,
> In my application, I have to call AztecOO::Iterate(int MaxIters,double
> Tolerance) to solve the equation Ax=b. There is output like below when
> calling this function:
>
>         ********************************************************
>         ***** Problem: Epetra::CrsMatrix
>         ***** Preconditioned GMRES solution
>         ***** 1 step block Jacobi
>         ***** No scaling
>         *******************************************************
>                 iter:    0           residual = 1.000000e+00
>                 ....
>                 iter:   41           residual = 3.345028e-08
>                 iter:   42           residual = 2.219359e-08
>                 iter:   43           residual = 1.459019e-08
>                 iter:   44           residual = 9.729064e-09
>         Solution time: 0.051379 (sec.)
>         total iterations: 44*
>
> But I found that the displayed "Solution time" was sometimes much smaller
> than the real time. For example, I used the following simple code to time
> the calling to that method.
>
> *double ttemp3 = MPI_Wtime();
> (*solver).Iterate(2000, 1.0E-8);
> double ttemp4 = MPI_Wtime();
> double timeUsedByCallingIterate = ttemp4 - ttemp3;*
>
> Especially when I use multiple CPUs, such as 960 cores, the difference
> between the calculated "timeUsedByCallingIterate" and the output "Solution
> time" can be huge. Why is this happening please?
>
> Thank you,
> Henian
> --
> Henian Xia
> Graduate Research Assistant
> Department of MABE
> University of Tennessee, Knoxville
>
> ------------------------------
>
> _______________________________________________
> Trilinos-Users mailing listTrilinos-Users at software.sandia.govhttp://software.sandia.gov/mailman/listinfo/trilinos-users
>
>
>


-- 
Henian Xia
Graduate Research Assistant
Department of MABE
University of Tennessee, Knoxville
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://software.sandia.gov/pipermail/trilinos-users/attachments/20110331/26d24bb1/attachment-0001.html 


More information about the Trilinos-Users mailing list