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

Bug in CalculateCoverageDGS #15182

Closed
AndreiSavici opened this issue Feb 4, 2016 · 0 comments
Closed

Bug in CalculateCoverageDGS #15182

AndreiSavici opened this issue Feb 4, 2016 · 0 comments
Assignees
Labels
Bug Issues and pull requests that are regressions or would be considered a bug by users (e.g. crashing) Direct Inelastic Issues and pull requests related to direct inelastic High Priority An issue or pull request that if not addressed is severe enough to postponse a release.
Milestone

Comments

@AndreiSavici
Copy link
Member

There is a problem when using the planning tool for direct geometry inelastic. In particular, the trajectories do not correspond to results from ConvertToMD if one uses projections
Here is the results from ConvertToMD
cncs-cmd
The script to generate it is:

Load(Filename='CNCS_7860_event.nxs', OutputWorkspace='CNCS_7860_event')
ConvertUnits(InputWorkspace='CNCS_7860_event', OutputWorkspace='CNCS_7860_event', Target='DeltaE', EMode='Direct', EFixed=3)
SetUB(Workspace='CNCS_7860_event', a=10, b=10, c=10)
SetGoniometer(Workspace='CNCS_7860_event', Axis0='30,0,1,0,1')
ConvertToMD(InputWorkspace='CNCS_7860_event', QDimensions='Q3D', Q3DFrames='HKL', QConversionScales='HKL', Uproj='1,1,0', Vproj='1,-1,0', Wproj='0,0,1', OutputWorkspace='md', MinValues='-4,-4,-4,-4', MaxValues='4,4,4,4')
BinMD(InputWorkspace='md', AxisAligned=False, BasisVector0='[H,H,0],in 0.889 A^-1,1,0,0,0', BasisVector1='[H,-H,0],in 0.889 A^-1,0,1,0,0', BasisVector2='[0,0,L],in 0.628 A^-1,0,0,1,0', BasisVector3='DeltaE,DeltaE,0,0,0,1', OutputExtents='-2.4,2.4,-0.8,4,-0.1,0.1,-0.1,0.1', OutputBins='100,100,1,1', Parallel=True, OutputWorkspace='md_rebinned')

When using the planning tool, one can use the projection u to be (1,1,0), projection v (1,-1,0)
cncs
One can also reverse the order of projections, but still plot (HH0) along x, and (H,-H,0) along y. I would expect the same result. But what I get is
cncs-reverse-order

I tracked down the issue, and is the way we store matrices. In CalculateCoverageDGS.cpp I set the rows of W matrix as the projection vectors, instead of the columns (lines 295-297)

@AndreiSavici AndreiSavici added High Priority An issue or pull request that if not addressed is severe enough to postponse a release. Bug Issues and pull requests that are regressions or would be considered a bug by users (e.g. crashing) Direct Inelastic Issues and pull requests related to direct inelastic Group: Planning Tools labels Feb 4, 2016
@AndreiSavici AndreiSavici self-assigned this Feb 4, 2016
@AndreiSavici AndreiSavici added this to the Release 3.6 milestone Feb 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Issues and pull requests that are regressions or would be considered a bug by users (e.g. crashing) Direct Inelastic Issues and pull requests related to direct inelastic High Priority An issue or pull request that if not addressed is severe enough to postponse a release.
Projects
None yet
Development

No branches or pull requests

2 participants