| Bsoft 1.9 Bernard's software package

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Classes | Macros | Functions
img_reflections.h File Reference

Routines to manipulate reflection files. More...

`#include "rwimg.h"`
`#include "utilities.h"`

Go to the source code of this file.

## Classes
struct | Bprofile

## Macros
#define | NSHELLS 100

## Functions
int | img_normalize_reflections (Bimage *p)
| Normalizes a set of reflections encoded as a complex image. More...
int | img_mirror_reflections (Bimage *p)
| Mirrors a set of reflections by negating the phases. More...
unsigned long | img_select_reflections (Bimage *p, double hires, double lores, double cone, int weigh, double fomcut)
| Selects reflections for output. More...
Bprofile * | img_reflection_profile (Bimage *p, float radius)
int | img_sfanalyze (Bimage *p)
| Analyzes the FOM's of a set of reflections encoded as a complex image. More...
int | img_sfscale (Bimage *p, Bstring &hklname)
| Scales the input reflections with a second set. More...
int | img_sfmerge (Bimage *p, Bstring &hklname)
| Merges the input reflections with a second set. More...

## Detailed Description

Routines to manipulate reflection files.

Author
  Bernard Heymann

Date
  Created: 19981229
  Modified: 20141231

Definition in file img_reflections.h.

## Macro Definition Documentation

#define NSHELLS 100

Definition at line 13 of file img_reflections.h.

## Function Documentation

int img_mirror_reflections | ( | Bimage * | p | ) |

Mirrors a set of reflections by negating the phases.

Parameters

  *p | complex image.

Returns
  int error code.

      The image must be complex or polar, typically a Fourier transform.

Definition at line 64 of file img_reflections.cpp.

int img_normalize_reflections | ( | Bimage * | p | ) |

Normalizes a set of reflections encoded as a complex image.

Parameters

  *p | complex image.

Returns
  int error code.

      The normalized reflection or structure factor is:
          E = F/sum(|F|)
      where   F is a structure factor or reflection.

Definition at line 29 of file img_reflections.cpp.

Bprofile* img_reflection_profile | ( | Bimage * | p,
|  | float | radius
| ) |  |

unsigned long img_select_reflections | ( | Bimage * | p,
|  | double | hires,
|  | double | lores,
|  | double | cone,
|  | int | weigh,
|  | double | fomcut
| ) |  |

Selects reflections for output.

Parameters

  *p | complex image.
  hires | high resolution limit.
  lores | low resolution limit.
  cone | exclude missing cone data, set to PI/2 for none excluded.
  weigh | flag: if 1 then multiply amplitude with FOM.
  fomcut | FOM cutoff value.

Returns
  unsigned long number of reflections selected.

      Reflections or structure factors are selected based on:
      1.  not in the missing cone.
      2.  above the FOM cutoff value.
      The reflections may be optionally weighed with the FOM.

Definition at line 94 of file img_reflections.cpp.

int img_sfanalyze | ( | Bimage * | p | ) |

Analyzes the FOM's of a set of reflections encoded as a complex image.

Parameters

  *p | complex image.

Returns
  int error code.

Definition at line 300 of file img_reflections.cpp.

int img_sfmerge | ( | Bimage * | p,
|  | Bstring & | hklname
| ) |  |

Merges the input reflections with a second set.

Parameters

  *p | complex image.
  &hklname | file name for second set of reflections.

Returns
  int error code.

Definition at line 477 of file img_reflections.cpp.

int img_sfscale | ( | Bimage * | p,
|  | Bstring & | hklname
| ) |  |

Scales the input reflections with a second set.

Parameters

  *p | complex image.
  &hklname | file name for second set of reflections.

Returns
  int error code.

Definition at line 418 of file img_reflections.cpp.