gpp4  1.3.1
csymlib.h
Go to the documentation of this file.
1 /*
2  csymlib.h: header file for csymlib.c
3  Copyright (C) 2001 CCLRC, Martyn Winn
4 
5  This library is free software: you can redistribute it and/or
6  modify it under the terms of the GNU Lesser General Public
7  License as published by the Free Software Foundation, either
8  version 3 of the License, or (at your option) any later version.
9 
10  This library is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser General Public
16  License along with This library. If not, see
17  <http://www.gnu.org/licenses/>.
18 
19 */
20 
97 #ifndef __CSymLib__
98 #define __CSymLib__
99 
100 
101 /* note that definitions in ccp4_spg.h are within the CSym namespace */
102 #include "ccp4_spg.h"
103 
104 #ifdef __cplusplus
105 namespace CSym {
106 extern "C" {
107 #endif
108 
113 CCP4SPG *ccp4spg_load_by_standard_num(const int numspg);
114 
119 CCP4SPG *ccp4spg_load_by_ccp4_num(const int ccp4numspg);
120 
125 CCP4SPG *ccp4spg_load_by_spgname(const char *spgname);
126 
134 CCP4SPG *ccp4spg_load_by_ccp4_spgname(const char *ccp4spgname);
135 
141 CCP4SPG * ccp4_spgrp_reverse_lookup(const int nsym1, const ccp4_symop *op1);
142 
154 CCP4SPG *ccp4spg_load_spacegroup(const int numspg, const int ccp4numspg,
155  const char *spgname, const char *ccp4spgname,
156  const int nsym1, const ccp4_symop *op1);
157 
162 void ccp4spg_mem_tidy(void);
163 
171 int symfr_driver (const char *line, float rot[][4][4]);
172 
176 void ccp4spg_free(CCP4SPG **sp);
177 
183 void ccp4spg_register_by_ccp4_num(int numspg);
184 
191 void ccp4spg_register_by_symops(int nops, float rsm[][4][4]);
192 
199 int ccp4_spg_get_centering(const char *symbol_Hall, float cent_ops[4][3]);
200 
206 int ccp4spg_load_laue(CCP4SPG* spacegroup, const int nlaue);
207 
211 int ASU_1b (const int h, const int k, const int l);
212 
216 int ASU_2_m (const int h, const int k, const int l);
217 
221 int ASU_mmm (const int h, const int k, const int l);
222 
226 int ASU_4_m (const int h, const int k, const int l);
227 
231 int ASU_4_mmm(const int h, const int k, const int l);
232 
236 int ASU_3b (const int h, const int k, const int l);
237 
241 int ASU_3bm (const int h, const int k, const int l);
242 
246 int ASU_3bmx (const int h, const int k, const int l);
247 
251 int ASU_6_m (const int h, const int k, const int l);
252 
256 int ASU_6_mmm(const int h, const int k, const int l);
257 
261 int ASU_m3b (const int h, const int k, const int l);
262 
266 int ASU_m3bm (const int h, const int k, const int l);
267 
272 char *ccp4spg_symbol_Hall(CCP4SPG* sp);
273 
280 
288 int ccp4spg_name_equal(const char *spgname1, const char *spgname2);
289 
301 int ccp4spg_name_equal_to_lib(const char *spgname_lib, const char *spgname_match);
302 
310 char *ccp4spg_to_shortname(char *shortname, const char *longname);
311 
318 void ccp4spg_name_de_colon(char *name);
319 
327 int ccp4spg_pgname_equal(const char *pgname1, const char *pgname2);
328 
335 
348 int ccp4_spgrp_equal( int nsym1, const ccp4_symop *op1, int nsym2, const ccp4_symop *op2);
349 
356 
363 int ccp4_int_compare( const void *p1, const void *p2 );
364 
372 int ccp4spg_is_in_pm_asu(const CCP4SPG* sp, const int h, const int k, const int l);
373 
381 int ccp4spg_is_in_asu(const CCP4SPG* sp, const int h, const int k, const int l);
382 
397 int ccp4spg_put_in_asu(const CCP4SPG* sp, const int hin, const int kin, const int lin,
398  int *hout, int *kout, int *lout );
399 
412 void ccp4spg_generate_indices(const CCP4SPG* sp, const int isym,
413  const int hin, const int kin, const int lin,
414  int *hout, int *kout, int *lout );
415 
426 float ccp4spg_phase_shift(const int hin, const int kin, const int lin,
427  const float phasin, const float trans[3], const int isign);
428 
434 int ccp4spg_do_chb(const float chb[3][3]);
435 
442 
452 int ccp4spg_is_centric(const CCP4SPG* sp, const int h, const int k, const int l);
453 
461 int ccp4spg_check_centric_zone(const int nzone, const int h, const int k, const int l);
462 
471 float ccp4spg_centric_phase(const CCP4SPG* sp, const int h, const int k, const int l);
472 
477 void ccp4spg_print_centric_zones(const CCP4SPG* sp);
478 
484 char *ccp4spg_describe_centric_zone(const int nzone, char *centric_zone);
485 
492 
501 int ccp4spg_get_multiplicity(const CCP4SPG* sp, const int h, const int k, const int l);
502 
510 int ccp4spg_check_epsilon_zone(const int nzone, const int h, const int k, const int l);
511 
516 void ccp4spg_print_epsilon_zones(const CCP4SPG* sp);
517 
523 char *ccp4spg_describe_epsilon_zone(const int nzone, char *epsilon_zone);
524 
525 
533 int ccp4spg_is_sysabs(const CCP4SPG* sp, const int h, const int k, const int l);
534 
546 int ccp4spg_generate_origins(const char *namspg, const int nsym, const float rsym[][4][4],
547  float origins[][3], int *polarx, int *polary, int *polarz,
548  const int iprint);
549 
554 void ccp4spg_print_recip_spgrp(const CCP4SPG* sp);
555 
560 void ccp4spg_print_recip_ops(const CCP4SPG* sp);
561 
568 int range_to_limits(const char *range, float limits[2]);
569 
581 void set_fft_grid(CCP4SPG* sp, const int nxmin, const int nymin, const int nzmin,
582  const float sample, int *nx, int *ny, int *nz);
583 
589 int all_factors_le_19(const int n);
590 
598 int get_grid_sample(const int minsmp, const int nmul, const float sample);
599 
607 int ccp4spg_check_symm_cell(int nsym, float rsym[][4][4], float cell[6]);
608 
609 #ifdef __cplusplus
610 } }
611 #endif
612 #endif
613 
614 /*
615  Local variables:
616  mode: font-lock
617  End:
618 */
int ccp4spg_load_laue(CCP4SPG *spacegroup, const int nlaue)
Definition: csymlib.c:1835
void ccp4spg_print_epsilon_zones(const CCP4SPG *sp)
Definition: csymlib.c:1371
int ASU_m3b(const int h, const int k, const int l)
Definition: csymlib.c:722
void ccp4spg_set_centric_zones(CCP4SPG *sp)
Definition: csymlib.c:1092
void set_fft_grid(CCP4SPG *sp, const int nxmin, const int nymin, const int nzmin, const float sample, int *nx, int *ny, int *nz)
Definition: csymlib.c:1764
int ASU_3bm(const int h, const int k, const int l)
Definition: csymlib.c:714
void ccp4spg_print_centric_zones(const CCP4SPG *sp)
Definition: csymlib.c:1211
CCP4SPG * ccp4spg_load_by_ccp4_num(const int ccp4numspg)
Definition: csymlib.c:54
int ccp4_int_compare(const void *p1, const void *p2)
Definition: csymlib.c:982
int ASU_3b(const int h, const int k, const int l)
Definition: csymlib.c:712
void ccp4spg_free(CCP4SPG **sp)
Definition: csymlib.c:634
int ccp4spg_generate_origins(const char *namspg, const int nsym, const float rsym[][4][4], float origins[][3], int *polarx, int *polary, int *polarz, const int iprint)
Definition: csymlib.c:1459
int get_grid_sample(const int minsmp, const int nmul, const float sample)
Definition: csymlib.c:1794
CCP4SPG * ccp4_spgrp_reverse_lookup(const int nsym1, const ccp4_symop *op1)
Definition: csymlib.c:69
int ccp4spg_name_equal_to_lib(const char *spgname_lib, const char *spgname_match)
Definition: csymlib.c:770
int ASU_4_mmm(const int h, const int k, const int l)
Definition: csymlib.c:710
int ccp4_spgrp_equal(int nsym1, const ccp4_symop *op1, int nsym2, const ccp4_symop *op2)
Definition: csymlib.c:922
CCP4SPG * ccp4spg_load_by_spgname(const char *spgname)
Definition: csymlib.c:59
int ASU_4_m(const int h, const int k, const int l)
Definition: csymlib.c:708
void ccp4spg_generate_indices(const CCP4SPG *sp, const int isym, const int hin, const int kin, const int lin, int *hout, int *kout, int *lout)
Definition: csymlib.c:1039
ccp4_symop * ccp4spg_norm_trans(ccp4_symop *op)
Definition: csymlib.c:910
char * ccp4spg_describe_epsilon_zone(const int nzone, char *epsilon_zone)
Definition: csymlib.c:1392
int ASU_6_m(const int h, const int k, const int l)
Definition: csymlib.c:718
int ASU_3bmx(const int h, const int k, const int l)
Definition: csymlib.c:716
int all_factors_le_19(const int n)
Definition: csymlib.c:1776
int ASU_2_m(const int h, const int k, const int l)
Definition: csymlib.c:704
void ccp4spg_mem_tidy(void)
Definition: csymlib_f.c:99
Data structure for symmetry information.
int ASU_1b(const int h, const int k, const int l)
Definition: csymlib.c:702
int ccp4_spg_get_centering(const char *symbol_Hall, float cent_ops[4][3])
Definition: csymlib.c:641
int ccp4spg_check_centric_zone(const int nzone, const int h, const int k, const int l)
Definition: csymlib.c:1155
void ccp4spg_register_by_symops(int nops, float rsm[][4][4])
Definition: csymlib_f.c:1093
char * ccp4spg_symbol_Hall(CCP4SPG *sp)
Definition: csymlib.c:727
char * ccp4spg_describe_centric_zone(const int nzone, char *centric_zone)
Definition: csymlib.c:1233
char * ccp4spg_to_shortname(char *shortname, const char *longname)
Definition: csymlib.c:831
int ccp4spg_is_in_pm_asu(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:987
int ccp4spg_check_epsilon_zone(const int nzone, const int h, const int k, const int l)
Definition: csymlib.c:1335
int ccp4spg_is_centric(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:1136
int ASU_6_mmm(const int h, const int k, const int l)
Definition: csymlib.c:720
void ccp4spg_register_by_ccp4_num(int numspg)
Definition: csymlib_f.c:1080
void ccp4spg_print_recip_ops(const CCP4SPG *sp)
Definition: csymlib.c:1618
int ccp4spg_is_in_asu(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:993
float ccp4spg_phase_shift(const int hin, const int kin, const int lin, const float phasin, const float trans[3], const int isign)
Definition: csymlib.c:1065
void ccp4spg_print_recip_spgrp(const CCP4SPG *sp)
Definition: csymlib.c:1603
int ccp4spg_put_in_asu(const CCP4SPG *sp, const int hin, const int kin, const int lin, int *hout, int *kout, int *lout)
Definition: csymlib.c:1006
CCP4SPG * ccp4spg_load_spacegroup(const int numspg, const int ccp4numspg, const char *spgname, const char *ccp4spgname, const int nsym1, const ccp4_symop *op1)
Definition: csymlib.c:78
int ccp4spg_check_symm_cell(int nsym, float rsym[][4][4], float cell[6])
Definition: csymlib.c:1949
int ccp4_symop_code(ccp4_symop op)
Definition: csymlib.c:971
int range_to_limits(const char *range, float limits[2])
Definition: csymlib.c:1703
int symfr_driver(const char *line, float rot[][4][4])
int ccp4spg_do_chb(const float chb[3][3])
Definition: csymlib.c:1082
int ccp4spg_get_multiplicity(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:1318
void ccp4spg_name_de_colon(char *name)
Definition: csymlib.c:862
int ASU_m3bm(const int h, const int k, const int l)
Definition: csymlib.c:724
int ccp4spg_name_equal(const char *spgname1, const char *spgname2)
Definition: csymlib.c:744
float ccp4spg_centric_phase(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:1187
int ccp4spg_is_sysabs(const CCP4SPG *sp, const int h, const int k, const int l)
Definition: csymlib.c:1426
ccp4_symop ccp4_symop_invert(const ccp4_symop op1)
Definition: csymlib.c:735
void ccp4spg_set_epsilon_zones(CCP4SPG *sp)
Definition: csymlib.c:1267
Data structure of a space group descriptor.
Definition: ccp4_spg.h:58
int ccp4spg_pgname_equal(const char *pgname1, const char *pgname2)
Definition: csymlib.c:883
int ASU_mmm(const int h, const int k, const int l)
Definition: csymlib.c:706
Kevin&#39;s symmetry operator.
Definition: ccp4_spg.h:48
CCP4SPG * ccp4spg_load_by_standard_num(const int numspg)
Definition: csymlib.c:49
CCP4SPG * ccp4spg_load_by_ccp4_spgname(const char *ccp4spgname)
Definition: csymlib.c:64