{"action":"created","issue":{"url":"https://api.github.com/repos/mit-crpg/openmc/issues/470","labels_url":"https://api.github.com/repos/mit-crpg/openmc/issues/470/labels{/name}","comments_url":"https://api.github.com/repos/mit-crpg/openmc/issues/470/comments","events_url":"https://api.github.com/repos/mit-crpg/openmc/issues/470/events","html_url":"https://github.com/mit-crpg/openmc/pull/470","id":109627325,"number":470,"title":"Addition of angle-related filters: polar, azimuthal, and mu","user":{"login":"nelsonag","id":1037107,"avatar_url":"https://avatars.githubusercontent.com/u/1037107?v=3","gravatar_id":"","url":"https://api.github.com/users/nelsonag","html_url":"https://github.com/nelsonag","followers_url":"https://api.github.com/users/nelsonag/followers","following_url":"https://api.github.com/users/nelsonag/following{/other_user}","gists_url":"https://api.github.com/users/nelsonag/gists{/gist_id}","starred_url":"https://api.github.com/users/nelsonag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nelsonag/subscriptions","organizations_url":"https://api.github.com/users/nelsonag/orgs","repos_url":"https://api.github.com/users/nelsonag/repos","events_url":"https://api.github.com/users/nelsonag/events{/privacy}","received_events_url":"https://api.github.com/users/nelsonag/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-03T15:21:32Z","updated_at":"2015-10-03T15:31:41Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/mit-crpg/openmc/pulls/470","html_url":"https://github.com/mit-crpg/openmc/pull/470","diff_url":"https://github.com/mit-crpg/openmc/pull/470.diff","patch_url":"https://github.com/mit-crpg/openmc/pull/470.patch"},"body":"This PR adds filters for polar and azimuthal angles as well as scattering cosines, mu.\r\n\r\nThe changes to incorporate these new filters were pretty simple.  I have tested these with some small problems and even used these filters to generate angle-based cross sections which reproduce the OpenMC solution the best out of all possibilities, leading to confidence in this coding.\r\n\r\nThe new filters (\"mu\", \"polar\", and \"azimuthal\") can be used just like the \"energy\" and \"energyout\" filters, where the bins can be used to input in the explicit boundaries you want.  However, since normally I expect you would want data from these three filters data over equi-width bins, I also added functionality where if the user enters a single number for bins, then that number means how many bins to subdivide the region in to.  For exapmle, if you want two mu bins, you can either input:\r\n```\r\n<filter>\r\n  <type>mu</type>\r\n  <bins> -1.0 0.0 1.0 </bins>\r\n</filter>\r\n```\r\nOR\r\n```\r\n<filter>\r\n  <type>mu</type>\r\n  <bins> 2 </bins>\r\n</filter>\r\n```\r\nDocs have been updated, and tests added/updated (though I will need to update the tests after incorporation of #469 since that looks like it is close to completing its review).\r\n\r\nFinally, when testing this capability, I discovered that the spherical harmonics within math.F90 (which I put in there) were inconsistent at best with Scipy's scipy.special.lpmv (associated legendres) by a factor of (-1)^m.  This has been fixed as well."},"comment":{"url":"https://api.github.com/repos/mit-crpg/openmc/issues/comments/145256762","html_url":"https://github.com/mit-crpg/openmc/pull/470#issuecomment-145256762","issue_url":"https://api.github.com/repos/mit-crpg/openmc/issues/470","id":145256762,"user":{"login":"nelsonag","id":1037107,"avatar_url":"https://avatars.githubusercontent.com/u/1037107?v=3","gravatar_id":"","url":"https://api.github.com/users/nelsonag","html_url":"https://github.com/nelsonag","followers_url":"https://api.github.com/users/nelsonag/followers","following_url":"https://api.github.com/users/nelsonag/following{/other_user}","gists_url":"https://api.github.com/users/nelsonag/gists{/gist_id}","starred_url":"https://api.github.com/users/nelsonag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nelsonag/subscriptions","organizations_url":"https://api.github.com/users/nelsonag/orgs","repos_url":"https://api.github.com/users/nelsonag/repos","events_url":"https://api.github.com/users/nelsonag/events{/privacy}","received_events_url":"https://api.github.com/users/nelsonag/received_events","type":"User","site_admin":false},"created_at":"2015-10-03T15:31:41Z","updated_at":"2015-10-03T15:31:41Z","body":"Wait... Wasnt there an issue associated with angle tally filters? I'm on my phone now but can't seem to find it."}}