####################################################################### # # # Example: Using the WRITE RDF command. # # # ####################################################################### # # # Syntax: # # WRITE [FILE [+]fname] RDF ntable rmin rmax [type1 type2] # # # # Below we write out four RDF (Radial Distribution Functions) # # tables for the same NiAl lattice. # # # # The RDF is a histogram which counts the number of atom pairs # # whose separation distance falls in each displayed sub-range. # # The command also writes the cumulative RDF in the last column; # # this is useful for comparing two RDF functions. # # # ####################################################################### # Read potential for nial read ../nial.txt # Set type constants calc Ni = 1 calc Al = 2 # Make repeating box and lattice (in units of a0) box 6 6 6 particle 2 Ni 0.25 0.25 0.25 Al 0.75 0.75 0.75 dup 5 1 0 0 dup 5 0 1 0 dup 5 0 0 1 # Scale up to units of angstroms (2.8712 unit cell) scale 2.8712 # Set particle masses (in atomic mass units) select type Ni mass 58.71 select type Al mass 26.982 # Write four different kinds of RDFs for perfect NiAl lattice # RDF for distances between all atom pairs. write file rdf-all.out rdf 200 0 4.0 # RDF for distance between atom pairs of Ni-Ni. write file rdf-ni-ni.out rdf 200 0 4.0 Ni Ni # RDF for distance between atom pairs of Al-Al. write file rdf-al-al.out rdf 200 0 4.0 Al Al # RDF for distance between atom pairs of Ni-Ni write file rdf-ni-al.out rdf 200 0 4.0 Ni Al