Skip to content

Implement multiple options for computing muD #143

Closed
@yucongalicechen

Description

@yucongalicechen

We would like an app that reads things from the command line (or gooey), calls the functions from here, and goes on its merry way. Its tricky in gooey but we may be able to do one layer of conditional logic, to support a gooey uc like this:

  • UC3a
  1. user selects "compute muD from known density" radio button
  2. labpdfproc.mudCalc presents a form pre-filled with defaults containing fields for user to enter mass density in g/cm^3, composition (e.g. ZrO2), wavelength(angstroms), D (mm). Defaults are <Till's zirconia number>, , , 1.
  3. user enters the other info (browses for files etc.)
  4. user hits start
  5. code runs.
  • UC3b - user has muD
  1. user selects "enter muD manually"
  2. mudCalc presents a box to type in a float "muD value"
  3. as UC3a 3-end
  • UC3c - user doesn't know density
  1. user selects "estimate muD from composition"
  2. labpdfproc.mudCalc presents a form pre-filled with defaults containing fields for user to enter powder fraction (number between 0 and 1), composition (e.g. ZrO2), wavelength(angstroms), D (mm). Defaults are 0.5, , , 1. program assumes some reasonable atomic number density by default, since this is not known or given in principle.
  3. as UC3a 3-end
  • UC4
  1. as UC3a.1-2
  2. user clicks run calc
  3. lpp.mudCalc returns the calculated value as output without running the cve calc.

Implementationally, one way to handle 3a-c in lpp might be that it is not conditional but depending on which fields are filled vs empty different logic is run. It means that some defaults would have to be None.

See more dicussions in diffpy/diffpy.utils#45

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions