[mesa-users] Fwd: quick question on definitions in run_star_extras.f

Bill Paxton paxton at kitp.ucsb.edu
Thu Aug 15 14:01:49 EDT 2013


Can someone help Manos?

thanks,
bill



Begin forwarded message:

> From: Manos Chatzopoulos <manolis at astro.as.utexas.edu>
> Date: August 15, 2013 10:54:04 AM PDT
> To: Bill Paxton <paxton at kitp.ucsb.edu>
> Subject: quick question on definitions in run_star_extras.f
> 
> Hi Bill,
> 
> I apologize to bother you, I am adding my own column/variable in run_star_extras.f and it looks like
> this:
> 
>      subroutine data_for_extra_profile_columns(s, id, id_extra, n, nz, names, vals, ierr)
>         type (star_info), pointer :: s
>         integer, intent(in) :: id, id_extra, n, nz
>         character (len=maxlen_profile_column_name) :: names(n)
>         real(dp) :: vals(nz,n),lnLambda
>         integer, intent(out) :: ierr
>         integer :: k
>         ierr = 0
> 
>     names(1) = 'mri_criterion'
> 
>     do k = 2,nz
>        lnLambda = log(2/(3*qe**3)*
>     +      sqrt(mp*(s% abar(k))*(kerg*(s% T(k)))**3/(pi*(s% rho(k))*
>     +      (max(1d-10,s% zbar(k)))**5)))
> 
>        vals(k,1) = 7.0d11*lnLambda/(s% T(k))**1.5d0
> 
>     enddo
> 
>     vals(1,1) = 0.
> 
> Do I have to re-define the constants (qe, pi, kerg, mp) or the code will recognize them? Or there
> is a special way I have to code them in the equation in the do-loop above? Do I also have to use
> the s% idiom like I do with the variables? (for example s% kerg) or things will work the way they are?
> 
> Thanks!
> 
> Manos
> 
> -- 
> Dr. Manos Chatzopoulos
> Department of Astronomy
> University of Texas at Austin
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.mesastar.org/pipermail/mesa-users/attachments/20130815/4fed001d/attachment.html>


More information about the Mesa-users mailing list