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

Work towards entangled units #178

Merged
merged 44 commits into from
Oct 22, 2023
Merged

Work towards entangled units #178

merged 44 commits into from
Oct 22, 2023

Conversation

kbarros
Copy link
Member

@kbarros kbarros commented Oct 8, 2023

No description provided.

@Lazersmoke
Copy link
Contributor

@kbarros there's something funky with the system show instance in this PR. You should check that typing both sys and [sys] in the repl produce sensible output (the second one is used frequently for inverse modelling + distributed)

@kbarros
Copy link
Member Author

kbarros commented Oct 16, 2023

@kbarros there's something funky with the system show instance in this PR.

Extracted from this PR and fixed on main: 920e4b7

@ddahlbom
Copy link
Member

ddahlbom commented Oct 17, 2023

Recent pushes include:

  1. Generalized interactions for SU(N) LSWT.
  2. LSWT biquadratic functionality now uses the Stevens operators and works with the general 5x5 quadrupolar exchange matrix that is provided by Kip's refactor. (This needs a test of some sort.)
  3. Some reorganization of the SU(N) LSWT code, mostly in the form of breaking things into discrete functions.
  4. Removal of extra buffers and some code simplifications.
  5. Elimination of all allocations from the construction of the SWT Hamiltonian (well, for SU(N) anyway -- dipole mode will probably need some additional work).
  6. A few other performance enhancements (e.g., checking whether bilin or biquad is zero before executing associated code -- this is quite significant).
  7. Precalculation of external magnetic field operators when the SpinWaveTheory is first constructed.
  8. Addition of two tests:
    • Consistency of Hamiltonian construction when extract_parts is true and false
    • A reference test for spin ladder intensities, which exercises the generalized interactions

Further simplifications are possible -- we only really need the basic logic of swt_onsite_coupling! and swt_general_couplings! and could eliminate both swt_bilinear! and swt_biquadratic!. I am leaving these for now, however, since we should discuss the implications for KPM. I left the contents and style of swt_bilinear! and swt_biquadratic! very similar to the original code so hopefully it is still readable to Hao, with whom I will discuss further. We may want to redo the indexing a bit once everyone is on the same page.

@ddahlbom
Copy link
Member

I reorganized the SWT file structure a bit. I did not end up doing much to the dipole part of the SWT code. Probably it should be kept in familiar form for the time being to make it easier for Hao to add the general biquadratic. This can be addressed in a future PR.

There's still a fair amount on the table as far as simplifying and accelerating the SWT code. But I think what's done here represents a self-contained revision that incorporates the general interactions into SU(N) SWT.

As I mentioned on Slack, dipole and SU(N) modes seem to use different sign conventions for the external field. I'll examine this a bit. Once that's resolved, this will be good to go from my perspective.

@kbarros
Copy link
Member Author

kbarros commented Oct 22, 2023

As I mentioned on Slack, dipole and SU(N) modes seem to use different sign conventions for the external field.

@ddahlbom mentioned elsewhere that the sign conventions are the same.

@kbarros kbarros merged commit 4326d7a into main Oct 22, 2023
3 checks passed
@kbarros kbarros deleted the gen_exchange branch October 22, 2023 16:03
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.

3 participants