Warning: Trying to access array offset on value of type null in /home/site/wwwroot/lib/plugins/move/action/rename.php on line 42

Warning: Cannot modify header information - headers already sent by (output started at /home/site/wwwroot/lib/plugins/move/action/rename.php:42) in /home/site/wwwroot/inc/common.php on line 1955

Warning: Cannot modify header information - headers already sent by (output started at /home/site/wwwroot/lib/plugins/move/action/rename.php:42) in /home/site/wwwroot/inc/actions.php on line 38
out_cif_crystalmaker [topas wiki]

User Tools

Site Tools


out_cif_crystalmaker

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
out_cif_crystalmaker [2009/11/18 16:45] – created dch3slout_cif_crystalmaker [2022/11/03 15:08] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== Out_CIF_crystalmaker ======
 +
 +Description: output cif file with adps for crystalmaker
 +
 +Comment: removes a couple of default topas cif items that crystalmaker doesn't like reading so saves editing files
 +
 +Contributed by: John Evans
 +
 +<code topas>macro Out_CIF_crystalmaker(file) {Out_CIF_crystalmaker_1(file) Out_CIF_crystalmaker_2(file)}
 +macro Out_CIF_crystalmaker_1(file)
 +{
 +   out file
 +      Out_String("\ndata_")
 +      Out(Get(phase_name), "\n_chemical_name_mineral ?%s?")
 +      Out(Get(a), "\n_cell_length_a  %V")
 +      Out(Get(b), "\n_cell_length_b  %V")
 +      Out(Get(c), "\n_cell_length_c  %V")
 +      Out(Get(al), "\n_cell_angle_alpha %V")
 +      Out(Get(be), "\n_cell_angle_beta  %V")
 +      Out(Get(ga), "\n_cell_angle_gamma %V")
 +      Out(Get(cell_volume), "\n_cell_volume %V")
 +
 +      Out(Get(sp_grp_char), "\n_space_group %s")
 +
 +      Out_String("\nloop_\n_symmetry_equiv_pos_as_xyz")
 +      Out(Get(sp_xyzs_txt),  "%s")
 +
 + Out_String("\nloop_")
 +         Out_String("\n_atom_site_label")
 +''       Out_String("\n_atom_site_type_symbol")
 +''       Out_String("\n_atom_site_symmetry_multiplicity")
 +         Out_String("\n_atom_site_fract_x")
 +         Out_String("\n_atom_site_fract_y")
 +         Out_String("\n_atom_site_fract_z")
 +         Out_String("\n_atom_site_occupancy")
 +         Out_String("\n_atom_site_B_iso_or_equiv")
 +         atom_out file append
 +            load out_record out_fmt out_eqn
 +            {
 +               "\n%s" = Get_From_String(Get(current_atom), site);
 +'' " %s" = Get_From_String(Get(current_atom), atom);
 +''             " %3.0f" = Get_From_String(Get(current_atom), num_posns);
 + " %V" = Get_From_String(Get(current_atom), x);
 +               " %V" = Get_From_String(Get(current_atom), y);
 +               " %V" = Get_From_String(Get(current_atom), z);
 +               " %V" = Get_From_String(Get(current_atom), occ);
 +               " %V" = Get_From_String(Get(current_atom), beq);
 +            }
 +}
 +
 +macro Out_CIF_crystalmaker_2(file)
 +{
 +   out file append
 +      Out_String("\nloop_")
 +      Out_String("\n_atom_site_aniso_label")
 +''    Out_String("\n_atom_site_type_symbol")
 +      Out_String("\n_atom_site_aniso_U_11")
 +      Out_String("\n_atom_site_aniso_U_22")
 +      Out_String("\n_atom_site_aniso_U_33")
 +      Out_String("\n_atom_site_aniso_U_12")
 +      Out_String("\n_atom_site_aniso_U_13")
 +      Out_String("\n_atom_site_aniso_U_23")
 +      atom_out file append
 +         load out_record out_fmt out_eqn
 +         {
 +            "\n%s" = Get_From_String(Get(current_atom), site);
 +''          " %s" = Get_From_String(Get(current_atom), atom);
 +            " %V" = Get_From_String(Get(current_atom), u11);
 +            " %V" = Get_From_String(Get(current_atom), u22);
 +            " %V" = Get_From_String(Get(current_atom), u33);
 +            " %V" = Get_From_String(Get(current_atom), u12);
 +            " %V" = Get_From_String(Get(current_atom), u13);
 +            " %V" = Get_From_String(Get(current_atom), u23);
 +          }
 +}</code>