clwainwright / CosmoTransitions

A package for analyzing finite or zero-temperature cosmological phase transitions driven by single or multiple scalar fields.
MIT License
25 stars 19 forks source link

NotImplementedError: Two phases have been found to coincide at one end but not the other. #3

Closed PhysicsBaker closed 7 years ago

PhysicsBaker commented 7 years ago

Hi,

I'm using CosmoTransitions to analyse the phase transitions of the effective potential in http://arxiv.org/abs/1608.07578.

For many parameter points it raises the exception:

"Two phases have been found to coincide at one end " NotImplementedError: Two phases have been found to coincide at one end but not the other. Ideally, this function would find where the two diverge, make a cut, and join them such there are no more phase redundancies. Instead, just raise an exception.

Is this something that could be easily implemented (either by an expert or by me with a bit of guidance)? Or is there an available work around?

Many thanks,

Mike

clwainwright commented 7 years ago

Hi Mike,

That error comes about in the removeRedundantPhases function, which is needed when you trace the high-temperature evolution of two phases individually, and the two end up splitting from a common higher temperature phase via a phase transition. The higher temperature phase can get included twice, and this gets rid of one of the copies. Without getting rid of one copy you'd end up with micro transitions between nearly identical states. The problem occurs when you have two phases that join together in something that doesn't really look like a phase transition — dphi/dT remains finite — so the algorithm makes no distinction between the low-temperature phase and the high-temperature phase. So you end up with the temperature evolution of two different phases, both of which are the same at high temperature but different at low temperature.

The ideal solution would be to implement the algorithm in the not implemented error. I don't think this would be too hard to do, you just need to find the distance between the two phases as a function of temperature, mark where two diverge, and split them into low temperature and high temperature parts. Then you can get rid of one of the duplicate high-T pieces.

A much easier work around would just be to tighten your numerical tolerances. I don't think you can actually have two phases join each other without causing dphi/dT to diverge in any physically reasonable model (i.e., the second derivative of the field will go to zero in a second order transition), so if you tighten your tolerances you might be able to resolve the divergence. Try decreasing x_eps and/or T_eps in the generic_potential class or your subclass thereof.

Let me know if you have any luck.

Cheers, Carroll

PhysicsBaker commented 7 years ago

Hi Carroll,

Thanks a lot for replying so quickly! Yes, ok, that's pretty much what I thought the error meant, from your exception description.

Thanks for sketching what the function should do. For now, as you suggested, I've found that I can improve things by varying x_eps (although in my case T_eps doesn't seem to have any effect).

I'll stick to this for now, but will let you know if I try to implement this function in the future.

Thanks again,

Mike

DarkKnight6777 commented 4 years ago

I am running cosmoTransitions for vev values 10^(3 to 7) GeV and kept the x_eps and T_eps as self.x_eps = .00001 self.T_eps = .001 Still I am getting NotImplementedError: Two phases have been found to coincide at one end but not the other. Ideally, this function would find where the two diverge, make a cut, and join them such there are no more phase redundancies. Instead, just raise an exception.

Any suggestions