Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bragg cavity spectroscopy #2

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

LorenzoFioroni
Copy link
Contributor

This PR adds to TorchGPE the code used to study the roton-mode softening at the onset of self-organization

@@ -254,6 +257,7 @@ def get_alpha(self, psi: torch.tensor, time: float = None):
self.eta = np.sqrt(self._lattice_depth(time))*self.eta_prefactor

alpha = self.c1*self.eta*order/self.c6
alpha = (self.c1*self.eta*order + self._cavity_probe(time)*(self.Er/spconsts.hbar))/self.c6

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Shouldn't we remove line 259?
  2. For real time evolution 260 will work, however for the imaginary time evolution we have "time"=None, which causes problems with callable cavity_probe(). I agree that it is not so useful in the imaginary time but we can allow in the imaginary time evolution to have stationary probes that do not change in time; constant cavity_probe(). That's why initially I had if clause discriminating with None value for the time and two different way of cavity_probe being calculated.

Copy link

@JustStefaniak JustStefaniak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comments for the get alpha implementation.

@LorenzoFioroni
Copy link
Contributor Author

  1. Shouldn't we remove line 259?

Yes, you are right. Thanks

  1. For real time evolution 260 will work, however for the imaginary time evolution we have "time"=None, which causes problems with callable cavity_probe(). I agree that it is not so useful in the imaginary time but we can allow in the imaginary time evolution to have stationary probes that do not change in time; constant cavity_probe(). That's why initially I had if clause discriminating with None value for the time and two different way of cavity_probe being calculated.

In line 207 we define self._cavity_probe = time_dependent_variable(self.cavity_probe). This means that if its value is constant, self._cavity_probe will be a function mapping any input to the constant value self.cavity_probe. Hence, I would argue that even if time is None everything should work. Am I mistaken?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants