-
Notifications
You must be signed in to change notification settings - Fork 210
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: additional ways to construct an ElectronicDensity
- Loading branch information
Showing
3 changed files
with
245 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
releasenotes/notes/feat-electronic-denisty-initializations-d1bd5131c5776418.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
features: | ||
- | | ||
Three news means of initializing an :class:`~qiskit_nature.second_q.properties.ElectronicDensity` | ||
have been added. | ||
.. code-block:: python | ||
size = 4 # number of spatial orbitals | ||
from qiskit_nature.second_q.properties import ElectronicDensity | ||
empty = ElectronicDensity.empty(size, include_rdm2=True) | ||
identity = ElectronicDensity.identity(size, include_rdm2=True) | ||
num_particles = (2, 2) | ||
two_and_two = ElectronicDensity.from_particle_number(size, num_particles) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters