! inlist_agb_to_wd


&star_job
      show_log_description_at_start = .false.
      
      !create_pre_main_sequence_model = .true.

      !save_model_number = 22501
      !save_model_filename = '1.0_z2m2_pre_ms.mod'
      save_model_filename = 'pre_wd.mod'

      load_saved_model = .true.
      !saved_model_name = '1.0_z2m2_pre_ms.mod'
      !saved_model_name = '0.544_from_1.0_z2m2.mod'
      saved_model_name = 'pre_wd.mod'

      !change_net = .true.      
      !new_net_name = 'pp_and_cno_extras.net'
      !new_net_name = 'pp_and_cno_extras.jina'
      !new_net_name = 'net_A32.jina'

      !log_columns_file = 'log_columns.list' 
      !profile_columns_file = 'profile_columns.list' 

      kappa_file_prefix = 'gs98'

      !pgplot_flag = .true.



/ ! end of star_job namelist

&controls

      D_norm_kappa = 1
      D_norm_alpha = 2 
      D_norm_atol = 1d-3
      D_norm_rtol = 1d-3


      use_lnE_for_eps_grav = .false.
      
      
      initial_mass = 1.0
      initial_z = 0.02d0

      ! check for retries and backups as part of test_suite
      max_number_backups = 100
      max_number_retries = 100

      photostep = 50
      profile_interval = 50
      log_cnt = 100
      terminal_cnt = 10
      write_header_frequency = 10

      gamma_center_limit = 160
      
      max_model_number = 1000
      
      !max_model_number = 433
      !op_split_burn_mix_trace = .true.
      !op_split_mix_trace = .true.
      
      !trace_mass_location = 0.3

      !report_hydro_solver_progress = .true. ! set true to see info about newton iterations
      !report_ierr = .true. ! if true, produce terminal output when have some internal error

      report_why_dt_limits = .false.
      report_all_dt_limits = .false.
      
      !show_mesh_changes = .true.
      !mesh_dump_call_number = 8875
      !okay_to_remesh = .false.

      trace_evolve = .false.
      
      ! hydro debugging
      !hydro_check_everything = .true.
      !hydro_inspectB_flag = .true.
      
      !hydro_numerical_jacobian = .true.
      !hydro_save_numjac_plot_data = .true.
      !small_mtx_decsol = 'lapack'
      !large_mtx_decsol = 'lapack'
      !hydro_dump_call_number = 195
      
      !trace_shell_tracking_choice = .true.
      
      RGB_wind_scheme = 'Reimers'
      AGB_wind_scheme = 'Blocker'
      RGB_to_AGB_wind_switch = 1d-4
      Reimers_wind_eta = 0.5d0  
      Blocker_wind_eta = 0.1d0  

      use_CO_enhanced_opacities = .false.
      


/ ! end of controls namelist



&pgstar


      ! PGSTAR uses PGPLOT and X windows to make plots while mesa/star is running

      ! this file gives the default values of the controls for PGSTAR
      
      ! unlike the controls for the stellar evolution,
      ! these controls are read at each timestep during the run
      ! and take effect immediately.
      
      ! this means that you can edit your inlist while mesa/star is running
      ! to change the plots.

      ! for each window, there is an "activation" flag
      
         ! if the flag is set true, the window is created if necessary and updated at each step.
         ! if the flag is false at the start, the window is not created.
         ! if the flag is set false during the run, the window is "frozen".
         ! resetting the flag to true "thaws" the window for updating.

         
      ! top level controls

         !pause = .true. 
            ! if true, the code waits for user to enter a RETURN on the command line
         
      
      ! "main" window (also called the "summary" window)
      
         !MAIN_win_flag = .false.
      
         show_HR_TRho_with_main = .true. ! if true, use aspect ratio = 0.62 or so
         MAIN_win_width = 14.5
         MAIN_win_aspect_ratio = 0.78 !1.2 ! aspect_ratio = height/width
      
         xaxis_by = 1 ! select xaxis for main window
            ! 1 = by_mass
            ! 2 = by_grid
            ! 3 = by_radius
            ! 4 = by_logR
            ! 5 = by_logP
            ! 6 = by_logxm
            
         !show_main_win_text_info = .false.
         
         ! xaxis limits -- to override system default selections
         !main_xmin = 0.50
         main_xmax = 0.542
         
         logxq_cutoff = -7.1 ! min value when using logxm for xaxis
         
         ! control for plot showing abundances
         log_mass_frac_ymax = 0.7 ! making this > 0 helps readability
         log_mass_frac_ymin = -5.1
         num_abundance_line_labels = 5
      
         log_abund_vary = 0.1 ! don't show species if it would vary by < this in plot

         show_main_annotation1 = .false.
         show_main_annotation2 = .false.
         show_main_annotation3 = .false.
      
         ! png output
         MAIN_file_flag = .true.
         MAIN_file_dir = 'pgstar_out'
         MAIN_file_prefix = 'main'
         MAIN_file_cnt = 2 ! output when mod(model_number,main_file_cnt)==0
      
      
      ! HR window -- lg_L vs. lg_Teff
      
         !HR_win_flag = .true.
      
         HR_win_width = 12.5
         HR_win_aspect_ratio = 0.62 ! aspect_ratio = height/width
      
         ! axis limits -- to override system default selections
         HR_logT_min = -1000 !3.44 !-101 ! only used if > -100
         !HR_logT_max = 3.8 ! for pre-ms to tip of AGB
         HR_logT_max = -1000 !5.2 ! tip of AGB to end
         
         HR_logL_min = -1000 !-0.8 !-101 ! only used if > -100
         HR_logL_max =-1000 ! 4.01 !-101 ! only used if > -100
      
         HR_age_min = -1 ! only plot models with age >= this
         HR_step_min = -1 ! only plot models with model number >= this
         HR_step_max = 999999 ! only plot models with model number <= this
         
         ! png output
         !HR_file_flag = .true.
         HR_file_dir = 'pgstar_out'
         HR_file_prefix = 'hr'
         HR_file_cnt = 5 ! output when mod(model_number,HR_file_cnt)==0
         
      
      ! TRho window -- central temperature vs. density
      
         !TRho_win_flag = .true.
      
         TRho_win_width = 12.5
         TRho_win_aspect_ratio = 0.62 ! aspect_ratio = height/width
      
         ! axis limits -- to override system default selections
         TRho_logT_min = -1000 !6.8 ! for pre-ms to tip of AGB
         TRho_logT_max = -1000 !8.4 ! for pre-ms to tip of AGB
         !TRho_logT_min = 7.92 ! tip of AGB to end
         !TRho_logT_max = 7.99 ! tip of AGB to end

         TRho_logRho_min = -1000 !3 ! for pre-ms to tip of AGB
         !TRho_logRho_min = 6.08 ! tip of AGB to end
         TRho_logRho_max = -1000 !6.4 ! -101 ! only used if > -100

         TRho_age_min = -1 ! only plot models with age >= this
         TRho_step_min = -1 ! only plot models with model number >= this
         TRho_step_max = 999999 ! only plot models with model number <= this

         show_TRho_annotation1 = .true.
         show_TRho_annotation2 = .true.
         show_TRho_annotation3 = .false.
         
         ! png output
         !TRho_file_flag = .true.
         TRho_file_dir = 'pgstar_out'
         TRho_file_prefix = 'trho'
         TRho_file_cnt = 5 ! output when mod(model_number,TRho_file_cnt)==0
      
      
      ! Convection window -- history of convection and more.
      
         !CONV_win_flag = .true.
      
         CONV_win_width = 12.5
         CONV_win_aspect_ratio = 0.62 ! aspect_ratio = height/width
      
         ! axis limits
         CONV_xmax = -1 ! step number.  negative means use default.
         CONV_xmin = -1 ! step number.  negative means use default.
         CONV_max_width = 0 ! only used if > 0.  causes xmin to move with xmax.
         CONV_mmax = -1 ! (Msun units) negative means use start initial mass
         CONV_mmin =0 ! (Msun units)
         CONV_lgLmax = -101 ! only used if > -100; (L in Lsun units)
         CONV_lgLmin = -2 ! only used if > -100; (L in Lsun units)

         CONV_show_burn = .false.
         CONV_show_mixing = .false.
         CONV_show_log_radius = .false.
         !CONV_show_luminosities = .false.
         CONV_show_mass_boundaries = .true.
         
         ! png output
         !CONV_file_flag = .true.
         CONV_file_dir = 'pgstar_out'
         CONV_file_prefix = 'conv'
         CONV_file_cnt = 5 ! output when mod(model_number,CONV_file_cnt)==0
      
      
      ! TRho Profile window -- current model in T-Rho plane
      
         !TRho_Profile_win_flag = .true.

         TRho_Profile_win_width = 12.5
         TRho_Profile_win_aspect_ratio = 0.62 ! aspect_ratio = height/width
            
         !show_TRho_Profile_text_info = .false.
         !show_TRho_Profile_legend = .false.
         show_HR_TRho_with_TRho_Profile = .true.
         show_TRho_Profile_burn_labels = .false.

         show_TRho_Profile_annotation1 = .true.
         show_TRho_Profile_annotation2 = .true.
         show_TRho_Profile_annotation3 = .true.
      
         ! axis limits
         TRho_Profile_xmin = -1.0
         TRho_Profile_xmax = 6.7
         TRho_Profile_ymin = 6.2
         TRho_Profile_ymax = 8.7
         
         
         ! for png movies
         ! setenv PGPLOT_PNG_WIDTH 1200
         ! setenv PGPLOT_PNG_HEIGHT 742
         ! png output
         !TRho_Profile_file_flag = .true.
         TRho_Profile_file_dir = 'pgstar_out'
         TRho_Profile_file_prefix = 'trho_profile'
         TRho_Profile_file_cnt = 1 ! output when mod(model_number,TRho_Profile_file_cnt)==0
         
      
      ! HR_TRho window -- HR and TRho together
      
         HR_TRho_win_flag = .false.
      
         HR_TRho_win_width = 7.5
         HR_TRho_win_aspect_ratio = 1.5 ! aspect_ratio = height/width
                  
         ! png output
         HR_TRho_file_flag = .false.
         HR_TRho_file_dir = ''
         HR_TRho_file_prefix = 'trho'
         HR_TRho_file_cnt = 5 ! output when mod(model_number,HR_TRho_file_cnt)==0
      
      
      ! Profile window
      
         !Profile_win_flag = .true.

         Profile_win_width = 12.5
         Profile_win_aspect_ratio = 0.62 ! aspect_ratio = height/width
            
         show_Profile_legend = .true.
         Profile_legend_coord = 0.05
         Profile_legend_fjust = 0.0
         Profile_legend_disp1 = -28.5
         Profile_legend_del_disp = -1.5
         Profile_show_mass_locs = .false.
         Profile_show_decorated_line = .true.
         
         show_HR_TRho_with_Profile = .true.
         show_Profile_cross_hair = .false.

         show_Profile_text_info = .true.
         Profile_text_info_xfac = 0.13 ! controls x location
         Profile_text_info_dxfac = 0.02 ! controls x spacing to value from text
         Profile_text_info_yfac = 0.7 ! controls y location of 1st line
         Profile_text_info_dyfac = -0.04 ! controls line spacing

         show_Profile_annotation1 = .true.
         show_Profile_annotation2 = .true.
         show_Profile_annotation3 = .false.
         
         ! axis choices
            ! to get a list of axis identifiers, edit your star_job controls
               ! to set show_profile_column_numbers = .true.
            ! you can use any identifier for x or y
         Profile_xaxis_id = 14 ! mass
         Profile_xaxis_reversed = .false.
         
         !Profile_xmin = 0 ! only used if > -100
         !Profile_xmax = 1.001 !-101 ! only used if > -100

         Profile_xmax = 0.55 ! after reach he flash
         Profile_xmin = 0.41 ! only used if > -100
         
         Profile_yaxis_id = 26 ! logT
         Profile_yaxis_reversed = .false.
         Profile_ymin = 6.0
         !Profile_ymin = 4.0
         !Profile_ymax = 7.8    
         Profile_ymax = 8.7     
         
         Profile_other_yaxis_id = 0
         Profile_other_yaxis_reversed = .false.
         Profile_other_ymin = -101 ! only used if > -100
         Profile_other_ymax = -101 ! only used if > -100        
         
         ! png output
         !Profile_file_flag = .true.
         Profile_file_dir = 'pgstar_out'
         Profile_file_prefix = 'profile'
         Profile_file_cnt = 1 ! output when mod(model_number,Profile_file_cnt)==0
         
         
      ! Central History window
      
         !Cntr_Hist_win_flag = .true.
      
         Cntr_Hist_win_width = 12.5
         Cntr_Hist_win_aspect_ratio = 1.2 ! aspect_ratio = height/width
      
         ! axis limits
         Cntr_Hist_xmax = -1 ! step number.  negative means use default.
         Cntr_Hist_xmin = -1 ! step number.  negative means use default.
         !Cntr_Hist_max_width = 300 ! only used if > 0.  causes xmin to move with xmax.
         
         ! abundance limits
         Cntr_Hist_mass_frac_min = 0
         Cntr_Hist_mass_frac_max = 1.1
         
         ! png output
         Cntr_Hist_file_flag = .false.
         Cntr_Hist_file_dir = ''
         Cntr_Hist_file_prefix = 'conv'
         Cntr_Hist_file_cnt = 5 ! output when mod(model_number,Cntr_Hist_file_cnt)==0
         
         
      ! Surface History window
      
         !Surf_Hist_win_flag = .true.
      
         Surf_Hist_win_width = 12.5
         Surf_Hist_win_aspect_ratio = 1.2 ! aspect_ratio = height/width
      
         ! axis limits
         Surf_Hist_xmax = -1 ! step number.  negative means use default.
         Surf_Hist_xmin = -1 ! step number.  negative means use default.
         Surf_Hist_max_width = 0 ! only used if > 0.  causes xmin to move with xmax.
         
         ! abundance limits
         Surf_Hist_mass_frac_min = 0
         Surf_Hist_mass_frac_max = 1.1 ! > 0 helps legibility
         
         ! png output
         Surf_Hist_file_flag = .false.
         Surf_Hist_file_dir = ''
         Surf_Hist_file_prefix = 'conv'
         Surf_Hist_file_cnt = 5 ! output when mod(model_number,Surf_Hist_file_cnt)==0

      
      ! "annotation" strings -- provide args for PGMTXT
      
      !          Write text at a position specified relative to the viewport (outside
      !          or inside).  The text is written using the current values of
      !          attributes color-index, line-width, character-height, and
      !          character-font.
      !           
      !           SIDE            : must include one of the characters 'B', 'L', 'T',
      !                             or 'R' signifying the Bottom, Left, Top, or Right
      !                             margin of the viewport. If it includes 'LV' or
      !                             'RV', the string is written perpendicular to the
      !                             frame rather than parallel to it.
      !           DISP            : the displacement of the character string from the
      !                             specified edge of the viewport, measured outwards
      !                             from the viewport in units of the character
      !                             height. Use a negative value to write inside the
      !                             viewport, a positive value to write outside.
      !           COORD           : the location of the character string along the
      !                             specified edge of the viewport, as a fraction of
      !                             the length of the edge.
      !           FJUST           : controls justification of the string parallel to
      !                             the specified edge of the viewport. If
      !                             FJUST = 0.0, the left-hand end of the string will
      !                             be placed at COORD; if JUST = 0.5, the center of
      !                             the string will be placed at COORD; if JUST = 1.0,
      !                             the right-hand end of the string will be placed at
      !                             at COORD. Other values between 0 and 1 give inter-
      !                             mediate placing, but they are not very useful.
      !           TEXT           :  the text string to be plotted. Trailing spaces are
      !                             ignored when justifying the string, but leading
      !                             spaces are significant.

         annotation1_ci = 1 ! color index
         annotation1_ch = 0.7 ! character height
         annotation1_lw = 1 ! line width
         annotation1_cf = 1 ! character font (1=sans serif, 2=roman, 3=italic, 4=script)
         annotation1_side = 'B'
         annotation1_disp = 5.2
         annotation1_coord = 1.1
         annotation1_fjust = 1.0
         annotation1_text = 'MESA/STAR'
      
         annotation2_ci = 1
         annotation2_ch = 0.7 !1.125
         annotation2_lw = 1
         annotation2_cf = 3
         annotation2_side = 'B'
         annotation2_disp = 5.2
         annotation2_coord = -0.1
         annotation2_fjust = 0
         annotation2_text = 'Bill Paxton'
      
         annotation3_side = 'T'
         annotation3_disp = 0
         annotation3_coord = 0
         annotation3_fjust = 0.0
         annotation3_text = ''

      ! the extra's work the same as for the star controls


         read_extra_pgstar_inlist1 = .false.
         extra_pgstar_inlist1_name = 'undefined'
         ! if read_extra_pgstar_inlist1 is true, then read &pgstar from this namelist file

         read_extra_pgstar_inlist2 = .false.
         extra_pgstar_inlist2_name = 'undefined'
         ! if read_extra_pgstar_inlist2 is true, then read &pgstar from this namelist file

         read_extra_pgstar_inlist3 = .false.
         extra_pgstar_inlist3_name = 'undefined'
         ! if read_extra_pgstar_inlist3 is true, then read &pgstar from this namelist file

         read_extra_pgstar_inlist4 = .false.
         extra_pgstar_inlist4_name = 'undefined'
         ! if read_extra_pgstar_inlist4 is true, then read &pgstar from this namelist file

         read_extra_pgstar_inlist5 = .false.
         extra_pgstar_inlist5_name = 'undefined'
         ! if read_extra_pgstar_inlist5 is true, then read &pgstar from this namelist file


/ ! end of pgstar namelist
