gpp4  1.3.1
Macros | Functions
csymlib_f.c File Reference

Fortran API for symmetry information. More...

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <math.h>
#include "ccp4_fortran.h"
#include "ccp4_general.h"
#include "ccp4_parser.h"
#include "csymlib.h"
#include "cmtzlib.h"
#include "cvecmat.h"

Macros

#define CSYMLIB_DEBUG(x)
 
#define MSPAC   4
 
#define MAXSYM   192
 
#define MAXSYMOPS   20
 
#define MAXLENSYMOPSTR   80
 

Functions

void ccp4spg_mem_tidy (void)
 
 FORTRAN_SUBR (INVSYM, invsym,(const float a[4][4], float ai[4][4]),(const float a[4][4], float ai[4][4]),(const float a[4][4], float ai[4][4]))
 
int symfr_driver (const char *line, float rot[MAXSYMOPS][4][4])
 
 FORTRAN_SUBR (SYMFR3, symfr3,(const fpstr icol, const int *i1, int *nsym, float rot[MAXSYM][4][4], int *eflag, int icol_len),(const fpstr icol, const int *i1, int *nsym, float rot[MAXSYM][4][4], int *eflag),(const fpstr icol, int icol_len, const int *i1, int *nsym, float rot[MAXSYM][4][4], int *eflag))
 
 FORTRAN_SUBR (SYMFR2, symfr2,(fpstr symchs, int *icol, int *nsym, float rot[MAXSYM][4][4], int symchs_len),(fpstr symchs, int *icol, int *nsym, float rot[MAXSYM][4][4]),(fpstr symchs, int symchs_len, int *icol, int *nsym, float rot[MAXSYM][4][4]))
 
 FORTRAN_SUBR (SYMTR3, symtr3,(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs, const int *iprint, int symchs_len),(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs, const int *iprint),(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs, int symchs_len, const int *iprint))
 
 FORTRAN_SUBR (SYMTR4, symtr4,(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs, int symchs_len),(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs),(const int *nsm, const float rsm[MAXSYM][4][4], fpstr symchs, int symchs_len))
 
 FORTRAN_SUBR (PGMDF, pgmdf,(int *jlass, int *jcentr, int jscrew[3]),(int *jlass, int *jcentr, int jscrew[3]),(int *jlass, int *jcentr, int jscrew[3]))
 
 FORTRAN_SUBR (PGDEFN, pgdefn,(fpstr nampg, int *nsymp, const int *nsym, float rsmt[192][4][4], const ftn_logical *lprint, int nampg_len),(fpstr nampg, int *nsymp, const int *nsym, float rsmt[192][4][4], const ftn_logical *lprint),(fpstr nampg, int nampg_len, int *nsymp, const int *nsym, float rsmt[192][4][4], const ftn_logical *lprint))
 
 FORTRAN_SUBR (PGNLAU, pgnlau,(const fpstr nampg, int *nlaue, fpstr launam, int nampg_len, int launam_len),(const fpstr nampg, int *nlaue, fpstr launam),(const fpstr nampg, int nampg_len, int *nlaue, fpstr launam, int launam_len))
 
 FORTRAN_SUBR (CCP4SPG_F_GET_LAUE, ccp4spg_f_get_laue,(const int *sindx, int *nlaue, fpstr launam, int launam_len),(const int *sindx, int *nlaue, fpstr launam),(const int *sindx, int *nlaue, fpstr launam, int launam_len))
 
 FORTRAN_SUBR (HKLRANGE, hklrange,(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1),(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1),(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1))
 
 FORTRAN_SUBR (PATSGP, patsgp,(const fpstr spgnam, const fpstr pgname, fpstr patnam, int *lpatsg, int spgnam_len, int pgname_len, int patnam_len),(const fpstr spgnam, const fpstr pgname, fpstr patnam, int *lpatsg),(const fpstr spgnam, int spgnam_len, const fpstr pgname, int pgname_len, fpstr patnam, int patnam_len, int *lpatsg))
 
 FORTRAN_SUBR (ASUSET, asuset,(fpstr spgnam, int *numsgp, fpstr pgname, int *msym, float rrsym[192][4][4], int *msymp, int *mlaue, ftn_logical *lprint, int spgnam_len, int pgname_len),(fpstr spgnam, int *numsgp, fpstr pgname, int *msym, float rrsym[192][4][4], int *msymp, int *mlaue, ftn_logical *lprint),(fpstr spgnam, int spgnam_len, int *numsgp, fpstr pgname, int pgname_len, int *msym, float rrsym[192][4][4], int *msymp, int *mlaue, ftn_logical *lprint))
 
 FORTRAN_SUBR (ASUSYM, asusym,(float rassym[384][4][4], float rinsym[384][4][4], int *nisym),(float rassym[384][4][4], float rinsym[384][4][4], int *nisym),(float rassym[384][4][4], float rinsym[384][4][4], int *nisym))
 
 FORTRAN_SUBR (ASUPUT, asuput,(const int ihkl[3], int jhkl[3], int *isym),(const int ihkl[3], int jhkl[3], int *isym),(const int ihkl[3], int jhkl[3], int *isym))
 
 FORTRAN_SUBR (ASUGET, asuget,(const int ihkl[3], int jhkl[3], const int *isym),(const int ihkl[3], int jhkl[3], const int *isym),(const int ihkl[3], int jhkl[3], const int *isym))
 
 FORTRAN_SUBR (ASUPHP, asuphp,(const int jhkl[3], const int *lsym, const int *isign, const float *phasin, float *phasout),(const int jhkl[3], const int *lsym, const int *isign, const float *phasin, float *phasout),(const int jhkl[3], const int *lsym, const int *isign, const float *phasin, float *phasout))
 
 FORTRAN_SUBR (CCP4SPG_F_LOAD_BY_NAME, ccp4spg_f_load_by_name,(const int *sindx, fpstr namspg, int namspg_len),(const int *sindx, fpstr namspg),(const int *sindx, fpstr namspg, int namspg_len))
 
 FORTRAN_SUBR (CCP4SPG_F_LOAD_BY_OPS, ccp4spg_f_load_by_ops,(const int *sindx, int *msym, float rrsym[192][4][4]),(const int *sindx, int *msym, float rrsym[192][4][4]),(const int *sindx, int *msym, float rrsym[192][4][4]))
 
 FORTRAN_FUN (int, CCP4SPG_F_EQUAL_OPS_ORDER, ccp4spg_f_equal_ops_order,(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4]),(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4]),(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4]))
 
 FORTRAN_SUBR (CCP4SPG_F_ASUPUT, ccp4spg_f_asuput,(const int *sindx, const int ihkl[3], int jhkl[3], int *isym),(const int *sindx, const int ihkl[3], int jhkl[3], int *isym),(const int *sindx, const int ihkl[3], int jhkl[3], int *isym))
 
 FORTRAN_FUN (int, INASU, inasu,(const int ihkl[3], const int *nlaue),(const int ihkl[3], const int *nlaue),(const int ihkl[3], const int *nlaue))
 
 FORTRAN_FUN (int, CCP4SPG_F_INASU, ccp4spg_f_inasu,(const int *sindx, const int ihkl[3]),(const int *sindx, const int ihkl[3]),(const int *sindx, const int ihkl[3]))
 
 FORTRAN_SUBR (PRTRSM, prtrsm,(const fpstr pgname, const int *nsymp, const float rsymiv[192][4][4], int pgname_len),(const fpstr pgname, const int *nsymp, const float rsymiv[192][4][4]),(const fpstr pgname, int pgname_len, const int *nsymp, const float rsymiv[192][4][4]))
 
void ccp4spg_register_by_ccp4_num (int numspg)
 
void ccp4spg_register_by_symops (int nops, float rsm[][4][4])
 
 FORTRAN_SUBR (MSYMLB3, msymlb3,(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr namspg_cifs, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4], int namspg_cif_len, int namspg_cifs_len, int nampg_len),(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr namspg_cifs, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]),(const int *ist, int *lspgrp, fpstr namspg_cif, int namspg_cif_len, fpstr namspg_cifs, int namspg_cifs_len, fpstr nampg, int nampg_len, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]))
 
 FORTRAN_SUBR (MSYMLB, msymlb,(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4], int namspg_cif_len, int nampg_len),(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]),(const int *ist, int *lspgrp, fpstr namspg_cif, int namspg_cif_len, fpstr nampg, int nampg_len, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]))
 
 FORTRAN_SUBR (MSYMLB2, msymlb2,(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4], int namspg_cif_len, int nampg_len),(const int *ist, int *lspgrp, fpstr namspg_cif, fpstr nampg, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]),(const int *ist, int *lspgrp, fpstr namspg_cif, int namspg_cif_len, fpstr nampg, int nampg_len, int *nsymp, int *nsym, float rlsymmmatrx[192][4][4]))
 
 FORTRAN_SUBR (MSYGET, msyget,(const int *ist, int *lspgrp, int *nsym, float rlsymmmatrx[192][4][4]),(const int *ist, int *lspgrp, int *nsym, float rlsymmmatrx[192][4][4]),(const int *ist, int *lspgrp, int *nsym, float rlsymmmatrx[192][4][4]))
 
 FORTRAN_SUBR (EPSLN, epsln,(const int *nsm, const int *nsmp, const float rsm[192][4][4], const int *iprint),(const int *nsm, const int *nsmp, const float rsm[192][4][4], const int *iprint),(const int *nsm, const int *nsmp, const float rsm[192][4][4], const int *iprint))
 
 FORTRAN_SUBR (EPSLON, epslon,(const int ih[3], float *epsi, int *isysab),(const int ih[3], float *epsi, int *isysab),(const int ih[3], float *epsi, int *isysab))
 
 FORTRAN_SUBR (CCP4SPG_F_EPSLON, ccp4spg_f_epslon,(const int *sindx, const int ih[3], float *epsi, int *isysab),(const int *sindx, const int ih[3], float *epsi, int *isysab),(const int *sindx, const int ih[3], float *epsi, int *isysab))
 
 FORTRAN_SUBR (SYSAB, sysab,(const int in[3], int *isysab),(const int in[3], int *isysab),(const int in[3], int *isysab))
 
 FORTRAN_SUBR (CCP4SPG_F_IS_SYSABS, ccp4spg_f_is_sysabs,(const int *sindx, const int in[3], int *isysab),(const int *sindx, const int in[3], int *isysab),(const int *sindx, const int in[3], int *isysab))
 
 FORTRAN_SUBR (CENTRIC, centric,(const int *nsm, const float rsm[192][4][4], const int *iprint),(const int *nsm, const float rsm[192][4][4], const int *iprint),(const int *nsm, const float rsm[192][4][4], const int *iprint))
 
 FORTRAN_SUBR (CENTR, centr,(const int ih[3], int *ic),(const int ih[3], int *ic),(const int ih[3], int *ic))
 
 FORTRAN_SUBR (CCP4SPG_F_IS_CENTRIC, ccp4spg_f_is_centric,(const int *sindx, const int ih[3], int *ic),(const int *sindx, const int ih[3], int *ic),(const int *sindx, const int ih[3], int *ic))
 
 FORTRAN_SUBR (CENTPHASE, centphase,(const int ih[3], float *cenphs),(const int ih[3], float *cenphs),(const int ih[3], float *cenphs))
 
 FORTRAN_SUBR (CCP4SPG_F_CENTPHASE, ccp4spg_f_centphase,(const int *sindx, const int ih[3], float *cenphs),(const int *sindx, const int ih[3], float *cenphs),(const int *sindx, const int ih[3], float *cenphs))
 
 FORTRAN_SUBR (SETLIM, setlim,(const int *lspgrp, float xyzlim[3][2]),(const int *lspgrp, float xyzlim[3][2]),(const int *lspgrp, float xyzlim[3][2]))
 
 FORTRAN_SUBR (SETLIM_ZERO, setlim_zero,(const int *lspgrp, float xyzlim[3][2]),(const int *lspgrp, float xyzlim[3][2]),(const int *lspgrp, float xyzlim[3][2]))
 
 FORTRAN_SUBR (SETGRD, setgrd,(const int *nlaue, const float *sample, const int *nxmin, const int *nymin, const int *nzmin, int *nx, int *ny, int *nz),(const int *nlaue, const float *sample, const int *nxmin, const int *nymin, const int *nzmin, int *nx, int *ny, int *nz),(const int *nlaue, const float *sample, const int *nxmin, const int *nymin, const int *nzmin, int *nx, int *ny, int *nz))
 
 FORTRAN_SUBR (FNDSMP, fndsmp,(const int *minsmp, const int *nmul, const float *sample, int *nsampl),(const int *minsmp, const int *nmul, const float *sample, int *nsampl),(const int *minsmp, const int *nmul, const float *sample, int *nsampl))
 
 FORTRAN_SUBR (CALC_ORIG_PS, calc_orig_ps,(fpstr namspg_cif, int *nsym, float rsym[192][4][4], int *norig, float orig[96][3], ftn_logical *lpaxisx, ftn_logical *lpaxisy, ftn_logical *lpaxisz, int namspg_cif_len),(fpstr namspg_cif, int *nsym, float rsym[192][4][4], int *norig, float orig[96][3], ftn_logical *lpaxisx, ftn_logical *lpaxisy, ftn_logical *lpaxisz, int namspg_cif_len),(fpstr namspg_cif, int namspg_cif_len, int *nsym, float rsym[192][4][4], int *norig, float orig[96][3], ftn_logical *lpaxisx, ftn_logical *lpaxisy, ftn_logical *lpaxisz))
 
 FORTRAN_SUBR (SETRSL, setrsl,(const float *a, const float *b, const float *c, const float *alpha, const float *beta, const float *gamma),(const float *a, const float *b, const float *c, const float *alpha, const float *beta, const float *gamma),(const float *a, const float *b, const float *c, const float *alpha, const float *beta, const float *gamma))
 
 FORTRAN_SUBR (STHLSQ1, sthlsq1,(float *reso, const int *ih, const int *ik, const int *il),(float *reso, const int *ih, const int *ik, const int *il),(float *reso, const int *ih, const int *ik, const int *il))
 
 FORTRAN_SUBR (STS3R41, sts3r41,(float *reso, const int *ih, const int *ik, const int *il),(float *reso, const int *ih, const int *ik, const int *il),(float *reso, const int *ih, const int *ik, const int *il))
 
 FORTRAN_SUBR (HANDCHANGE, handchange,(const int *lspgrp, float *cx, float *cy, float *cz),(const int *lspgrp, float *cx, float *cy, float *cz),(const int *lspgrp, float *cx, float *cy, float *cz))
 

Detailed Description

Fortran API for symmetry information.

Author
Martyn Winn

Function Documentation

void ccp4spg_mem_tidy ( void  )

Free all memory malloc'd from static pointers. To be called before program exit. The function can be registered with atexit.

References ccp4spg_free().

Referenced by ccp4f_mem_tidy().

void ccp4spg_register_by_ccp4_num ( int  numspg)

Look up spacegroup in standard setting by number and load into static storage of csymlib_f.

Parameters
numspgspacegroup number
Returns
void

References ccp4spg_free(), ccp4spg_load_by_ccp4_num(), and ccperror().

void ccp4spg_register_by_symops ( int  nops,
float  rsm[][4][4] 
)

Look up spacegroup by set of symmetry operators and load into static storage of csymlib_f.

Parameters
nopsnumber of symops
rsmsymmetry operators
Returns
void

References ccp4_spgrp_reverse_lookup(), ccp4_utils_malloc(), ccp4spg_free(), ccperror(), float_uint_uchar::i, ccp4_symop_::rot, and ccp4_symop_::trn.

Referenced by FORTRAN_SUBR().

FORTRAN_FUN ( int  ,
CCP4SPG_F_EQUAL_OPS_ORDER  ,
ccp4spg_f_equal_ops_order  ,
(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4])  ,
(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4])  ,
(int *msym1, float rrsym1[192][4][4], int *msym2, float rrsym2[192][4][4])   
)

Compare two sets of symmetry operators to see if they are in the same order. This is important for the consistent use of ISYM which encodes the operator position in the list.

Parameters
msym1number of symmetry matrices passed in first list.
rrsym1first list of symmetry matrices.
msym2number of symmetry matrices passed in second list.
rrsym2second list of symmetry matrices.
Returns
1 if operator lists are equal and in the same order, 0 otherwise

References ccp4_utils_malloc(), float_uint_uchar::i, and ccp4_symop_::trn.

FORTRAN_FUN ( int  ,
INASU  ,
inasu  ,
(const int ihkl[3], const int *nlaue)  ,
(const int ihkl[3], const int *nlaue)  ,
(const int ihkl[3], const int *nlaue)   
)

Test whether reflection or it's Friedel mate is in asu. The argument nlaue is checked against the value for the current spacegroup: if it differs then spacegroup->nlaue is updated temporarily.

Parameters
ihklreflection indices.
nlaueLaue group number.
Returns
1 if in asu, -1 if -h -k -l is in asu, 0 otherwise

References ccp4spg_is_in_pm_asu(), ccp4spg_load_laue(), and ccperror().

FORTRAN_FUN ( int  ,
CCP4SPG_F_INASU  ,
ccp4spg_f_inasu  ,
(const int *sindx, const int ihkl[3])  ,
(const int *sindx, const int ihkl[3])  ,
(const int *sindx, const int ihkl[3])   
)

Test whether reflection or it's Friedel mate is in the asymmetric unit of the spacegroup on index "sindx".

Parameters
sindxindex of this spacegroup.
ihklreflection indices.
Returns
1 if in asu, -1 if -h -k -l is in asu, 0 otherwise

References ccp4spg_is_in_pm_asu().

FORTRAN_SUBR ( SYMTR3  ,
symtr3  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs, const int *iprint, int symchs_len)  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs, const int *iprint)  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs, int symchs_len, const int *iprint)   
)

Fortran wrapper for mat4_to_symop.

Parameters
nsmnumber of symmetry matrices passed.
rsmsymmetry matrices.
symchssymmetry strings returned.
iprintprint flag.

References ccp4_CtoFString(), float_uint_uchar::i, and mat4_to_symop().

FORTRAN_SUBR ( SYMTR4  ,
symtr4  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs, int symchs_len)  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs)  ,
(const int *nsm, const float rsm[MAXSYM][4][4],fpstr symchs, int symchs_len)   
)

Fortran wrapper for mat4_to_symop.

Parameters
nsmnumber of symmetry matrices passed.
rsmsymmetry matrices.
symchssymmetry strings returned.

References ccp4_CtoFString(), float_uint_uchar::i, and mat4_to_symop().

FORTRAN_SUBR ( PGNLAU  ,
pgnlau  ,
(const fpstr nampg, int *nlaue, fpstr launam,int nampg_len, int launam_len)  ,
(const fpstr nampg, int *nlaue, fpstr launam)  ,
(const fpstr nampg, int nampg_len, int *nlaue,fpstr launam, int launam_len)   
)

Return Laue number and name for current spacegroup.

Parameters
nampgPoint group name (unused in this implementation)
nlaueLaue number
launamLaue name

References ccp4_CtoFString(), ccp4_FtoCString(), and ccp4spg_pgname_equal().

FORTRAN_SUBR ( CCP4SPG_F_GET_LAUE  ,
ccp4spg_f_get_laue  ,
(const int *sindx, int *nlaue, fpstr launam, int launam_len)  ,
(const int *sindx, int *nlaue, fpstr launam)  ,
(const int *sindx, int *nlaue, fpstr launam, int launam_len)   
)

Return Laue number and name for a spacegroup onto index "sindx".

Parameters
sindxindex of this spacegroup.
nlaueLaue number
launamLaue name

References ccp4_CtoFString(), and ccp4_spacegroup_::nlaue.

FORTRAN_SUBR ( HKLRANGE  ,
hklrange  ,
(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1)  ,
(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1)  ,
(int *ihrng0, int *ihrng1, int *ikrng0, int *ikrng1, int *ilrng0, int *ilrng1)   
)

Return ranges on H K L appropriate to spacegroup.

Parameters
sindxindex of this spacegroup.
nlaueLaue number
launamLaue name

References ccp4spg_is_in_asu(), ccperror(), and float_uint_uchar::i.

FORTRAN_SUBR ( PATSGP  ,
patsgp  ,
(const fpstr spgnam, const fpstr pgname, fpstr patnam, int *lpatsg,int spgnam_len, int pgname_len, int patnam_len)  ,
(const fpstr spgnam, const fpstr pgname, fpstr patnam, int *lpatsg)  ,
(const fpstr spgnam, int spgnam_len, const fpstr pgname,int pgname_len, fpstr patnam, int patnam_len, int *lpatsg)   
)

Return the Patterson group name and number corresponding to a spacegroup identified by spacegroup name and point group name.

Parameters
spgnamOn input, spacegroup name.
pgnameOn input, point group name.
patnamOn return, Patterson spacegroup name.
lpatsgOn return, Patterson spacegroup number.

References ccp4_CtoFString(), ccp4_FtoCString(), ccp4spg_load_by_ccp4_spgname(), ccp4spg_name_equal_to_lib(), ccp4spg_pgname_equal(), ccp4_spacegroup_::npatt, and ccp4_spacegroup_::patt_name.

FORTRAN_SUBR ( ASUSET  ,
asuset  ,
(fpstr spgnam, int *numsgp, fpstr pgname,int *msym, float rrsym[192][4][4], int *msymp,int *mlaue, ftn_logical *lprint, int spgnam_len, int pgname_len)  ,
(fpstr spgnam, int *numsgp, fpstr pgname,int *msym, float rrsym[192][4][4], int *msymp,int *mlaue, ftn_logical *lprint)  ,
(fpstr spgnam, int spgnam_len, int *numsgp,fpstr pgname, int pgname_len,int *msym, float rrsym[192][4][4], int *msymp,int *mlaue, ftn_logical *lprint)   
)

Set spacegroup for subsequent calls to ASUPUT, ASUGET, ASUSYM and ASUPHP.

Parameters
spgnamspacegroup name
numsgpspacegroup number
pgnameOn return, point group name
msymnumber of symmetry matrices passed.
rrsymsymmetry matrices (preferred method of identifying spacegroup).
msympOn return, number of primitive symmetry operators
mlaueOn return, number of Laue group.
lprintIf true, print symmetry information.

References ccp4_CtoFString(), ccp4_spgrp_reverse_lookup(), ccp4_utils_malloc(), ccp4spg_free(), ccp4spg_load_by_ccp4_num(), ccp4spg_print_recip_spgrp(), ccperror(), float_uint_uchar::i, and ccp4_symop_::trn.

FORTRAN_SUBR ( ASUSYM  ,
asusym  ,
(float rassym[384][4][4], float rinsym[384][4][4], int *nisym)  ,
(float rassym[384][4][4], float rinsym[384][4][4], int *nisym)  ,
(float rassym[384][4][4], float rinsym[384][4][4], int *nisym)   
)

Return symmetry operators and inverses, set up by ASUSET.

Parameters
rassymsymmetry operators.
rinsyminverse symmetry operators.
nisymnumber of symmetry operators returned.

References ccperror(), and float_uint_uchar::i.

FORTRAN_SUBR ( ASUPUT  ,
asuput  ,
(const int ihkl[3], int jhkl[3], int *isym)  ,
(const int ihkl[3], int jhkl[3], int *isym)  ,
(const int ihkl[3], int jhkl[3], int *isym)   
)

Put reflection in asymmetric unit, as set up by ASUSET.

Parameters
ihklinput indices.
jhkloutput indices.
isymsymmetry operation applied (ISYM number).

References ccp4spg_put_in_asu().

FORTRAN_SUBR ( ASUGET  ,
asuget  ,
(const int ihkl[3], int jhkl[3], const int *isym)  ,
(const int ihkl[3], int jhkl[3], const int *isym)  ,
(const int ihkl[3], int jhkl[3], const int *isym)   
)

Get the original indices jkhl from input indices ihkl generated under symmetry operation isym.

Parameters
ihklinput indices.
jhkloutput indices (recovered original indices).
isymsymmetry operation to be applied (ISYM number).

References ccp4spg_generate_indices().

FORTRAN_SUBR ( ASUPHP  ,
asuphp  ,
(const int jhkl[3], const int *lsym, const int *isign,const float *phasin, float *phasout)  ,
(const int jhkl[3], const int *lsym, const int *isign,const float *phasin, float *phasout)  ,
(const int jhkl[3], const int *lsym, const int *isign,const float *phasin, float *phasout)   
)

Generate phase of symmetry equivalent JHKL from that of IHKL.

Parameters
jhklindices hkl generated in ASUPUT
lsymsymmetry number for generating JHKL
isign1 for I+ , -1 for I-
phasinphase for reflection IHKL
phasoutphase for reflection JHKL

References ccp4spg_phase_shift().

FORTRAN_SUBR ( CCP4SPG_F_LOAD_BY_NAME  ,
ccp4spg_f_load_by_name  ,
(const int *sindx, fpstr namspg, int namspg_len)  ,
(const int *sindx, fpstr namspg)  ,
(const int *sindx, fpstr namspg, int namspg_len)   
)

Loads a spacegroup onto index "sindx". The spacegroup is identified by the spacegroup name.

Parameters
sindxindex of this spacegroup.
namspgspacegroup name.

References ccp4_FtoCString(), ccp4spg_free(), and ccp4spg_load_by_ccp4_spgname().

FORTRAN_SUBR ( CCP4SPG_F_LOAD_BY_OPS  ,
ccp4spg_f_load_by_ops  ,
(const int *sindx, int *msym, float rrsym[192][4][4])  ,
(const int *sindx, int *msym, float rrsym[192][4][4])  ,
(const int *sindx, int *msym, float rrsym[192][4][4])   
)

Loads a spacegroup onto index "sindx". The spacegroup is identified by the set of symmetry matrices.

Parameters
sindxindex of this spacegroup.
msymnumber of symmetry matrices passed.
rrsymsymmetry matrices.

References ccp4_spgrp_reverse_lookup(), ccp4_utils_malloc(), ccp4spg_free(), ccp4spg_print_recip_spgrp(), ccperror(), float_uint_uchar::i, and ccp4_symop_::trn.

FORTRAN_SUBR ( CCP4SPG_F_ASUPUT  ,
ccp4spg_f_asuput  ,
(const int *sindx, const int ihkl[3], int jhkl[3], int *isym)  ,
(const int *sindx, const int ihkl[3], int jhkl[3], int *isym)  ,
(const int *sindx, const int ihkl[3], int jhkl[3], int *isym)   
)

Put reflection in asymmetric unit of spacegroup on index sindx.

Parameters
sindxindex of this spacegroup.
ihklinput indices.
jhkloutput indices.
isymsymmetry operation applied (ISYM number).

References ccp4spg_put_in_asu().

FORTRAN_SUBR ( MSYMLB3  ,
msymlb3  ,
(const int *ist, int *lspgrp, fpstr namspg_cif,fpstr namspg_cifs, fpstr nampg, int *nsymp, int *nsym,float rlsymmmatrx[192][4][4], int namspg_cif_len,int namspg_cifs_len, int nampg_len)  ,
(const int *ist, int *lspgrp, fpstr namspg_cif,fpstr namspg_cifs, fpstr nampg, int *nsymp, int *nsym,float rlsymmmatrx[192][4][4])  ,
(const int *ist, int *lspgrp, fpstr namspg_cif, int namspg_cif_len,fpstr namspg_cifs, int namspg_cifs_len, fpstr nampg, int nampg_len,int *nsymp, int *nsym, float rlsymmmatrx[192][4][4])   
)

Fortran wrapper for ccp4spg_load_by_* functions.

Parameters
istObsolete parameter.
lspgrpSpacegroup number in CCP4 convention. If set on entry, used to search for spacegroup. Returned value is that found.
namspg_cifSpacegroup name. If set on entry, used to search for spacegroup. Returned value is the full extended Hermann Mauguin symbol, with one slight alteration. Symbols such as 'R 3 :H' are converted to 'H 3'. This is for backwards compatibility.
namspg_cifsOn output, contains the spacegroup name without any spaces.
nampgOn output, the point group name.
nsympOn output, the number of primitive symmetry operators.
nsymOn output, the total number of symmetry operators.
rlsymmmatrxOn output, the symmetry operators.

References ccp4_CtoFString(), ccp4_FtoCString(), ccp4_utils_malloc(), ccp4spg_free(), ccp4spg_load_by_ccp4_num(), ccp4spg_load_by_ccp4_spgname(), ccp4spg_name_de_colon(), ccp4spg_to_shortname(), and float_uint_uchar::i.

FORTRAN_SUBR ( EPSLN  ,
epsln  ,
(const int *nsm, const int *nsmp, const float rsm[192][4][4],const int *iprint)  ,
(const int *nsm, const int *nsmp, const float rsm[192][4][4],const int *iprint)  ,
(const int *nsm, const int *nsmp, const float rsm[192][4][4],const int *iprint)   
)

Epsilon zones currently set up in ccp4spg_load_spacegroup If these are not available, use lookup by symops.

Parameters
nsmnumber of symmetry operators.
nsmpnumber of primitive symmetry operators.
rsmsymmetry matrices.
iprintIf iprint > 0 then a summary of epsilon zones is printed.

References ccp4_spgrp_reverse_lookup(), ccp4_utils_malloc(), ccp4spg_print_epsilon_zones(), float_uint_uchar::i, ccp4_symop_::rot, and ccp4_symop_::trn.

FORTRAN_SUBR ( CENTRIC  ,
centric  ,
(const int *nsm, const float rsm[192][4][4],const int *iprint)  ,
(const int *nsm, const float rsm[192][4][4],const int *iprint)  ,
(const int *nsm, const float rsm[192][4][4],const int *iprint)   
)

Set up centric zones based on symmetry operators. Convention: translations are in rsm[isym][3][*]

Parameters
nsmnumber of symmetry matrices passed.
rsmsymmetry matrices.
iprintIf iprint > 0 then a summary of centric zones is printed.

References ccp4_spgrp_reverse_lookup(), ccp4_utils_malloc(), ccp4spg_print_centric_zones(), float_uint_uchar::i, ccp4_symop_::rot, and ccp4_symop_::trn.