Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Davison, Jacob
tfimsrg
Commits
78c2d824
Commit
78c2d824
authored
Sep 07, 2020
by
Jacob August Davison
Browse files
updated pydoc string in main()
parent
16bc6384
Changes
1
Hide whitespace changes
Inline
Side-by-side
main.py
View file @
78c2d824
...
...
@@ -152,9 +152,9 @@ def main(n_holes, n_particles, ref=[], d=1.0, g=0.5, pb=0.0, verbose=1, flow_dat
d -- energy spacing in Pairing model (default: 1.0)
g -- pairing strength in Pairing model (default: 0.5)
pb -- pair-breaking in Pairing-plus-ph model (default: 0.0)
verbose -- toggles output of flow information
flow_data_log -- toggles output of flow data (pickled IM-SRG coefficients every 10 integrator steps)
generator -- specify generator to produce IM-SRG flow
verbose -- toggles output of flow information
(default: 1)
flow_data_log -- toggles output of flow data (pickled IM-SRG coefficients every 10 integrator steps)
(default: 0)
generator -- specify generator to produce IM-SRG flow
(default: wegner)
Returns:
...
...
@@ -242,7 +242,7 @@ def main(n_holes, n_particles, ref=[], d=1.0, g=0.5, pb=0.0, verbose=1, flow_dat
# break
if
iters
%
10
==
0
and
verbose
:
print
(
"iter: {:>6d}
\t
scale param: {:0.4f}
\t
E = {:0.8f}"
.
format
(
iters
,
solver
.
t
,
Es
))
if
flow_data_log
:
#
and iters %10 == 0:
if
flow_data_log
and
iters
%
10
==
0
:
H0B
,
H1B
,
H2B
=
get_vacuum_coeffs
(
Es
,
fs
,
Gs
,
ha
.
sp_basis
,
ha
.
holes
)
fname
=
'vac_coeffs_flow_c{}.p'
.
format
(
iters
)
pickle
.
dump
((
solver
.
t
,
H0B
,
H1B
,
H2B
),
open
(
fname
,
'wb'
))
...
...
@@ -261,7 +261,7 @@ def main(n_holes, n_particles, ref=[], d=1.0, g=0.5, pb=0.0, verbose=1, flow_dat
# if verbose: print("---- Energy diverged at iter {:>06d} with energy {:3.8f}\n".format(iters,E_vals[-1]))
# break
if
iters
>
2
0000
:
if
iters
>
1
0000
:
if
verbose
:
print
(
"---- Energy diverged at iter {:>06d} with energy {:3.8f}
\n
"
.
format
(
iters
,
E_vals
[
-
1
]))
break
...
...
@@ -342,7 +342,7 @@ if __name__ == '__main__':
# main(4,4, g=5, ref=[1,1,1,1,0,0,0,0])
main
(
4
,
4
,
g
=
0.5
,
flow_data_log
=
0
,
generator
=
'imtime'
)
main
(
4
,
4
,
g
=
2
,
flow_data_log
=
0
,
generator
=
'imtime'
)
# H1B_true, H2B_true = pickle.load(open('comparison.p','rb'))
# H1B, H2B = pickle.load(open('vac_coeffs_unevolved.p', 'rb'))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment