Skip to content

Commit

Permalink
whitespace cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
petermao committed Mar 8, 2023
1 parent e39ecbe commit be514e9
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions arc/calculations_atom_single.py
Original file line number Diff line number Diff line change
Expand Up @@ -782,19 +782,19 @@ def diagonalise(self, eFieldList, drivingFromState=[0, 0, 0, 0, 0],
upTo ('int', optional): Number of top contributing bases states
to be saved into composition attribute; Set to 4 by default.
To keep all contributing states, set upTo = -1.
totalContributionMax ('float', optional): Ceiling for
totalContributionMax ('float', optional): Ceiling for
contribution to the wavefunction from basis states included
in composition attribute. Composition will contain a list
of [coefficient, state index] pairs for top contributing
in composition attribute. Composition will contain a list
of [coefficient, state index] pairs for top contributing
unperturbed basis states until the number of states reaches
upTo or their total contribution reaches totalContributionMax,
whichever comes first. totalContributionMax is ignored if
upTo = -1.
upTo = -1.
"""

# if we are driving from some state
# ========= FIND LASER COUPLINGS (START) =======

coupling = []
dimension = len(self.basisStates)
self.maxCoupling = 0.
Expand Down Expand Up @@ -879,7 +879,7 @@ def diagonalise(self, eFieldList, drivingFromState=[0, 0, 0, 0, 0],
comp = []
for i in xrange(len(ev)):
sh.append(abs(egvector[indexOfCoupledState, i])**2)
comp.append(self._stateComposition2(egvector[:, i],
comp.append(self._stateComposition2(egvector[:, i],
upTo=upTo,
totalContributionMax=totalContributionMax))
self.highlight.append(sh)
Expand Down Expand Up @@ -1206,7 +1206,7 @@ def _stateComposition2(self, stateVector, upTo=300,totalContributionMax = 0.999)
index = -1
totalContribution = 0
mainStates = [] # [state Value, state index]

if upTo == -1:
for index in range(len(order)):
i = order[-index-1]
Expand Down

0 comments on commit be514e9

Please sign in to comment.