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

General Hartree-Fock mean fields #316

Merged
merged 11 commits into from
Oct 25, 2024
Merged

General Hartree-Fock mean fields #316

merged 11 commits into from
Oct 25, 2024

Conversation

pablosanjose
Copy link
Owner

Non-spatial models allow us to build and solve mean-field Hartree-Fock problems when interactions are purely on-site. Otherwise, the Hartree potential on a site i depends on the density matrix on other sites, which cannot be expressed cleanly using the non-spatial model approach.

With the possibility of computing only a density matrix on a sparse or diagonal collection of site pairs (#315), it now becomes possible to tackle the above problem efficiently

Here we introduce a new meanfield(g::GreenFunction,...) constructor of a M::MeanField object. This object can build a Hartree-Fock mean field stored in a Φ::OrbitalSliceMatrix with Φ = M(µ, kBT; params...). Then, a non-spatial model such as @onsite((i; phi = missing) --> phi[i]) + @hopping((i, j; phi = missing) --> phi[i, j]) can be used to inject the mean field into a Hamiltonian. See updated documentation for a tutorial.

@codecov-commenter
Copy link

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

Attention: Patch coverage is 88.07531% with 57 lines in your changes missing coverage. Please review.

Project coverage is 92.46%. Comparing base (5a6b446) to head (f919c99).

Files with missing lines Patch % Lines
src/specialmatrices.jl 67.34% 16 Missing ⚠️
src/types.jl 83.33% 11 Missing ⚠️
src/tools.jl 75.60% 10 Missing ⚠️
src/show.jl 53.33% 7 Missing ⚠️
src/observables.jl 86.11% 5 Missing ⚠️
src/meanfield.jl 93.84% 4 Missing ⚠️
src/slices.jl 93.10% 2 Missing ⚠️
src/greenfunction.jl 99.06% 1 Missing ⚠️
src/hamiltonian.jl 75.00% 1 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #316      +/-   ##
==========================================
- Coverage   92.90%   92.46%   -0.44%     
==========================================
  Files          38       39       +1     
  Lines        6678     6903     +225     
==========================================
+ Hits         6204     6383     +179     
- Misses        474      520      +46     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pablosanjose pablosanjose merged commit 13c2be2 into master Oct 25, 2024
9 checks passed
@pablosanjose pablosanjose deleted the hartreefock branch October 25, 2024 15:37
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