Skip to content

Commit 0d73390

Browse files
Matthias Fabryevbauer
andauthored
pgbinary docs (#525)
pgbinary docs --------- Co-authored-by: evbauer <[email protected]>
1 parent ef9e1c5 commit 0d73390

File tree

14 files changed

+2287
-2150
lines changed

14 files changed

+2287
-2150
lines changed

binary/defaults/pgbinary.defaults

Lines changed: 2203 additions & 2104 deletions
Large diffs are not rendered by default.

binary/private/pgbinary_ctrls_io.f90

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1331,7 +1331,7 @@ module pgbinary_ctrls_io
13311331
Orbit_ytop, &
13321332
Orbit_file_width, &
13331333
Orbit_file_aspect_ratio, &
1334-
Orbit_txt_scale, &
1334+
Orbit_txt_scale_factor, &
13351335
Orbit_show_RL, &
13361336

13371337
annotation1_ci, &
@@ -2805,7 +2805,7 @@ subroutine store_pgbinary_controls(b, ierr)
28052805
pg% Orbit_ytop = Orbit_ytop
28062806
pg% Orbit_file_width = Orbit_file_width
28072807
pg% Orbit_file_aspect_ratio = Orbit_file_aspect_ratio
2808-
pg% Orbit_txt_scale = Orbit_txt_scale
2808+
pg% Orbit_txt_scale_factor = Orbit_txt_scale_factor
28092809
pg% Orbit_show_RL = Orbit_show_RL
28102810

28112811
pg% annotation1_ci = annotation1_ci

binary/private/pgbinary_grid.f90

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -534,7 +534,7 @@ subroutine Grid_plot(b, id, device_id, &
534534
case ('orbit')
535535
call do_orbit_plot(&
536536
b, id, device_id, xleft, xright, ybot, ytop, grid_subplot, b% pg% Orbit_title, &
537-
Grid_txt_scale_factor(i) * b% pg% Orbit_txt_scale, ierr)
537+
Grid_txt_scale_factor(i) * b% pg% Orbit_txt_scale_factor, ierr)
538538
case default
539539
! check for "other" plot
540540
found_it = .false.
@@ -557,9 +557,9 @@ subroutine Grid_plot(b, id, device_id, &
557557
write(*, '(a)') &
558558
'here are the valid names:', &
559559
'Summary_History', &
560-
'Text_Summary1,..,9', &
561-
'History_Panels1,..,9', &
562-
'History_Tracks1,..,9', &
560+
'Text_Summary1..9', &
561+
'History_Panels1..9', &
562+
'History_Tracks1..9', &
563563
'Star1,2'
564564
write(*, *)
565565

binary/private/pgbinary_orbit.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ subroutine Orbit_plot(id, device_id, ierr)
4747
call do_Orbit_plot(b, id, device_id, &
4848
b% pg% Orbit_xleft, b% pg% Orbit_xright, &
4949
b% pg% Orbit_ybot, b% pg% Orbit_ytop, .false., &
50-
b% pg% Orbit_title, b% pg% Orbit_txt_scale, ierr)
50+
b% pg% Orbit_title, b% pg% Orbit_txt_scale_factor, ierr)
5151
if (ierr /= 0) return
5252
call pgebuf()
5353
end subroutine Orbit_plot

binary/private/pgbinary_star.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ subroutine do_star_plot(b, id, device_id, xleft, xright, &
203203
call plot_case(b% s1, b% star_ids(1))
204204
call update_pgstar_history_file(b% s1, ierr)
205205
else
206-
write(mass, '(f12.3)') b% m(1) / Msun
206+
write(mass, '(f3.2)') b% m(1) / Msun
207207
call pgmtxt('T', -2.0, 0.5, 0.5, 'Star 1 not simulated')
208208
call pgmtxt('T', -3.0, 0.5, 0.5, 'point mass of ' // trim(adjustl(mass)) // ' M\d\(2281)')
209209
end if

binary/public/pgbinary_controls.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -932,7 +932,7 @@ real :: Orbit_win_width, Orbit_win_aspect_ratio, &
932932
Orbit_ybot, Orbit_ytop, &
933933
prev_Orbit_win_width, prev_Orbit_win_ratio, &
934934
Orbit_file_width, Orbit_file_aspect_ratio, &
935-
prev_Orbit_file_width, prev_Orbit_file_ratio, Orbit_txt_scale
935+
prev_Orbit_file_width, prev_Orbit_file_ratio, Orbit_txt_scale_factor
936936

937937
integer :: annotation1_ci, annotation1_lw, annotation1_cf
938938
real :: annotation1_ch

binary/test_suite/evolve_both_stars/inlist_pgbinary

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,14 @@ pgbinary_model_fjust = 1.4
99
pgbinary_grid_title_disp = 0.2
1010
pgbinary_title_disp = 0.2
1111

12+
13+
Orbit_win_flag = .true.
14+
Orbit_win_width = 8
15+
16+
1217
Grid1_win_flag = .true.
1318

14-
Grid1_win_width = 19.5
19+
Grid1_win_width = 19
1520
Grid1_win_aspect_ratio = 0.58
1621

1722
Grid1_xleft = 0.0

docs/source/_ext/defaults2rst.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
'kap/defaults',
1212
'reference/binary_job',
1313
'reference/binary_controls',
14+
'reference/pgbinary',
1415
'reference/star_job',
1516
'reference/controls',
1617
'reference/pgstar',

docs/source/changelog.rst

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,35 @@ A new other_close_gaps hook has been added. Provided by Simon Guichandut
3333
Backwards-incompatible changes
3434
------------------------------
3535

36+
Module enhancement: ``pgbinary``
37+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
38+
39+
When running ``./binary`` models it is useful to have graphical
40+
output to 'see' what's going on.
41+
Previously, this was only possible on the ``pgstar`` level, meaning you would
42+
need to setup two ``pgstar`` windows if you are evolving two stars in the
43+
binary.
44+
45+
Here we introduce ``pgbinary``, which acts much like ``pgstar``. You enable it
46+
with the ``&binary_job`` inlist with ``pgbinary_flag = .true.``. Then you
47+
select windows and/or files to be plotted in the ``&pgbinary`` inlist.
48+
Currently the following plot types can be created:
49+
50+
* History_Track[1-9],
51+
* Summary_History,
52+
* History_Panels[1-9],
53+
* Text_Summary[1-9],
54+
* Grid[1-9],
55+
56+
analogous to their ``pgstar`` equivalents, and two ``pgbinary``-only plots:
57+
58+
* Star[1-2], to plot a star window through ``&pgstar`` controls, within ``pgbinary``.
59+
* Orbit, a visual representation of the stars' sizes to their separation
60+
61+
Main use case is to have a single window containing both stars' ``pgstar`` info,
62+
through using ``Grid`` at the ``pgbinary`` level, populating it with ``Star1``
63+
and ``Star2``, and have each plot profile info, Kipp diagrams etc...
64+
3665
Renamed controls for upper limits
3766
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3867

docs/source/doc_archive/defaults2rst.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ defaults2rst ../kap/defaults/kap.defaults source/kap/defaults.rst
1717
# binary
1818
defaults2rst ../binary/defaults/binary_job.defaults source/reference/binary_job.rst
1919
defaults2rst ../binary/defaults/binary_controls.defaults source/reference/binary_controls.rst
20+
defaults2rst ../binary/defaults/pgbinary.defaults source/reference/pgbinary.rst
21+
2022

2123
# star
2224
defaults2rst ../star/defaults/star_job.defaults source/reference/star_job.rst

0 commit comments

Comments
 (0)