Ticket #7653 (closed: fixed)

Opened 7 years ago

Last modified 5 years ago

Implement function "neutron back-to-back exponential convoluted with pseudo-voigt"

Reported by: Wenduo Zhou Owned by: Wenduo Zhou
Priority: major Milestone: Release 3.0
Component: Framework Keywords:
Cc: petersonpf@… Blocked By:
Blocking: Tester: Vickie Lynch

Description (last modified by Wenduo Zhou) (diff)

It is GSAS's neutron function number 3 and Fullprof's number 9 peak profile. It should inherit IPowderDiffractionFunction?.

Attachments

arg_si_111.dat (1.9 KB) - added by Wenduo Zhou 7 years ago.

Change History

comment:1 Changed 7 years ago by Wenduo Zhou

  • Status changed from new to inprogress

comment:2 Changed 7 years ago by Wenduo Zhou

Added class NeutronBk2BkExpConvPVoigt. Refs #7653.

Changeset: 983784191b4d19487e5094b1b2f07ce6222d3232

comment:3 Changed 7 years ago by Wenduo Zhou

Refactor codes. Refs #7653.

Moved some methods belonged to ThermalNeutronBk2BkExpConvPVoigt to IPowderDiffPeakFunction because they are used by NeutronBk2BkExpConvPVoigt, too.

Changeset: b3f4eabf5bd8b5197e9d348574a4556828a63a87

comment:4 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: 42c72e80b5127dcd2183748b1381e996dce89cfd

comment:5 Changed 7 years ago by Wenduo Zhou

  • Description modified (diff)

comment:6 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: 4e3ab2ecb13cd080b33cc51c14572fb334305534

comment:7 Changed 7 years ago by Wenduo Zhou

Moved some common function to interface. Refs #7653.

Changeset: 79e491630a8039ea4e22856b89a6248263c6325d

comment:8 Changed 7 years ago by Wenduo Zhou

Complete coding (almost). Refs #7653.

Changeset: 1fe695fb6b10b6b31da3a9a8704804ff9ddfdaae

comment:9 Changed 7 years ago by Wenduo Zhou

Refactor E1() to interface. Refs #7653.

Changeset: 180ecf20970cb8afc7c514dd4f41261702e02e2a

comment:10 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: 1342c4640898e3296231e662ffbdb27d0aa97db6

comment:11 Changed 7 years ago by Wenduo Zhou

Fixed a bug during testing this ticket. Refs #7653.

Changeset: 89777fb61dfc0fd20df953805f74feee165231b9

comment:12 Changed 7 years ago by Wenduo Zhou

Added some unit test (incomplete). Refs #7653.

Changeset: ad7a75f0529bebcfd4b8d3f38512353bbe8ef2ea

comment:13 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: 4b9e26ce1a36a89c39c2d28e96e7f4261d05756c

comment:14 Changed 7 years ago by Wenduo Zhou

Added some unit tests. Refs #7653.

Changeset: 340b00a95e755b6fe8f23722c79c6bca653ea9da

comment:15 Changed 7 years ago by Wenduo Zhou

Tried to fix windows build. Refs #7653.

Changeset: f496e9e074981ab71c82c02a0524b90badd84335

comment:16 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: 05bedc78a764c8aec64486ab37136636c621a30b

comment:17 Changed 7 years ago by Wenduo Zhou

Checkpointing work. Refs #7653.

Changeset: b5e63499944ff6e2d95641cbcd5386802a9db39b

comment:18 Changed 7 years ago by Wenduo Zhou

Checkpointing work (1113). Refs #7653.

Changeset: 830ec7b9df71b931bbf986f8c1a283f07e64d972

comment:19 Changed 7 years ago by Wenduo Zhou

Completed unit test. Refs #7653.

Changeset: d3de072dd20394ca0ba00fb667bc617f976c6958

comment:20 Changed 7 years ago by Wenduo Zhou

  • Status changed from inprogress to verify
  • Resolution set to fixed

comment:21 Changed 7 years ago by Anders Markvardsen

  • Status changed from verify to verifying
  • Tester set to Anders Markvardsen

comment:22 Changed 7 years ago by Anders Markvardsen

  • Status changed from verifying to reopened
  • Resolution fixed deleted

I tried to do the following

  1. Open MantidPlot and plot a spectrum
  1. activate the fitting. However to my surprised when right clicking on the plot fit window your function does not shown up as peak

At least users at isis, who uses mantidplot for fitting will for this reason not realise that your new function exit and also with not have the graphical tools activated to adjust such a peak.

Looked at code notice IPowderDiffPeakFunction is not inherenting from IPeakFunction, although looking briefly the method required to satisfy this interface seems to be implemented in IPowderDiffPeakFunction

Also as include this peak in the 'Peak' category

comment:23 Changed 7 years ago by Wenduo Zhou

  • Status changed from reopened to verify
  • Resolution set to fixed

IPowderDiffPeakFunction is an interface class for powder diffraction peaks in Le Bail fit and Rietveld refinement. So far, NeutronBk2BkExpConvPVoigt and ThermalNeutronBk2BkExpConvPVoigt are the only 2 types of powder diffraction peaks inheriting this interface. They are used in powder diffraction analysis, but not designed for the purpose to do single peak fitting. Therefore, they do not inherit interface IPeakFunction.

NeutronBk2BkExpConvPVoigt and ThermalNeutronBk2BkExpConvPVoigt are back-to-back exponential peak functions. But the parameters of them are used to construct functions to calculate back-to-back exponential peak function parameters centered at different d-space. Therefore, it is not practical neither to plot the function nor to fit the peak function in MantidPlot's Fit interface.

There was a discussion about this when I implemented ThermalNeutronBk2BkExpConvPVoigt. And the current implementation follows the conclusion of that discussion.

comment:24 Changed 7 years ago by Wenduo Zhou

  • Status changed from verify to reopened
  • Resolution fixed deleted
  1. Make (H, K, L) as 3 additional peak parameters;
  2. Override unfix() such that H, K, L cannot be fitted;

comment:25 Changed 7 years ago by Wenduo Zhou

  • Status changed from reopened to inprogress

Added HKL to function parameters. Refs #7653.

Changeset: a93c307825f5cb8d1c58a0f765a530d0349c0dd5

comment:26 Changed 7 years ago by Wenduo Zhou

  • Status changed from inprogress to verify
  • Resolution set to fixed

How to verify

  1. Download attached arg_si_111.dat;
  2. In MantidPlot, load this data file;
  3. Launch Fit interface on the plot of arg_si_111.dat;
  4. Add function 'NeutronBk2BkExpConvPVoigt'. Set the parameters as Height = 1.436480e+06 Dtt1 = 7476.910000 Dtt2 = -1.540000 Zero = -9.227000 Alph0 = 0.0 Alph1 = 0.597100 Beta0 = 0.042210 Beta1 = 0.009460 Sig0 = 1.741260 Sig1 = 5.746910 Sig2 = 0.0 Gam0 = Gam1 = Gam2 = 0.0 Lattice = 5.431360 H = K = L = 1
  5. Do evaluation to this function. You can see the model is close to data.

Changed 7 years ago by Wenduo Zhou

comment:27 Changed 7 years ago by Vickie Lynch

  • Status changed from verify to verifying
  • Tester changed from Anders Markvardsen to Vickie Lynch

comment:28 Changed 7 years ago by Vickie Lynch

  • Status changed from verifying to closed

Merge remote branch 'origin/feature/7653_add_fp_peak9'

comment:29 Changed 7 years ago by Nick Draper

  • Component changed from Framework to Diffraction

comment:30 Changed 7 years ago by Nick Draper

  • Component changed from Diffraction to Framework

comment:31 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 8498

Note: See TracTickets for help on using tickets.