| Bsoft 2.0.5 Bernard's software package

Functions | Variables
mol_water.cpp File Reference

Generating and managing water. More...

`#include "rwmolecule.h"`
`#include "mol_bonds.h"`
`#include "Matrix3.h"`
`#include "linked_list.h"`
`#include "random_numbers.h"`
`#include "utilities.h"`

Go to the source code of this file.

## Functions
Bmolecule * | mol_generate_one_water (Bmolecule **mollist, char *watername, Vector3< double > Ocoord)
| Generates one water molecule at a given location. More...
Bmolgroup * | molgroup_generate_regular_water (Vector3< double > size, int type)
| Generates a block of water based on a regular lattice. More...
Bmolgroup * | molgroup_generate_random_water (Vector3< double > size)
| Generates a block of water with random placement. More...
Bbond * | water_bond_list (Bmolgroup *molgroup)
| Generates a bond list for a block of waters. More...
Bangle * | water_angle_list (Bmolgroup *molgroup)
| Generates a bond angle list for a block of waters. More...
int | molgroup_calc_water_rdf (Bmolgroup *molgroup, double interval, double cutoff)
| Calculates a radial distribution function for water molecules. More...

## Variables
int | verbose

## Detailed Description

Generating and managing water.

Author
  Bernard Heymann

Date
  Created: 20001014
  Modified: 20110811

Definition in file mol_water.cpp.

## Function Documentation

## ◆ mol_generate_one_water()

Bmolecule* mol_generate_one_water | ( | Bmolecule ** | mollist,
|  | char * | watername,
|  | Vector3< double > | Ocoord
| ) |  |

Generates one water molecule at a given location.

Parameters

  **mollist | molecule list.
  *watername | molecule name.
  Ocoord | oxygen coordinates.

Returns
  Bmolecule* new water molecule.

Definition at line 26 of file mol_water.cpp.

## ◆ molgroup_calc_water_rdf()

int molgroup_calc_water_rdf | ( | Bmolgroup * | molgroup,
|  | double | interval,
|  | double | cutoff
| ) |  |

Calculates a radial distribution function for water molecules.

Parameters

  *molgroup | molecule group.
  interval | interval between bins.
  cutoff | distance cutoff.

Returns
  int 0.

Definition at line 323 of file mol_water.cpp.

## ◆ molgroup_generate_random_water()

Bmolgroup* molgroup_generate_random_water | ( | Vector3< double > | size | ) |

Generates a block of water with random placement.

    The number of water molecules generated is calculated as:
        n = volume * 0.03346.

Parameters

  size | size of block.

Returns
  Bmolgroup* new molecule group.

Definition at line 181 of file mol_water.cpp.

## ◆ molgroup_generate_regular_water()

Bmolgroup* molgroup_generate_regular_water | ( | Vector3< double > | size,
|  | int | type
| ) |  |

Generates a block of water based on a regular lattice.

    The number of water molecules generated is calculated as:
        n = volume * 0.03346.

Parameters

  size | size of block.
  type | type of lattice, 2=rectangular, 3=tetrahedral.

Returns
  Bmolgroup* new molecule group.

Definition at line 89 of file mol_water.cpp.

## ◆ water_angle_list()

Bangle* water_angle_list | ( | Bmolgroup * | molgroup | ) |

Generates a bond angle list for a block of waters.

Parameters

  *molgroup | molecule group.

Returns
  Bangle* new bond angle list.

Definition at line 291 of file mol_water.cpp.

## ◆ water_bond_list()

Bbond* water_bond_list | ( | Bmolgroup * | molgroup | ) |

Generates a bond list for a block of waters.

Parameters

  *molgroup | molecule group.

Returns
  Bbond* new bond list.

Definition at line 249 of file mol_water.cpp.

## Variable Documentation

## ◆ verbose

int verbose