Skip to content

Commit

Permalink
updated README
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Wietek committed Jul 16, 2024
1 parent 7cf5a70 commit 3e610e8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ int main() try {
Spinhalf block(n_sites, nup);

// Define the nearest-neighbor Heisenberg model
BondList bonds;
OpSum ops;
for (int i = 0; i < n_sites; ++i) {
bonds += Bond("HB", "J", {i, (i + 1) % n_sites});
ops += Op("HB", "J", {i, (i + 1) % n_sites});
}
bonds["J"] = 1.0;
ops["J"] = 1.0;

set_verbosity(2); // set verbosity for monitoring progress
double e0 = eigval0(bonds, block); // compute ground state energy
set_verbosity(2); // set verbosity for monitoring progress
double e0 = eigval0(ops, block); // compute ground state energy

Log("Ground state energy: {:.12f}", e0);

Expand Down

0 comments on commit 3e610e8

Please sign in to comment.