[Carpet] Assertion `leveltimes.at(ml).at(rl) == global_time' failed

Erik Schnetter schnetter at cct.lsu.edu
Fri May 16 16:56:59 CEST 2008


On May 16, 2008, at 06:40:57, Bruno Giacomazzo wrote:

> Erik,
> 	I have received the following error in several runs after few  
> iterations:
>
> Assertion `leveltimes.at(ml).at(rl) == global_time' failed.
>
> 	which I think is the assert in line 106 in Evolve.cc:
>
>      // Ensure that all levels have consistent times
>      {
>        // This is dangerouse because it compares floating point
>        // numbers for equality
>        assert (cctkGH->cctk_time == global_time);
>        for (int ml=0; ml<mglevels; ++ml) {
>          for (int rl=0; rl<reflevels; ++rl) {
>            int const do_every =
>              ipow (mgfact, ml) * (maxtimereflevelfact /  
> timereffacts.at(rl));
>            if (cctkGH->cctk_iteration % do_every == 0) {
>              // This is dangerouse because it compares floating point
>              // numbers for equality
>              assert (leveltimes.at(ml).at(rl) == global_time);
>
>
> 	It's actually the first time I see this error. Can it be related to  
> the recent changes you did to the development version of Carpet?


Bruno,

yes, I introduced this check recently to ensure that the times on all  
refinement levels remain consistent.  I have now made these  
comparisons less strict.

I am currently trying to ensure that the times associated with the  
individual refinement levels are consistent with the global time in  
Carpet.  There were some inconsistencies, reported by Ian Hinder and  
Nils Dorband, which should be corrected now.  This code is an  
additional check that should ensure consistency.  According to the  
IEEE floating point standard these conditions should hold, but maybe  
your compiler is using strong optimisations.  If not, then there is  
still some inconsistency left.

These inconsistencies are small, of the order of floating point round- 
off, but they accumulate over time, and I want to prevent this.

-erik

-- 
Erik Schnetter <schnetter at cct.lsu.edu>   http://www.cct.lsu.edu/~eschnett/

My email is as private as my paper mail.  I therefore support encrypting
and signing email messages.  Get my PGP key from www.keyserver.net.



-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 194 bytes
Desc: This is a digitally signed message part
Url : /archives/developers/attachments/20080516/45cf4155/attachment.pgp 


More information about the developers mailing list