[mesa-users] Turning off neutrino types

Josiah Schwab jwschwab at berkeley.edu
Wed Mar 20 21:50:10 EDT 2013


Hi Shane,

> From what I can tell, since the routine expects "flags" to be an
> input I can't modify it. I've tried using
> 
>          s% flags = .false.
> and
>          s% flags(pair_neu_type) = .false.
> 
> (for a single type), both of which give me errors as "flags" isn't
> recognized by the star pointer.

No, flags is not part of the star pointer, as you discovered :)

> I've also tried changing the intent of "flags" to inout at the
> beginning of the subroutine:
> 
>          logical, intent(inout) :: flags(num_neu_types)
> 
>  but this also gives an error since the intent disagrees between
> my_other_neu and other_neu. Leaving the intent(in), I get an error when I
> try to change "flags" as well.

Ah, yes.  I did not realize that flags is intent(in) in other_neu!

Bill, is there a technical reason that the other_neu routine shouldn't
modify flags?

If not, I'd actually say the easiest (or at least most flexible) thing
to do would be to edit other_neu to allow for that kind of change.  To
do that you'd need to change the intent of flags in the files

star/public/star_def.inc
star/other/other_neu.f

If that change were going to live in MESA, we'd need to update
test_suite/axion_cooling/src/run_star_extras.f

But you're right, since as is, the other_neu routine, can't touch
flags, I do think you need to edit micro.f.

> The variable is defined in micro.f, but when I changed it and ran "clean"
> and "mk" in mesa/star it didn't change the behavior of my work directory.

You'd need to ./export and then recopile (./mk) your work directory as
well.  That ought to work.

Josiah




More information about the Mesa-users mailing list