Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Distributions part 1 #6

Merged
merged 12 commits into from
Jul 26, 2024
Merged

Distributions part 1 #6

merged 12 commits into from
Jul 26, 2024

Conversation

whaeck
Copy link
Member

@whaeck whaeck commented Jul 9, 2024

This adds the TabulatedANgularDistribution object

@whaeck whaeck requested review from cjosey and nathangibson14 July 9, 2024 21:14
@whaeck whaeck marked this pull request as draft July 17, 2024 17:34
Base automatically changed from fix/review-part2 to develop July 19, 2024 16:45
Copy link

@cjosey cjosey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is currently missing the LegendreAngular stuff in Python. Rest looks good.


CHECK( InterpolationType::LinearLinear == linear.interpolants()[0] );

CHECK_THAT( -1.0 , WithinRel( linear.cosines()[0] ) );
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually went and bothered to verify this linearization. It's below 0.01 relative error, except between the last two nodes. The midpoint is below 0.01, but of course it diverges to infinity as it approaches zero. So, this works as expected.


CHECK( 3 == result.order() );
CHECK( 4 == result.coefficients().size() );
CHECK_THAT( 10.33333333333333, WithinRel( result.coefficients()[0] ) );
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would almost suggest testing these in linearized space where assumptions can be verified easier, but then it would depend on the implementation detail of linearization. But all of these look correct.

@whaeck
Copy link
Member Author

whaeck commented Jul 22, 2024

There is currently missing the LegendreAngular stuff in Python. Rest looks good.

Still working on that, but I'm almost done. I'm currently stuck since I upgraded my xcode and no longer have a compiler.

@whaeck whaeck marked this pull request as ready for review July 22, 2024 17:10
@whaeck
Copy link
Member Author

whaeck commented Jul 22, 2024

@cjosey everything is here now

@whaeck whaeck merged commit f7de505 into develop Jul 26, 2024
8 checks passed
@whaeck whaeck deleted the feature/distributions-part1 branch July 26, 2024 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants