Skip to content

Including weight function specification into ALARAJOYWrapper - #317

Open
eitan-weinstein wants to merge 2 commits into
svalinn:mainfrom
eitan-weinstein:njoy_weight_functions
Open

Including weight function specification into ALARAJOYWrapper#317
eitan-weinstein wants to merge 2 commits into
svalinn:mainfrom
eitan-weinstein:njoy_weight_functions

Conversation

@eitan-weinstein

Copy link
Copy Markdown
Contributor

Closes #312.

This PR enables ALARAJOYWrapper to process groupwise cross-sections with weight functions other than the standard Vitamin-E, that was otherwise hard-coded as a pre-set GROUPR parameter in njoy_tools. Primarily, this is accomplished by abstracting the function njoy_tools.set_group_structure() to being njoy_tools.set_modifiable_groupr_parameters(). The logic for implementing group structure vs weight function specifications is nearly identical, so I've combined both into an agnostic function wherein the respective command line argument and reference dictionaries are supplied to extract either group structure or weight function parameters. In its implementation within preprocess_fendl3.main(), this looks like:

ign, group_name, ngn, egn = njt.set_modifiable_groupr_parameters(
      args.group_structure, njt.NJOY_GROUPS
)
iwt, weight_function, _, _ = njt.set_modifiable_groupr_parameters(
      args.weight_function, njt.NJOY_WEIGHT_FUNCTIONS
)

Unlike the group structure handling, I did not include functionality for arbitrary weight function applications, even though NJOY is capable of accommodating them. My main reasoning was that I was building this new functionality specifically for the purpose of having the ability to do 1/E weighting, which is included among the built-in NJOY weight functions, so that I could have a 1:1 comparison to FISPACT-II's PREPRO-processed TENDL data. While I could conceive of a user theoretically wanting to create a fully customized weight function themselves (although Vitamin-E is still the standard FENDL weight function), the NJOY implementation is considerably more complex than for arbitrary group structures, which really only require the group bounds. Given that, it did not seem like a worthwhile way to spend my time at this point to build the most expansive arbitrary weight function capabilities, but rather to limit the scope to NJOY's built-in options, which will still allow us to make the necessary comparisons with FISPACT-II.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Create Arbitrary Weight Function Option for GROUPR

1 participant