atomes 1.1.15
atomes: an atomic scale modeling tool box
Loading...
Searching...
No Matches
read_coord.c File Reference

General functions to import atomic coordinates. More...

#include "global.h"
#include "glview.h"
#include "callbacks.h"
#include "interface.h"
#include "project.h"
#include "bind.h"
#include "cbuild_edit.h"
+ Include dependency graph for read_coord.c:

Go to the source code of this file.

Functions

int open_xyz_file (int linec)
 open XYZ file
 
int open_c3d_file (int linec)
 open C3D file
 
int open_pdb_file (int linec)
 open PDB file
 
int open_trj_file (int linec)
 open CPMD file
 
int open_vas_file (int linec)
 open VASP file
 
int open_cif_file (int linec)
 open CIF file
 
int open_hist_file (int linec)
 open DL-POLY history file
 
void allocatoms (project *this_proj)
 allocate project data
 
chemical_dataalloc_chem_data (int spec)
 allocate chemistry data
 
int build_crystal (gboolean visible, project *this_proj, gboolean to_wrap, gboolean show_clones, cell_info *cell, GtkWidget *widg)
 build crystal
 
void add_reader_info (gchar *info, int mid)
 append information message to the reader information
 
void reader_info (gchar *type, gchar *sinf, int val)
 display reader information
 
void format_error (int stp, int ato, gchar *mot, int line)
 Message to display an error message.
 
int set_v_dummy (gchar *this_word)
 check if dummy is used for unknown species, if not then ask what to do
 
void check_for_species (double v, int ato)
 Fill the species for each atom and the associated data.
 
int open_coord_file (gchar *filename, int fti)
 open atomic coordinates file
 

Variables

const gchar * dfi [2]
 
atom_searchcif_search
 
atomic_objectcif_object
 
FILE * coordf
 
coord_filethis_reader
 
gchar ** coord_line = NULL
 
gchar * this_line = NULL
 
char * this_word
 
line_nodehead = NULL
 
line_nodetail = NULL
 

Detailed Description

General functions to import atomic coordinates.

Author
Sébastien Le Roux sebas.nosp@m.tien.nosp@m..lero.nosp@m.ux@i.nosp@m.pcms..nosp@m.unis.nosp@m.tra.f.nosp@m.r

Definition in file read_coord.c.

Function Documentation

◆ add_reader_info()

void add_reader_info ( gchar * info,
int mid )

append information message to the reader information

Parameters
infothe reader information message
midmessage type (0 = error, 1 = warning)

Definition at line 86 of file read_coord.c.

◆ alloc_chem_data()

chemical_data * alloc_chem_data ( int spec)
extern

allocate chemistry data

Parameters
specthe number of chemical species

Definition at line 186 of file open_p.c.

◆ allocatoms()

void allocatoms ( project * this_proj)
extern

allocate project data

Parameters
this_projthe target project

Definition at line 160 of file open_p.c.

◆ build_crystal()

int build_crystal ( gboolean visible,
project * this_proj,
gboolean to_wrap,
gboolean show_clones,
cell_info * cell,
GtkWidget * widg )
extern

build crystal

Parameters
visibleis the crystal builder window visible ?
this_projthe target project
to_wrapwrap or not atomic coordinates in the unit cell
show_clonesshow / hide clone(s)
cellthe cell info that contains the crystal description
widgthe GtkWidget sending the signal

Definition at line 907 of file cbuild_action.c.

◆ check_for_species()

void check_for_species ( double v,
int ato )

Fill the species for each atom and the associated data.

Parameters
vZ
atothe atom id

Definition at line 196 of file read_coord.c.

◆ format_error()

void format_error ( int stp,
int ato,
gchar * mot,
int line )

Message to display an error message.

Parameters
stpthe MD step id
atoAtom id
motMessage
lineLine with the error

Definition at line 116 of file read_coord.c.

◆ open_c3d_file()

int open_c3d_file ( int linec)
extern

open C3D file

Parameters
linecNumber of lines in the file

Definition at line 322 of file read_c3d.c.

◆ open_cif_file()

int open_cif_file ( int linec)
extern

open CIF file

Parameters
linecTotal number of lines

Definition at line 1728 of file read_cif.c.

◆ open_coord_file()

int open_coord_file ( gchar * filename,
int fti )

open atomic coordinates file

Parameters
filenamethe file name
ftithe type of coordinates

Definition at line 250 of file read_coord.c.

◆ open_hist_file()

int open_hist_file ( int linec)
extern

open DL-POLY history file

Parameters
linecNumber of lines in the file

Definition at line 440 of file read_hist.c.

◆ open_pdb_file()

int open_pdb_file ( int linec)
extern

open PDB file

Parameters
linecNumber of lines in the file

Definition at line 217 of file read_pdb.c.

◆ open_trj_file()

int open_trj_file ( int linec)
extern

open CPMD file

Parameters
linecNumber of lines in the file

Definition at line 251 of file read_trj.c.

◆ open_vas_file()

int open_vas_file ( int linec)
extern

open VASP file

Parameters
linecNumber of lines in the file

Definition at line 244 of file read_vas.c.

◆ open_xyz_file()

int open_xyz_file ( int linec)
extern

open XYZ file

Parameters
linecNumber of lines in the file

Definition at line 303 of file read_xyz.c.

◆ reader_info()

void reader_info ( gchar * type,
gchar * sinf,
int val )

display reader information

Parameters
typeFile type
sinfInformation message
valValue to present

Definition at line 101 of file read_coord.c.

◆ set_v_dummy()

int set_v_dummy ( gchar * this_word)

check if dummy is used for unknown species, if not then ask what to do

Parameters
this_wordthe chemical species label

Definition at line 142 of file read_coord.c.

Variable Documentation

◆ cif_object

atomic_object* cif_object
extern

Definition at line 282 of file read_cif.c.

◆ cif_search

atom_search* cif_search
extern

Definition at line 281 of file read_cif.c.

◆ coord_line

gchar** coord_line = NULL

Definition at line 72 of file read_coord.c.

◆ coordf

FILE* coordf

Definition at line 70 of file read_coord.c.

◆ dfi

const gchar* dfi[2]
extern

Definition at line 74 of file main.c.

◆ head

line_node* head = NULL

Definition at line 75 of file read_coord.c.

◆ tail

line_node* tail = NULL

Definition at line 76 of file read_coord.c.

◆ this_line

gchar* this_line = NULL

Definition at line 73 of file read_coord.c.

◆ this_reader

coord_file* this_reader

Definition at line 71 of file read_coord.c.

◆ this_word

char* this_word

Definition at line 74 of file read_coord.c.