Weighted error function ???
Called by:
- VOIGT
*** WERF by WIFD 25 May 84 ***
Classification:
Mathematical Functions . . . . . . . Utility
Performs various operations to do with weights for LSQ, either for
PR or simpler applications. applications.
Arguments:
-
On entry N=1 means find an
L WGHT card
and read from it the type of
- weighting to be used, with default = 1. ARG is irrelevant.
N=2 means from ARG, IWGHT etc make a weight to go with this OBS
N=3 means given WT, get WDIFF and SQRTWT. ARG is included for
- diagnostic purposes only, and is sometimes used as the
argument, or sometimes the observation.
Calls:
- ERRIN2
JFIX
MESS
ONCARD
Common blocks used:
-
- /IOUNIT/ to use LPT
- /OBSCAL/ to use OBS DIFF IWGH WT SQRTWT WDIFF
- /SOURCE/ to use JSOURC KSOURC
*** WGHTLS updated by JCM 23 Mar 92 ***
Classification:
General Least Squares Refinement . . . . . . . Utility
Deals with weights of LSQ observations for single crystal.
Description:
-
Puts weight of current observation into WT, its square root into SQRTWT,
and WDIFF = SQRTWT times difference, all according to IWGHT.
Calls:
- TESTOV
Called by:
- CHILSQ
MAGLSQ
MMPLSQ
MPLSQ
PALSQ
SFLSQ
SFTLSQ
Common blocks used:
-
- /OBSCAL/ to use DIFF WT SQRTWT WDIFF
*** WGHTSF argument H removed by PJB 12-July 1999 ***
Classification:
General Least Squares Refinement . . . . . . . Utility
Returns \$\exp(y^2){\textrm errf}(y)\$ for positive \$y\$
only
*** WIYPOS by WIFD 6-JUNE-84 ***
Classification:
Mathematical Functions . . . . . . . Utility
Multiple entry routine for the calculation of weighted averages.
Arguments:
-
On entry IFUN indicates which action is required:
- IFUN= 0 initialses an array SUMS for subsequent summing.
IFUN= a positive integer adds an observation X with a weight
- deduced from the value of IFUN:
IFUN=1 gives unit weights
IFUN=2 gives 1/DX squared
IFUN= a negative integer returns the mean in X, the standard
- deviation in DX, and the number of observations in
the 4th element of given array SUMS.
If an observation has zero DX, it is ignored. -ve DX is treated as +ve.
SUMS is a 1x5 array holding values for an individual set of data, so that
- several sets may be collected simultaneously.
SUMS HOLDS:
- Sum of weighted observations
Sum of weighted squares of observations
Sum of 1/DX squared
Number of observations
Denominator for mean
- If unit weights, this is the number of observations,
If 1/DX sqrd weights this is the sum of the weights
Calls:
- GMZER
Called by:
- ABSCOR
STATIS
ARRINC
ARRNGE
PATHS
INCMSF
MEANWT
SORGAM
*** WTMEAN corrected by PJB 21-Oct-97 ***
Classification:
Mathematical Functions . . . . . . . Utility
P. Jane Brown
e-mail: brown@ill.fr
Institut Laue Langevin,
Grenoble, FRANCE