Contents Prev Manual

LOGICAL FUNCTION LATABS(H)

Checks h,k,l for being a (nuclear) lattice absence.

Arguments:

On entry H is 1x3 real array of h,k,l
On exit LATABS = .TRUE. if h,k,l absent, .FALSE. if present

Prerequisite calls:

SYMOP should have set up the lattice information in /SYMDA, /NSYM

Notes:

Deals with non-integral h,k,l also, giving the answer "absent"

Calls:

SCALPR

Called by:

CALCFR EQRLV FMPCAL GENMUL GETGEN LFCALC LMPCAL MAGABS ICDINC CALMSF CALQSF EXTCAL GETMSF ICDINC MAGPOW POWDER CALCTW

Common blocks used:

/NSYM/ to use NLAT
/SYMDA/ to use ALAT

*** LATABS updated by PJB Sep 87 ***

Classification:

Basic Crystallography . . . . . . . Crystallographic

SUBROUTINE LATGEN(KI,K,KLIM,DONE,ISW,ISWO)

Generates points on a lattice.

Arguments:

On entry: KI(3) is the previous point generated
KLIM(3,2) gives the limits over which points should be generated
ISW is a switch indicating for which axes the a point on the upper
limit is required. The point is required for the nth axis if t nth bit is set in ISW.

On exit: K contains the next point generated.
DONE is .TRUE. if there are no more points
ISWO indicates whether the point generated is at any of the limits.
The nth bit is set if the point is at the limit for the nth axis.

Notes:

Use KLIM(1:3,1) for the first point, set KI(1:3)=KLIM(1:3,1) for the first call to LATGEN, for subsequent calls set KI=K and continue until
DONE is .TRUE.

Calls:

JGMEQ

Called by:

MAG3D MG3DGL MVENTR

*** LATGEN by PJB 23 Apr 92 ***

Classification:

Basic Crystallography . . . . . . . Crystallographic

SUBROUTINE LATVCS(STEP,AVEC,NPRIM)

Determines whether STEP defines a primitive lattice and if not
returns the non-primitive vectors.

Arguments:

On Input STEP contains 3 3-vectors which will be used to generate
points in a lattice

On exit NPRIM gives the number of lattice points in the cell defined by STEP
AVEC are the vectors joining these points to the origin

Notes:

The first entry in AVEC is always a zero vector.

Calls:

DETER3 ERRCHK FCTOR GMADD GMEQ GMREV GMSCA GMZER VECPRD

Common blocks used:

/IOUNIT/ to use LPT ITO

*** LATVCS new by PJB June 2006 C143 ***



LOGICAL FUNCTION LATVEC(X)

Tests for the presence of a lattice vector.

Arguments:

On entry X is a real 1x3 vector
On exit LATVEC is. TRUE. if X is a lattice vector, .FALSE. otherwise

Prerequisite calls:

SYMOP must have set up the lattice information in /SYMDA, /NSYM

Called by:

ATOPOS EQPPOS

*** LATVEC by PJB 5 Nov 84 ***

Classification:

Basic Crystallography . . . . . . . Crystallographic

FUNCTION LCOLPG(NAME)

Returns the number of color NAME, or 0 if NAME not in PGNAME

Calls:

ERRMES LENGT NCFIND UPONE

Called by:

INPUTM

Common blocks used:

/PGNAMS/ to use PGCOLS
/PGNUMS/ to use NPGCOL LPGCOL



LOGICAL FUNCTION LDUMMY(NN,MODE)

A dummy function to be called by APSHSF,VARSSF etc in simple
structure factor LSQ

Description:

It always returns false

Called by:

DOMAG PARSDS SFLSQ

*** LDUMMY new by PJB C105 April-2001

Classification:

Specific Least Squares Refinement . . . . . . . Setting Up

FUNCTION LENG(NTEXT,L)

Determines the length of a text string, omitting trailing spaces.

Arguments:

On entry NTEXT is an A1 character array of dimension L
On exit LEN is the number of visible characters in NTEXT

Called by:

FILPRO INCREM NOPFIL PLOTO SORGAM

*** LENG by PJB 13 Apr 85 ***

Classification:

CCSL Input/Output Routines . . . . . . . Utility

FUNCTION LENGT(CHAR)

Determines the length of a character variable, omitting the final
spaces.

Arguments:

On entry CHAR is a character variable
On exit LENGT is the number of visible characters in CHAR

Called by:

ADDSPC ARREAD ASK ATMPLT BIGCHA CDFIN CENTRE DOMAG DOMAG2 DOMPL2 ERRATM ERRCH2 ERRCHK ERRIN2 ERRMES ERRRE2 EXPAND F2NEW FILPRO INITIL INPUTN LCOLPG LERCHK LISPEC LSYMPG MESS NWINDS NWINFW NWINSF NWINT2 OTPUTI PLOTO PROPAG PSFILE RDDATA REAPOL SETFOR SETFOU UPLOW UPONE UPPER AVEXAR D3OP99 AISPRC NCHECK INFILE GRAFIC MADUBM ATLABS POSOUT

*** LENGT by JCM 13 Nov 87 ***

Classification:

CCSL Input/Output Routines . . . . . . . Utility

LOGICAL FUNCTION LERCHK(NTYP,NVALUE,NBOUND,
NACT,MESS)

FALSE or TRUE according to whether NVALUE (possibly incremented)
is greater than NBOUND

Arguments:

On entry NTYP=type of check required:
NTYP=1 simply check NVALUE for being NOT GREATER THAN NBOUND
NTYP=2 increment NVALUE by 1, then as type 1

On entry NVALUE is the integer to be checked
NBOUND is its upper bound

On entry NACT says which action is required if the test fails:
NACT +ve means increase IERR in /CARDRC/ by 1, complain and exit
NACT -ve means complain and exit
NACT =0 means complain and stop

On entry MESS is the message specific to this error state

Description:

returns TRUE if NVALUE <= NBOUND FALSE otherwise. If FALSE
NVALUE is set back to the value it had on entry.
The error message starts " ERROR ** ", and finishes with MESS.
If NTYP=1, NVALUE is printed.

Output:

Outputs the required message on units LPT and ITO

Calls:

LENGT MESS

Called by:

INPUTM MPFORM PSICON GRAFIC INCMSF

Common blocks used:

/CARDRC/ to use IERR
/IOUNIT/ to use LPT ITO

*** LERCHK from ERRCHK by PJB 15-Nov-95 ***

Classification:

CCSL Input/Output Routines . . . . . . . Utility

FUNCTION LETTER(I)

Determines whether a character is a letter.

Arguments:

On entry I is an A1 character
On exit LETTER=0 if I is not a letter, otherwise which letter in range 1-26

Notes:

Small letters and capitals treated alike.

Called by:

BIGCHA CDFIN CDSCAN DOMAG2 DOMPL2 DOTWN2 EXPAND FINDCD GENNAM INPUTA INPUTF INPUTT IPDONE MAJUST NWINDS NWINFW NWINSF NWINT2 ONCARD RDDATA RDINTG RDREAL RDWORD SAID SAYS UPLOW UPPER

Common blocks used:

/CHARS/ to use LETUP LETLOW

*** LETTER by JCM 7 Oct 83 ***

Classification:

CCSL Input/Output Routines . . . . . . . Utility

SUBROUTINE LFCALC(H)

Calculates a nuclear structure factor and its derivatives.

Arguments:

On entry H is a 1x3 array containing h,k,l

Prerequisite calls:

RECIP, SYMOP, SETANI, and SETFOR must have been obeyed to set up the structure factor calculations. (These are contained in SETFC).
The LSQ environment must have been set up by a suitable MAIN program (like
SFLSQ) which has called LSETUP and VARMAK.

Description:

On exit in /FCAL/
FC is the complex structure factor
FCMOD is its modulus
COSAL is the cosine of its phase
SINAL is the sine of its phase
FCDERS is an array of derivatives of FCMOD wrt all family 2 (structure
parameters. These are NOT multiplied or divided by anything else; compare LMCALC

The above will all be zero if h,k,l gives a lattice absence; note that such would not be true of FCALC, the similar routine which does not cater for LSQ

Calls:

ANITF CGMZER FORMFA GMZER LATABS ROTSYM SCALPR TESTOV

Called by:

CALCGR CHILSQ MAGLSQ MMPLSQ PALSQ SFLSQ SFTLSQ

Common blocks used:

/ANISO/ to use KATF IAPT
/BRAGG/ to use STHL SSQRD
/CONSTA/ to use TWOPI
/FCAL/ to use all members
/FORMDA/ to use NFORMF KCMULT
/NSYM/ to use NOPC CENTRC
/PHASE/ to use JPHASE
/POSNS/ to use NATOM KX AMULT TF KTF SITE KSITE
/PRBLEM/ to use LVFST1 NVARF
/SYMDA/ to use TRANS

*** LFCALC updated by JCM 22 Sep 87 ***

Classification:

General Least Squares Refinement . . . . . . . Crystallographic

FUNCTION LISPEC(PATHIN,ICYC,NUMOR,TEXT,ITEXT,
IPARS,NINTS,FPARS,NREALS,SCAN,NSPTS)

Reads files from the ILL data base

Calls:

CLOFIL EXPAND LENGT NOPFIL

Called by:

MADUBM

Common blocks used:

/SCRACH/ to use MESSAG

*** Updated by PJB 27-Aug-1998 ***

Classification:

Data Collection and Reduction . . . . . . . Utility

SUBROUTINE LLSCAL(N)

Multiple entry routine which deals with scale factors in Least
Squares.

Arguments:

On entry, N indicates the required action:
N=0 deals with the introduction of a single scale factor with the value 1,
to be refined, when no L SCAL cards are given.

N=1 reads in an L SCAL card and records the scale factors from it.
N=2 is not assigned.
N=3 applies a shift to a specific SCALE(ISPC), with ISPC in /NEWOLD/.
N=4 writes out a new L SCAL card to unit NEWIN.

Entries:

LSCAL8 called by: VARSMG VARSSF
LSCAL9 called by: VARSMG VARSSF

Calls:

ADJUST ERRCHK MESS PRILIS RDNUMS

Called by:

APSHSF INPLSF NWINSF STLSSF

Common blocks used:

/CARDRC/ to use IERR
/IOUNIT/ to use LPT ITO
/NEWOLD/ to use ISPC NEWIN
/SCLDAT/ to use NSCALE SCALE KSCALE NSCL LSCD

*** LLSCAL updated by JCM 10 Feb 87 ***

Classification:

General Least Squares Refinement . . . . . . . Setting Up

SUBROUTINE LLTFAC(N)

Multiple entry routine which deals with overall isotropic
temperature factors in Least Squares.

Arguments:

On entry N indicates the action required:
N=1 reads in L TFAC card and stores value of overall isotropic
temperature factor in TFAC.

N=2 is not assigned.
N=3 applies a shift to TFAC.
N=4 writes out a new L TFAC card .
N=5 deals with the default if no L TFAC card is given.
N=6 fixes a zero TFAC which is implied by the absence of an L TFAC card .
ENTRY LTFAC8(NV) sets KTFAC to indicate TFAC is variable number NV
ENTRY LTFAC9 sets KTFAC to indicate TFAC fixed

Entries:

LTFAC8 called by: VARSMG VARSSF
LTFAC9 called by: VARSMG VARSSF

Calls:

ADJUST MESS RDREAL

Called by:

APSHSF INPLSF NWINSF PARSSF STLSSF

Common blocks used:

/IOUNIT/ to use LPT
/NEWOLD/ to use IGEN ISPC NEWIN
/OVER/ to use NTFAC
/PHASE/ to use JPHASE

*** LLTFAC updated JCM 13 Jan 88 ***

Classification:

General Least Squares Refinement . . . . . . . Setting Up

FUNCTION LMAGPR(IP,IM,IR)

Gives the fix/vary information for one of the family 2 parameters
for magnetic atoms.

Arguments:

On entry IP = which species required, in the range 1-22
IM = which magnetic atom (if IP > 12)
IR = which atom

On exit LMAGPR = 0 if the parameter is fixed
= which variable it is if it is varied.

Description:

This function is necessary now we hold the fix/vary information with the parameter (e.g. KX with X, KATF with ATF) instead of in a single array regardless of the physical meaning of the parameter.

Notes:

One could use this for non-magnetic applications, if IP =< 12

Called by:

LMCALC LMMPCA

Common blocks used:

/ANISO/ to use KATF IAPT
/POSNS/ to use KX KTF KSITE
/MAGDAT/ to use KANGM KSMOD KPHIH

*** LMAGPR by JCM 29 May 92 ***

Classification:

Magnetic Structure Factors . . . . . . . Crystallographic

FUNCTION LMATCH(LABEL,NAMTAB,NUM,NBOUND)

Matches an A4 item in given table, adding it if it is not there
already.

Arguments:

On entry LABEL is the A4 item to be matched
NAMTAB is the A4 array in which to search (and add)
NUM is the number of entries so far (0 is allowed)
NBOUND is the dimension of NAMTAB

On exit LMATCH is set to the address of LABEL in NAMTAB
NUM is increased by 1 if an entry is added.

Output:

Writes an error message if the table becomes overfull.

Calls:

NCFIND

Called by:

ATOPOS INPUTQ SETFOR

Common blocks used:

/IOUNIT/ to use LPT ITO

*** LMATCH updated by JCM 23 Sep 86 ***

Classification:

Tests . . . . . . . Utility

SUBROUTINE LMCALC(H)

Calculates a magnetic structure factor and its derivatives.

Arguments:

On entry H is the 1x3 vector containing h,k,l

Prerequisite calls:

RECIP, SYMOP, SETANI, SETFOR and DOMAG must have been obeyed to set up the structure factor calculation. (They are all called by SETFCM)
The LSQ environment must have been set up by a suitable MAIN program (like
SFLSQ) which has called LSETUP and VARMAK.

Description:

On exit, in /MCAL/:
FMCMOD = modulus of FMC
FMCSQR = squared modulus of FMC
FMCDER is an array containing the derivatives of FMCMOD wrt the family
2 (structure) parameters, ALL MULTIPLIED BY FMCMOD.
(Note the difference from the specification of LFCALC's derivatives)

On exit, in /QCAL/:
Q is an array containing the magnetic interaction vectors for each domain
in general there will be NDOM*KCENT domains

On exit, in /QCALD/:
FQCDER is an array containing the derivatives of the Q's with respect to
all the family 2 parameters.

All the above will be zero if h,k,l is a magnetic absence

Notes:

Note the existence also of LFCALC (nuclear structure factors for LSQ)
FMCALC (magnetic structure factors)
FCALC (nuclear structure factors)

Calls:

ANITF C1MSCA CGMADD CGMEQ CGMSCA CGMSUB CGMZER CMRSCA FORMFA GMREV GMZER LMAGPR MAGABS MAGDOM RADIAN RCMPRD ROTOSM ROTSYM RSCALP SCALPR VCTMOD ROTMAG CROTO

Called by:

MAGLSQ PALSQ

Common blocks used:

/ANISO/ to use KATF IAPT
/BRAGG/ to use STHL SSQRD
/CONSTA/ to use TWOPI VALMUB
/IOUNIT/ to use LPT IOUT
/MAGDAT/ to use NMAG JMAGAT NMFORM KANGM SMOD KSMOD PHIH KPHIH LPHI FCENT IPTAB SPIND
/MCAL/ to use all members
/NSYM/ to use NOPC CENTRC
/PHASE/ to use JPHASE
/POSNS/ to use KX AMULT TF KTF SITE KSITE
/PRBLEM/ to use LVFST1 NVARF
/QCALD/ to use all members
/SATELL/ to use KSTAB IPROP FKSTAR
/SYMDA/ to use TRANS
/SYMMAG/ to use MSTAB OTRSYM FERO FERA HELI MODUL
/SYMTAB/ to use MULTAB

*** LMCALC Updated for PSI's C141 March 2006 ***

Classification:

Magnetic Structure Factors . . . . . . . Crystallographic

SUBROUTINE LMMPCA(H)

Calculates magnetic structure factor and its derivatives using
multipole description of the form factors.

Arguments:

On entry H is the 1x3 vector containing h,k,l

Prerequisite calls:

RECIP, SYMOP, SETANI, SETFOR and DOMAG must have been obeyed to set up the structure factor calculation. (They are all called by SETFCM)
The LSQ environment must have been set up by a suitable MAIN program (like
MPLSQ) which has called LSETUP and VARMAK.

Description:

On exit, in /MCAL/:
FMCMOD = modulus of FMC
FMCSQR = squared modulus of FMC
FMCDER is an array containing the derivatives of FMCMOD wrt the family
2 (structure) and family 5 (multipole) parameters, ALL
MULTIPLIED BY FMCMOD.
(Note the difference from the specification of LFCALC's derivatives)
FVCDER is an array containing the derivatives of FMC with respect to
all the family 2 parameters.

On exit, in /QCAL/:
Q is an array containing the magnetic interaction vectors for each domain
in general there will be NDOM*KCENT domains

On exit, in /QCALD/:
FQCDER is an array containing the derivatives of the Q's with respect to
all the family 2 parameters.

All the above will be zero if h,k,l is a magnetic absence

Notes:

Note the existence also of LFCALC (nuclear structure factors for LSQ)
FMCALC (magnetic structure factors)
FCALC (nuclear structure factors)
LMCALC (magnetic structure factors for LSQ)

Calls:

ANITF C1MSCA CGMADD CGMEQ CGMSCA CGMSUB CGMZER CMCONJ CMRSCA FORMFA FORMFC GMREV GMZER LMAGPR MAGABS MAGDOM PFORMF RADIAN RCMPRD ROTOSM ROTSYM RSCALP SCALPR VCTMOD ROTMAG CROTO

Called by:

MMPLSQ

Common blocks used:

/ANISO/ to use KATF IAPT
/BRAGG/ to use STHL SSQRD
/CONSTA/ to use TWOPI FOURPI VALMUB
/FORMDA/ to use KCMULT
/IOUNIT/ to use LPT IOUT
/MAGDAT/ to use NMAG JMAGAT NMFORM KANGM SMOD KSMOD PHIH KPHIH LPHI FCENT IPTAB SPIND
/MCAL/ to use all members
/MPODA/ to use MPNMTB MPTAB MP KPOLMP
/NSYM/ to use NOPC CENTRC
/POLFOR/ to use MPFOR MPLFOR
/POSNS/ to use KX AMULT TF KTF SITE KSITE
/PRBLEM/ to use LVFST1 NVARF
/QCALD/ to use all members
/SATELL/ to use KSTAB IPROP FKSTAR
/SYMDA/ to use TRANS
/SYMMAG/ to use MSTAB OTRSYM FERO FERA HELI MODUL
/SYMTAB/ to use MULTAB

*** LMMPCA updated by PJB C128 Feb 2004***

Classification:

Multipole Form Factors . . . . . . . Crystallographic

SUBROUTINE LMPCAL(H)

Calculates a structure factor and its derivatives using a
multipole description of the form factors.

Arguments:

On entry H is a 1x3 array containing h,k,l

Description:

On exit in /FCAL/
FC is the complex structure factor
FCMOD is its modulus
COSAL is the cosine of its phase
SINAL is the sine of its phase
FCDERS is an array of derivatives of FCMOD wrt all family 2 (structure
parameters and family 5 (multipole). These are NOT multiplied or divided by anything else; compare LMCALC

The above will all be zero if h,k,l gives a lattice absence; note that such would not be true of FCALC

Calls:

ANITF CGMZER FORMFA FORMFC GMZER LATABS PFORMF ROTSYM SCALPR TESTOV VCTMOD

Called by:

CALCMP MPLSQ

Common blocks used:

/ANISO/ to use KATF IAPT
/BRAGG/ to use STHL SSQRD
/CONSTA/ to use TWOPI FOURPI
/FCAL/ to use all members
/FORMDA/ to use NFORMF KCMULT
/MPODA/ to use MPNMTB MPTAB MP KPOLMP
/NSYM/ to use NOPC CENTRC
/POLFOR/ to use MPFOR MPLFOR
/POSNS/ to use NATOM KX AMULT TF KTF SITE KSITE
/PRBLEM/ to use LVFST1 NVARF
/SYMDA/ to use TRANS

*** LMPCAL updated by PJB C128 Feb 2004 ***

Classification:

Specific Least Squares Refinement . . . . . . . Crystallographic

SUBROUTINE LOCBIT(I,J,NR,NC,ISIDE,M,N)

A specialist routine for contour plotting, which finds the "next"
bit in the bit-map, removes it, and indicates where on the picture it was.

Arguments:

On entry I=which bit within a word in the bit-map,
J=which word in the bit-map
M,N give the size of the bit-map

On exit ISIDE=1,2,3 or 4 to indicate side of picture,
NR,NC are set to indicate the top left of the relevant square.

Prerequisite calls:

The bit-map must be set up in IBIT in /BITMAP/
NBITS must be set up as at most the number of bits in an integer.

Description:

Finds whether the indicated bit is 0 or 1, and in any case removes it.

Calls:

LOGAND

Called by:

PLOTCT

Common blocks used:

/BITMAP/ to use all members
/IOUNIT/ to use LPT ITO
/LENINT/ to use all members

*** LOCBIT by JCM 24 Nov 83 ***

Classification:

Logical Operations . . . . . . . Utility

FUNCTION LOGAND(I,J)

Performs logical "and" on 2 whole integers.

Arguments:

On entry I and J are the integers whose "and" is wanted.
On exit LOGAND is I and J, taken bit by bit.

Description:

Takes the logical "and" of all of the bits in I and J, except the sign digit, relying on the value of NBITS in /LENINT/ being set to one fewer than the number of bits in an integer (at most). NBITS is set in INITIL as a machine specific quantity.

Notes:

This is now part of standard FORTRAN

Called by:

BITSET LOCBIT

Common blocks used:

/IOUNIT/ to use LPT ITO
/LENINT/ to use all members

*** LOGAND IN FORTRAN by JCM 10 Oct 83 ***

Classification:

Logical Operations . . . . . . . Utility

SUBROUTINE LOGMAG

Sets mnemonic logicals from the type of magnetic structure.

Arguments:

On entry MTYP gives the type of structure, usually read from a Q STYP
card.

Description:

Complains and stops if MTYP is not between 1 and 5.
Sets only one of FERO, FERA, HELI, AMOD and ANTI to be TRUE and the rest to be FALSE. Sets MODUL to be TRUE if either HELI or AMOD.

Calls:

ERRMES

Called by:

DOMAG DOMAG1 MAGLSQ MMPLSQ PALSQ

Common blocks used:

/SYMMAG/ to use MTYP FERO FERA HELI AMOD ANTI MODUL

*** LOGMAG by JCM 27 Aug 91 ***

Classification:

Magnetic Structure Factors . . . . . . . Setting Up

FUNCTION LOGOR(I,J)

Performs logical "or" on 2 whole integers.

Arguments:

On entry I and J are the integers whose "or" is wanted.
On exit LOGAND is I or J, taken bit by bit.

Description:

Takes the logical "or" of all of the bits in I and J, except the sign digit, relying on the value of NBITS in /LENINT/ being set to one fewer than the number of bits in an integer (at most). NBITS is set in INITIL as a machine specific quantity.

Notes:

This is now part of standard FORTRAN

Called by:

BITSET

Common blocks used:

/IOUNIT/ to use LPT ITO
/LENINT/ to use all members

*** LOGOR IN FORTRAN by JCM 10 Oct 83 ***

Classification:

Logical Operations . . . . . . . Utility

SUBROUTINE LSETSF(NW,LSPEC,LWORDS)

Sets up vocabulary for a specific LSQ problem involving structure
factors.

Arguments:

NW on entry is the number of words in this problem's specific vocabulary
LSPEC on entry is an array specifying the meaning of the words
with 3 integers per word - family, genus, species

LWORDS on entry is an A4 array of words in this problem's vocabulary

Prerequisite calls:

The problem must have already been specified to the extent of:
NFAM=number of families
NGENS(I)=number of genera in family I
NSPC(I)=number of species in each genus of family I

Description:

Sets up the packing of IFAM, IGEN, ISPC into one integer
Packs the LSPEC integers to 1 word
First sets up the standard Structure Factor LSQ vocabulary for family 2 parameters (and cell from family 1).
Copies both arrays LSPEC and LWORDS into standard arrays IWDSPC and
LSQWD in /WDSPEC/ and /WORDS/.

Notes:

Because of its use of the standard family 2 names and numbers, it determines these to be the same in every application (e.g. B11 is always species 4).
If this is not what is wanted, use LSETUP and give it the entire vocabulary.

Calls:

ERRCHK ERRMES F2PARP NPACK VOCAB

Called by:

CHILSQ MAGLSQ MMPLSQ SFLSQ SFTLSQ

Common blocks used:

/F2NAMS/ to use all members
/F2NUMS/ to use all members
/LINKAG/ to use NUMFV NUMPAK NUMCON KPTCON
/LSQPAK/ to use all members
/PRBLEM/ to use NFAM
/REFINE/ to use MAG
/WDSPC/ to use IWDNUM

*** LSETSF Modified by PJB May 2001 ***

Classification:

General Least Squares Refinement . . . . . . . Setting Up

SUBROUTINE LSETUP(NW,LSPEC,LWORDS)

Sets up specific LSQ problem - copies the vocabulary to standard
COMMON.

Arguments:

NW on entry is the number of words in this problem's vocabulary
LSPEC on entry is an array specifying the meaning of the words
with 3 integers per word - family, genus, species

LWORDS on entry is an A4 array of words in this problem's vocabulary

Prerequisite calls:

The problem must have already been specified to the extent of:
NFAM=number of families
NGENS(I)=number of genera in family I
NSPC(I)=number of species in each genus of family I

Description:

Packs the LSPEC integers to 1 word
Copies both arrays LSPEC and LWORDS into standard arrays IWDSPC and
LSQWD in /WDSPEC/ and /WORDS/.
Sets up the packing of IFAM, IGEN, ISPC into one integer

Calls:

ERRCHK ERRMES NPACK

Called by:

MPLSQ PALSQ

Common blocks used:

/LINKAG/ to use NUMFV NUMPAK NUMCON KPTCON
/LSQPAK/ to use all members
/PRBLEM/ to use NFAM
/WDSPC/ to use all members
/WORDS/ to use all members

*** LSETUP updated by JCM 26 Jun 89 ***

Classification:

General Least Squares Refinement . . . . . . . Setting Up

SUBROUTINE LSTCTS(C,D,TMORTS)

Calculates a dead time correction

Arguments:

On entry:
C is the uncorrected count-rate
TMORTS(1) and TMORTS(2) the constants \$t_1\$ and \$2_2\$ and
TMORTS(3) and TMORTS(4) their esd's

On exit:
C is the correction factor by which the observed count should be multiplied
D is its esd

Description:

Calculates the correction to be applied to a counting rate R due to detector non-linearity. The corrected rate \$R_c\$ is given by \$\$R_c=R/(1-rt_1-r^2t_2)\$\$

Notes:

Used by DOP97 and CRYPAD

Called by:

BPBPRC AISPRC

*** LSTCTS into Library Nov 1997 ***

Classification:

Data Collection and Reduction . . . . . . . Utility

FUNCTION LSYMPG(NAME,FILL)

Returns the symbol type as defined by KANGA3 for NAME and FILL

Calls:

ERRMES LENGT NCFIND UPONE

Called by:

INPUTM

Common blocks used:

/PGNAMS/ to use PGSYMS PGTYPS
/PGNUMS/ to use NPGSYM LPGSYM NPGTYP LPGTYP




Contents Manual

P. Jane Brown e-mail: brown@ill.fr
Institut Laue Langevin,
Grenoble, FRANCE