diff --git a/doc/fermisurfer.doxygen b/doc/fermisurfer.doxygen index 70c5451..f5165d8 100644 --- a/doc/fermisurfer.doxygen +++ b/doc/fermisurfer.doxygen @@ -1,4 +1,4 @@ -# Doxyfile 1.8.9.1 +# Doxyfile 1.8.13 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project. @@ -38,7 +38,7 @@ PROJECT_NAME = fermisurfer # could be handy for archiving the generated documentation or if some version # control system is used. -PROJECT_NUMBER = 1.10.1 +PROJECT_NUMBER = 2.0.0 # Using the PROJECT_BRIEF tag one can provide an optional one line description # for a project that appears at the top of each page and should give viewer a @@ -252,7 +252,7 @@ TCL_SUBST = # members will be omitted, etc. # The default value is: NO. -OPTIMIZE_OUTPUT_FOR_C = YES +OPTIMIZE_OUTPUT_FOR_C = NO # Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or # Python sources only. Doxygen will then generate output that is more tailored @@ -303,6 +303,15 @@ EXTENSION_MAPPING = MARKDOWN_SUPPORT = YES +# When the TOC_INCLUDE_HEADINGS tag is set to a non-zero value, all headings up +# to that level are automatically included in the table of contents, even if +# they do not have an id attribute. +# Note: This feature currently applies only to Markdown headings. +# Minimum value: 0, maximum value: 99, default value: 0. +# This tag requires that the tag MARKDOWN_SUPPORT is set to YES. + +TOC_INCLUDE_HEADINGS = 0 + # When enabled doxygen tries to link words that correspond to documented # classes, or namespaces to their corresponding documentation. Such a link can # be prevented in individual cases by putting a % sign in front of the word or @@ -353,6 +362,13 @@ IDL_PROPERTY_SUPPORT = YES DISTRIBUTE_GROUP_DOC = NO +# If one adds a struct or class to a group and this option is enabled, then also +# any nested class or struct is added to the same group. By default this option +# is disabled and one has to add nested compounds explicitly via \ingroup. +# The default value is: NO. + +GROUP_NESTED_COMPOUNDS = NO + # Set the SUBGROUPING tag to YES to allow class member groups of the same type # (for instance a group of public functions) to be put as a subgroup of that # type (e.g. under the Public Functions section). Set it to NO to prevent @@ -515,7 +531,7 @@ CASE_SENSE_NAMES = NO # scope will be hidden. # The default value is: NO. -HIDE_SCOPE_NAMES = YES +HIDE_SCOPE_NAMES = NO # If the HIDE_COMPOUND_REFERENCE tag is set to NO (default) then doxygen will # append additional text to a page's title, such as Class Reference. If set to @@ -742,6 +758,12 @@ WARN_IF_DOC_ERROR = YES WARN_NO_PARAMDOC = NO +# If the WARN_AS_ERROR tag is set to YES then doxygen will immediately stop when +# a warning is encountered. +# The default value is: NO. + +WARN_AS_ERROR = NO + # The WARN_FORMAT tag determines the format of the warning messages that doxygen # can produce. The string should contain the $file, $line, and $text tags, which # will be replaced by the file and line number from which the warning originated @@ -765,11 +787,10 @@ WARN_LOGFILE = # The INPUT tag is used to specify the files and/or directories that contain # documented source files. You may enter file names like myfile.cpp or # directories like /usr/src/myproject. Separate the files or directories with -# spaces. +# spaces. See also FILE_PATTERNS and EXTENSION_MAPPING # Note: If this tag is empty the current directory is searched. -INPUT = ../src \ - ../src/variable.h +INPUT = ../src # This tag can be used to specify the character encoding of the source files # that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses @@ -782,14 +803,20 @@ INPUT_ENCODING = UTF-8 # If the value of the INPUT tag contains directories, you can use the # FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and -# *.h) to filter out the source-files in the directories. If left blank the -# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, -# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, -# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, -# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, -# *.qsf, *.as and *.js. +# *.h) to filter out the source-files in the directories. +# +# Note that for custom extensions or not directly supported extensions you also +# need to set EXTENSION_MAPPING for the extension otherwise the files are not +# read by doxygen. +# +# If left blank the following patterns are tested:*.c, *.cc, *.cxx, *.cpp, +# *.c++, *.java, *.ii, *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, +# *.hh, *.hxx, *.hpp, *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, +# *.m, *.markdown, *.md, *.mm, *.dox, *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, +# *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf and *.qsf. -FILE_PATTERNS = *.c +FILE_PATTERNS = *.cpp \ + *.hpp # The RECURSIVE tag can be used to specify whether or not subdirectories should # be searched for input files as well. @@ -873,6 +900,10 @@ IMAGE_PATH = # Note that the filter must not add or remove lines; it is applied before the # code is scanned, but not when the output code is generated. If lines are added # or removed, the anchors will not be placed correctly. +# +# Note that for custom extensions or not directly supported extensions you also +# need to set EXTENSION_MAPPING for the extension otherwise the files are not +# properly processed by doxygen. INPUT_FILTER = @@ -882,6 +913,10 @@ INPUT_FILTER = # (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how # filters are used. If the FILTER_PATTERNS tag is empty or if none of the # patterns match the file name, INPUT_FILTER is applied. +# +# Note that for custom extensions or not directly supported extensions you also +# need to set EXTENSION_MAPPING for the extension otherwise the files are not +# properly processed by doxygen. FILTER_PATTERNS = @@ -999,7 +1034,7 @@ VERBATIM_HEADERS = YES # rich C++ code for which doxygen's built-in parser lacks the necessary type # information. # Note: The availability of this option depends on whether or not doxygen was -# compiled with the --with-libclang option. +# generated with the -Duse-libclang=ON option for CMake. # The default value is: NO. CLANG_ASSISTED_PARSING = NO @@ -1159,8 +1194,9 @@ HTML_COLORSTYLE_GAMMA = 80 # If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML # page will contain the date and time when the page was generated. Setting this -# to NO can help when comparing the output of multiple runs. -# The default value is: YES. +# to YES can help to show when doxygen was last run and thus if the +# documentation is up to date. +# The default value is: NO. # This tag requires that the tag GENERATE_HTML is set to YES. HTML_TIMESTAMP = YES @@ -1634,9 +1670,12 @@ COMPACT_LATEX = NO PAPER_TYPE = a4 # The EXTRA_PACKAGES tag can be used to specify one or more LaTeX package names -# that should be included in the LaTeX output. To get the times font for -# instance you can specify -# EXTRA_PACKAGES=times +# that should be included in the LaTeX output. The package can be specified just +# by its name or with the correct syntax as to be used with the LaTeX +# \usepackage command. To get the times font for instance you can specify : +# EXTRA_PACKAGES=times or EXTRA_PACKAGES={times} +# To use the option intlimits with the amsmath package you can specify: +# EXTRA_PACKAGES=[intlimits]{amsmath} # If left blank no extra packages will be included. # This tag requires that the tag GENERATE_LATEX is set to YES. @@ -1739,6 +1778,14 @@ LATEX_SOURCE_CODE = NO LATEX_BIB_STYLE = plain +# If the LATEX_TIMESTAMP tag is set to YES then the footer of each generated +# page will contain the date and time when the page was generated. Setting this +# to NO can help when comparing the output of multiple runs. +# The default value is: NO. +# This tag requires that the tag GENERATE_LATEX is set to YES. + +LATEX_TIMESTAMP = NO + #--------------------------------------------------------------------------- # Configuration options related to the RTF output #--------------------------------------------------------------------------- @@ -2123,7 +2170,7 @@ HIDE_UNDOC_RELATIONS = YES # http://www.graphviz.org/), a graph visualization toolkit from AT&T and Lucent # Bell Labs. The other options in this section have no effect if this option is # set to NO -# The default value is: NO. +# The default value is: YES. HAVE_DOT = YES @@ -2237,7 +2284,8 @@ INCLUDED_BY_GRAPH = YES # # Note that enabling this option will significantly increase the time of a run. # So in most cases it will be better to enable call graphs for selected -# functions only using the \callgraph command. +# functions only using the \callgraph command. Disabling a call graph can be +# accomplished by means of the command \hidecallgraph. # The default value is: NO. # This tag requires that the tag HAVE_DOT is set to YES. @@ -2248,7 +2296,8 @@ CALL_GRAPH = YES # # Note that enabling this option will significantly increase the time of a run. # So in most cases it will be better to enable caller graphs for selected -# functions only using the \callergraph command. +# functions only using the \callergraph command. Disabling a caller graph can be +# accomplished by means of the command \hidecallergraph. # The default value is: NO. # This tag requires that the tag HAVE_DOT is set to YES. @@ -2271,11 +2320,17 @@ GRAPHICAL_HIERARCHY = YES DIRECTORY_GRAPH = YES # The DOT_IMAGE_FORMAT tag can be used to set the image format of the images -# generated by dot. +# generated by dot. For an explanation of the image formats see the section +# output formats in the documentation of the dot tool (Graphviz (see: +# http://www.graphviz.org/)). # Note: If you choose svg you need to set HTML_FILE_EXTENSION to xhtml in order # to make the SVG files visible in IE 9+ (other browsers do not have this # requirement). -# Possible values are: png, jpg, gif and svg. +# Possible values are: png, png:cairo, png:cairo:cairo, png:cairo:gd, png:gd, +# png:gd:gd, jpg, jpg:cairo, jpg:cairo:gd, jpg:gd, jpg:gd:gd, gif, gif:cairo, +# gif:cairo:gd, gif:gd, gif:gd:gd, svg, png:gd, png:gd:gd, png:cairo, +# png:cairo:gd, png:cairo:cairo, png:cairo:gdiplus, png:gdiplus and +# png:gdiplus:gdiplus. # The default value is: png. # This tag requires that the tag HAVE_DOT is set to YES. @@ -2326,6 +2381,11 @@ DIAFILE_DIRS = PLANTUML_JAR_PATH = +# When using plantuml, the PLANTUML_CFG_FILE tag can be used to specify a +# configuration file for plantuml. + +PLANTUML_CFG_FILE = + # When using plantuml, the specified paths are searched for files specified by # the !include statement in a plantuml block. diff --git a/src/bxsf2frmsf.cpp b/src/bxsf2frmsf.cpp deleted file mode 100644 index e241f2b..0000000 --- a/src/bxsf2frmsf.cpp +++ /dev/null @@ -1,315 +0,0 @@ -/* - The MIT License (MIT) - - Copyright (c) 2014 Mitsuaki KAWAMURA - - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is - furnished to do so, subject to the following conditions: - - The above copyright notice and this permission notice shall be included in - all copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. -*/ -/**@file -@brief Convert BXSF format to FRMSF format and compute Fermi velocity -*/ -#include -#include -#include -#include - -int Nb;//!< Number of bands -int Ng[3];//!< @f$k@f$-grid along each direction - -double Bvec[3][3];//!< Reciprocal lattice vector - -double ****Eig;//!< Eigenvalue @f$\varepsilon_{n k}@f$ [::Nb][::Ng[0]][::Ng[1]][::Ng[2]] -double *****vf;//!< Fermi velocity @f${\bf v}_{{\rm F} n k}@f$ [::Nb][::Ng[0]][::Ng[1]][::Ng[2]][7] -/* -@brief Read BXSF file -*/ -static void read_dat( - char *fname//!<[in] Input file name -) { - FILE *fp; - char ctmp[256], ctmpEF1[16], ctmpEF2[16]; - int ierr, ii, ib, ik0, ik1, ik2; - char *cerr; - double EF; - - if ((fp = fopen(fname, "r")) == NULL) { - printf("file open error!!\n"); - printf(" Press any key to exit.\n"); - ierr = getchar(); - exit(EXIT_FAILURE); - } - printf("\n##### Reading BXSF file %s #####\n\n", fname); - - cerr = fgets(ctmp, 256, fp); - while (strstr(ctmp, "Fermi Energy:") == NULL) { - cerr = fgets(ctmp, 256, fp); - } - ierr = sscanf(ctmp, "%s %s %lf", ctmpEF1, ctmpEF2, &EF); - printf(" Fermi energy : %le\n", EF); - - cerr = fgets(ctmp, 256, fp); - while (strstr(ctmp, "BEGIN_BLOCK_BANDGRID_3D") == NULL) { - cerr = fgets(ctmp, 256, fp); - } - cerr = fgets(ctmp, 256, fp); - cerr = fgets(ctmp, 256, fp); - - cerr = fgets(ctmp, 256, fp); - ierr = sscanf(ctmp, "%d", &Nb); - printf(" Number of bands : %d \n", Nb); - cerr = fgets(ctmp, 256, fp); - ierr = sscanf(ctmp, "%d%d%d", &Ng[0], &Ng[1], &Ng[2]); - for (ii = 0; ii < 3; ii++) Ng[ii] -= 1; - printf(" k point grid : %d %d %d \n", Ng[0], Ng[1], Ng[2]); - - cerr = fgets(ctmp, 256, fp); - for (ii = 0; ii < 3; ++ii) { - cerr = fgets(ctmp, 256, fp); - ierr = sscanf(ctmp, "%le%le%le", &Bvec[0][ii], &Bvec[1][ii], &Bvec[2][ii]); - printf(" Bvec %d : %f %f %f \n", ii + 1, Bvec[0][ii], Bvec[1][ii], Bvec[2][ii]); - } - - Eig = new double***[Nb]; - for (ib = 0; ib < Nb; ib++) { - Eig[ib] = new double**[Ng[0] + 1]; - for (ik0 = 0; ik0 <= Ng[0]; ik0++) { - Eig[ib][ik0] = new double*[Ng[1] + 1]; - for (ik1 = 0; ik1 <= Ng[1]; ik1++) { - Eig[ib][ik0][ik1] = new double[Ng[2] + 1]; - }/*for (ik1 = 0; ik1 < Ng[1]; ik1++)*/ - }/*for (ik0 = 0; ik0 < Ng[0]; ik0++)*/ - }/*for (ib = 0; ib < Nb; ib++)*/ - - for (ib = 0; ib < Nb; ib++) { - cerr = fgets(ctmp, 256, fp); - printf(" Reading %s", ctmp); - - for (ik0 = 0; ik0 <= Ng[0]; ik0++) { - for (ik1 = 0; ik1 <= Ng[1]; ik1++) { - for (ik2 = 0; ik2 <= Ng[2]; ik2++) { - ierr = fscanf(fp, "%le", &Eig[ib][ik0][ik1][ik2]); - Eig[ib][ik0][ik1][ik2] -= EF; - }/*for (ik2 = 0; ik2 < Ng[2]; ik2++)*/ - }/*for (ik1 = 0; ik1 < Ng[1]; ik1++)*/ - }/*for (ik0 = 0; ik0 < Ng[0]; ik0++)*/ - - cerr = fgets(ctmp, 256, fp); - - }/*for (ib = 0; ib < Nb; ib++)*/ -} -/** -@brief This routine compute the Fermi verocity from differentiate of e_{n k}. -*/ -static void fvel() { - int ik0, ik1, ik2, ib, ii, jj, ikv[3], ikp[3], ikm[3]; - double de[3]; - double det, avec[3][3], alength[3]; - - printf("\n##### Compute the Fermi velocity #####\n\n"); - - /* - Compute direct lattice vectors - */ - det = -Bvec[0][2] * Bvec[1][1] * Bvec[2][0] - + Bvec[0][1] * Bvec[1][2] * Bvec[2][0] - + Bvec[0][2] * Bvec[1][0] * Bvec[2][1] - - Bvec[0][0] * Bvec[1][2] * Bvec[2][1] - - Bvec[0][1] * Bvec[1][0] * Bvec[2][2] - + Bvec[0][0] * Bvec[1][1] * Bvec[2][2]; - - avec[0][0] = -Bvec[1][2] * Bvec[2][1] + Bvec[1][1] * Bvec[2][2]; - avec[0][1] = Bvec[0][2] * Bvec[2][1] - Bvec[0][1] * Bvec[2][2]; - avec[0][2] = -Bvec[0][2] * Bvec[1][1] + Bvec[0][1] * Bvec[1][2]; - avec[1][0] = Bvec[1][2] * Bvec[2][0] - Bvec[1][0] * Bvec[2][2]; - avec[1][1] = -Bvec[0][2] * Bvec[2][0] + Bvec[0][0] * Bvec[2][2]; - avec[1][2] = Bvec[0][2] * Bvec[1][0] - Bvec[0][0] * Bvec[1][2]; - avec[2][0] = -Bvec[1][1] * Bvec[2][0] + Bvec[1][0] * Bvec[2][1]; - avec[2][1] = Bvec[0][1] * Bvec[2][0] - Bvec[0][0] * Bvec[2][1]; - avec[2][2] = -Bvec[0][1] * Bvec[1][0] + Bvec[0][0] * Bvec[1][1]; - for (ii = 0; ii < 3; ++ii) { - for (jj = 0; jj < 3; ++jj) avec[ii][jj] /= det; - printf(" avec %d : %f %f %f \n", ii + 1, avec[ii][0], avec[ii][1], avec[ii][2]); - } - - for (ii = 0; ii < 3; ii++) - alength[ii] = sqrt( - avec[0][ii] * avec[0][ii] + avec[1][ii] * avec[1][ii] + avec[2][ii] * avec[2][ii]); - printf(" alength : %f %f %f \n", alength[0], alength[1], alength[2]); - /* - malloc fermi velocity - */ - vf = new double****[Nb]; - for (ib = 0; ib < Nb; ib++) { - vf[ib] = new double***[Ng[0]]; - for (ik0 = 0; ik0 < Ng[0]; ik0++) { - vf[ib][ik0] = new double**[Ng[1]]; - for (ik1 = 0; ik1 < Ng[1]; ik1++) { - vf[ib][ik0][ik1] = new double*[Ng[2]]; - for (ik2 = 0; ik2 < Ng[2]; ik2++) { - vf[ib][ik0][ik1][ik2] = new double[7]; - } - }/*for (ik1 = 0; ik1 < Ng[1]; ik1++)*/ - }/*for (ik0 = 0; ik0 < Ng[0]; ik0++)*/ - }/*for (ib = 0; ib < Nb; ib++)*/ - - for (ik0 = 0; ik0 < Ng[0]; ik0++) { - ikv[0] = ik0; - for (ik1 = 0; ik1 < Ng[1]; ik1++) { - ikv[1] = ik1; - for (ik2 = 0; ik2 < Ng[2]; ik2++) { - ikv[2] = ik2; - - for (ib = 0; ib < Nb; ib++) { - for (ii = 0; ii < 3; ii++) { - - for (jj = 0; jj < 3; jj++) { - ikp[jj] = ikv[jj]; - ikm[jj] = ikv[jj]; - } - if(ikv[ii] == Ng[ii] - 1) ikp[ii] = 0; - else ikp[ii] += 1; - - if (ikv[ii] == 0) ikm[ii] = Ng[ii] - 1; - else ikm[ii] -= 1; - - de[ii] = Eig[ib][ikp[0]][ikp[1]][ikp[2]] - - Eig[ib][ikm[0]][ikm[1]][ikm[2]]; - de[ii] *= 0.5 * (double)Ng[ii]; - }/*for (ii = 0; ii < 3; ii++)*/ - - for (ii = 0; ii < 3; ii++) { - vf[ib][ik0][ik1][ik2][ii] = de[ii] * alength[ii]; - vf[ib][ik0][ik1][ik2][ii + 3] = - avec[0][ii] * de[0] + avec[1][ii] * de[1] + avec[2][ii] * de[2]; - }/*for (ii = 0; ii < 3; ii++)*/ - vf[ib][ik0][ik1][ik2][6] = sqrt( - vf[ib][ik0][ik1][ik2][3] * vf[ib][ik0][ik1][ik2][3] - + vf[ib][ik0][ik1][ik2][4] * vf[ib][ik0][ik1][ik2][4] - + vf[ib][ik0][ik1][ik2][5] * vf[ib][ik0][ik1][ik2][5]); - - }/*for (ib = 0; ib < Nb; ib++)*/ - }/* for (ik2 = 0; ik2 < Ng[2]; ik2++)*/ - }/*for (ik1 = 0; ik1 < Ng[1]; ik1++)*/ - }/* for (ik0 = 0; ik0 < Ng[0]; ik0++)*/ -}/*void fvel()*/ -/** -@brief Write FRMSF file -*/ -static void write_file( - char *fname1, //!< [in] File name without - const char *ext, //!< [in] File tail - int component //!< [in] Component of the Fermi velocity -) -{ - FILE* fo; - int ierr, ibnd, ik0, ik1, ik2, ii; - char fname2[256]; - char *p; - - ii = 0; - if (strstr(fname1, ".bxsf") != NULL) { - for (p = &fname1[0]; p < strstr(fname1, ".bxsf"); p++) fname2[ii++] = *p; - } - else if (strstr(fname1, ".BXSF") != NULL) { - for (p = &fname1[0]; p < strstr(fname1, ".BXSF"); p++) fname2[ii++] = *p; - } - else if (strstr(fname1, ".Bxsf") != NULL) { - for (p = &fname1[0]; p < strstr(fname1, ".Bxsf"); p++) fname2[ii++] = *p; - } - else { - printf("ERROR! Extension shoud be .bxsf, .BXSF, or .Bxsf !\n"); - printf(" Press any key to exit.\n"); - ierr = getchar(); - exit(-1); - } - sprintf(&fname2[ii], "%s", ext); - - printf(" %s\n", fname2); - - fo = fopen(fname2, "w"); - ierr = fprintf(fo, "%d %d %d\n", Ng[0], Ng[1], Ng[2]); - ierr = fprintf(fo, "%d\n", 1); - ierr = fprintf(fo, "%d\n", Nb); - ierr = fprintf(fo, "%e %e %e\n", Bvec[0][0], Bvec[1][0], Bvec[2][0]); - ierr = fprintf(fo, "%e %e %e\n", Bvec[0][1], Bvec[1][1], Bvec[2][1]); - ierr = fprintf(fo, "%e %e %e\n", Bvec[0][2], Bvec[1][2], Bvec[2][2]); - - for (ibnd = 0; ibnd < Nb; ++ibnd) { - for (ik0 = 0; ik0 < Ng[0]; ++ik0) { - for (ik1 = 0; ik1 < Ng[1]; ++ik1) { - for (ik2 = 0; ik2 < Ng[2]; ++ik2) { - ierr = fprintf(fo, "%e\n", Eig[ibnd][ik0][ik1][ik2]); - } - } - } - } - if (component != 7) { - for (ibnd = 0; ibnd < Nb; ++ibnd) { - for (ik0 = 0; ik0 < Ng[0]; ++ik0) { - for (ik1 = 0; ik1 < Ng[1]; ++ik1) { - for (ik2 = 0; ik2 < Ng[2]; ++ik2) { - ierr = fprintf(fo, "%e\n", vf[ibnd][ik0][ik1][ik2][component]); - } - } - } - } - } - fclose(fo); - -}/*void write_file()*/ -/* - @brief Main routine of BXSF2FRMSF -*/ -int main( - int argc, //!< [in] - char *argv[] //!< [in] Input file name -) -{ - int ierr; - - if (argc < 2) { - printf("\n\nInput file is not specified !\n"); - printf(" Press any key to exit.\n"); - ierr = getchar(); - exit(-1); - } - - read_dat(argv[1]); - - fvel(); - - if (argc > 2 && strncmp(argv[2], "-v", 2) == 0) { - printf("\n##### Output files #####\n\n"); - - write_file(argv[1], "_vfa1.frmsf\0", 0); - write_file(argv[1], "_vfa2.frmsf\0", 1); - write_file(argv[1], "_vfa3.frmsf\0", 2); - write_file(argv[1], "_vfx.frmsf\0", 3); - write_file(argv[1], "_vfy.frmsf\0", 4); - write_file(argv[1], "_vfz.frmsf\0", 5); - write_file(argv[1], "_vf.frmsf\0", 6); - - printf("\n##### DONE #####\n"); - printf(" Press any key to exit.\n"); - ierr = getchar(); - } - else { - write_file(argv[1], ".frmsf\0", 7); - } -}