laserkelvin / PySpecTools

Routines for rotational spectroscopy analysis written in Python 3
MIT License
31 stars 5 forks source link

Added axis representation handling and fixed issues in Linear and SymmetricTop coding #37

Closed tjbarnum13 closed 2 years ago

tjbarnum13 commented 2 years ago

The first commit addresses Fixes 1 and 3 from Issue #36 on handling axis representations for SPCAT files. Five cases are handled:

  1. LinearMolecule and prolate SymmetricTop assigned representation "Ir" (SPCAT coding requirement)
  2. oblate SymmetricTop assigned representation "IIIl" (SPCAT coding requirement)
  3. AsymmetricTop with "rep" = "Ir" or "IIIl" specified in YAML file assigned to that representation
  4. AsymmetricTop with a different "rep" value is assigned to "Ir" or "IIIl" based on the value of Ray's asymmetry parameter, implemented with kappa from pyspectools.units. If kappa>0, "IIIl" is assigned, and "Ir" otherwise.
  5. AsymmetricTop with no "rep" specified. "Ir" or "IIIl" assigned by same kappa metric.

The second commit fixes some minor issues in the coding for Linear and SymmetricTop molecules. The flag s_reduced now defaults True, so that s is called in .var file for these molecules. infer_molecule now assigns a SymmetricTop if ("A-B" and "B") or ("B-C" and "B") are present. This aligns with the current coding for SymmetricTop, which uses "A-B". "B-C" was not added to coding because it is currently unclear to me how this is distinguished from "H_K" in Pickett code (see crib sheet). Other codings of symmetric tops are possible in SPCAT.