cloudy-astrophysics / bug-tracker-migration-test

Trial run for importing the nublado.org Trac tickets as GitHub issues
0 stars 0 forks source link

collisionsal ionization/3b recombination sink/sources to ground state of isosequences fails to produce LTE at high densities (trac #375) #377

Open cloudy-bot opened 7 years ago

cloudy-bot commented 7 years ago

reported by: @fguzmanful

The sources and sinks due to collisional ionization and three body recombination in the He iso-sequence are wrongly delivered to all excited states through a partition function. The reactions that matter are:

He(nl) + e <-> He+(1s) + 2e

where nl is any resolved state. However cloudy is delivering these populations to:

He(nl) + e -> He+(n'l') + 2e

through the partition function. The inverse reaction is duplicated for every n'l' (no partition function) :

He+(n'l') +2e -> He(nl) + e

The code that allows that possible is:

    if (0)
    {
        creation[0](../commit/0) += source;
        for( level=0; level < numlevels_local; level++ )
        {
            z[level][level] += sink;
        }
    }
    else
    {
        // Try Boltzmann weighting to capture LTE limit correctly
        t_iso_sp* sp = &iso_sp[ipISO][nelem];
        double partfun=0.0;
        for ( level = 0; level < numlevels_local; level++ )
        {
            partfun += sp->st[level].Boltzmann()*sp->st[level].g();
        }
        source /= partfun;
        for( level=0; level < numlevels_local; level++ )
        {
            creation[level] += source*
                sp->st[level].Boltzmann()*sp->st[level].g();
            z[level][level] += sink;
        }
    }

If the physics were correct, the first branch of the if clause should be allowed. However the current configuration produces correct LTE limits while the correct physics fails in producing that. This is seen in the wrong departure coefficients of He+ in the tsuite simulation limit_lte_he1_ste.in and in the modified attached sim limit_lte_he1_coll_t50k.in. It is possible that a bug in ionization-recombination balance produces this problem.

Migrated from https://www.nublado.org/ticket/375

{
    "status": "reopened",
    "changetime": "2019-02-04T12:10:21Z",
    "_ts": "1549282221449479",
    "description": "The sources and sinks due to collisional ionization and three body recombination in the He iso-sequence are wrongly delivered to all excited states through a partition function. The reactions that matter are:\n\n   He(nl) + e <-> He+(1s) + 2e\n\nwhere nl is any resolved state. However cloudy is delivering these populations to:\n\n   He(nl) + e -> He+(n'l') + 2e\n\nthrough the partition function. The inverse reaction is duplicated for every n'l' (no partition function) :\n  \n  He+(n'l') +2e -> He(nl) + e\n\nThe code that allows that possible is:\n\n\n\t\tif (0)\n\t\t{\n\t\t\tcreation[0] += source;\n\t\t\tfor( level=0; level < numlevels_local; level++ )\n\t\t\t{\n\t\t\t\tz[level][level] += sink;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// Try Boltzmann weighting to capture LTE limit correctly\n\t\t\tt_iso_sp* sp = &iso_sp[ipISO][nelem];\n\t\t\tdouble partfun=0.0;\n\t\t\tfor ( level = 0; level < numlevels_local; level++ )\n\t\t\t{\n\t\t\t\tpartfun += sp->st[level].Boltzmann()*sp->st[level].g();\n\t\t\t}\n\t\t\tsource /= partfun;\n\t\t\tfor( level=0; level < numlevels_local; level++ )\n\t\t\t{\n\t\t\t\tcreation[level] += source*\n\t\t\t\t\tsp->st[level].Boltzmann()*sp->st[level].g();\n\t\t\t\tz[level][level] += sink;\n\t\t\t}\n\t\t}\n\n\nIf the physics were correct, the first branch of the if clause should be allowed. However the current configuration produces correct LTE limits while the correct physics fails in producing that. This is seen in the wrong departure coefficients of He+ in the tsuite simulation limit_lte_he1_ste.in and in the modified attached sim limit_lte_he1_coll_t50k.in. It is possible that a bug in ionization-recombination balance produces this problem. ",
    "reporter": "fguzman",
    "cc": "",
    "resolution": "",
    "time": "2016-11-14T23:28:49Z",
    "component": "etc",
    "summary": "collisionsal ionization/3b recombination sink/sources to ground state of isosequences fails to produce LTE at high densities",
    "priority": "major",
    "keywords": "LTE, ionization",
    "version": "trunk",
    "milestone": "c19 branch",
    "owner": "nobody",
    "type": "physics"
}
cloudy-bot commented 7 years ago

output of limit_lte_he1_coll_t50 Attachment: limit_lte_he1_coll_t50.out

cloudy-bot commented 7 years ago

output of limit_lte_he1_coll_t50 without continuum lowering Attachment: limit_lte_he1_coll_t50_cloff.out

cloudy-bot commented 7 years ago

@fguzmanful commented:

If continuum lowering is disabled using the "sink/sources to the ground state" configuration, departure coefficients of ground state rise several orders of magnitude as can see in the second attachment limit_lte_he1_coll_t50_cloff.out

cloudy-bot commented 7 years ago

If you want to put the ionization only into the ground state, to maintain LTE you'd have to recombine only from the ground state, rather than all levels.

Assuming the 3-body recombination rate is independent of excitation seems a more reasonable estimate than taking the recombination rate from excited states to be zero. Thermodynamic consistency then requires partition function weighting of the collisional ionization rate source. You don't need partition function weighting on the recomination (sink) side, because you're solving for the populations, though it will appear (as it should) where the recombinations are added as a source to the populations of the lower ion.

cloudy-bot commented 7 years ago
cloudy-bot commented 7 years ago

@peter-van-hoof-noaccount changed milestone from "C17_branch" to "C19_branch"

cloudy-bot commented 7 years ago

Milestone renamed