#include "eigenIO.h"
Go to the source code of this file.
|
int | comp (const void *p, const void *q) |
|
int | OutputRealEigenValue (int xNsize, double *ene, char *filename) |
|
int | OutputCmpEigenValue (int xNsize, complex double *ene, char *filename) |
|
int | OutputRealEigenVec (int xNsize, const int nene, double **vec, const int nproc, char *filename) |
|
int | OutputCmpEigenVec (int xNsize, const int nene, complex double **vec, const int nproc, char *filename) |
|
int | InputRealEigenValue (int xNsize, double *ene, char *filename) |
|
int | InputCmpEigenValue (int xNsize, complex double *ene, char *filename) |
|
int | InputRealEigenVec (int xNsize, const int nene, double **vec, const int nproc, char *filename) |
|
int | InputCmpEigenVec (int xNsize, const int nene, complex double **vec, const int nproc, char *filename) |
|
◆ comp()
int comp |
( |
const void * |
p, |
|
|
const void * |
q |
|
) |
| |
◆ InputCmpEigenValue()
int InputCmpEigenValue |
( |
int |
xNsize, |
|
|
complex double * |
ene, |
|
|
char * |
filename |
|
) |
| |
Definition at line 118 of file eigenIO.c.
122 fp = fopen(filename,
"rb+");
127 fread(ene,
sizeof(complex
double), xNsize, fp);
◆ InputCmpEigenVec()
int InputCmpEigenVec |
( |
int |
xNsize, |
|
|
const int |
nene, |
|
|
complex double ** |
vec, |
|
|
const int |
nproc, |
|
|
char * |
filename |
|
) |
| |
Definition at line 149 of file eigenIO.c.
152 fp = fopen(filename,
"rb+");
157 fread(
vec[nene],
sizeof(complex
double), xNsize, fp);
◆ InputRealEigenValue()
int InputRealEigenValue |
( |
int |
xNsize, |
|
|
double * |
ene, |
|
|
char * |
filename |
|
) |
| |
Definition at line 103 of file eigenIO.c.
106 fp = fopen(filename,
"rb+");
111 fread(ene,
sizeof(
double), xNsize, fp);
◆ InputRealEigenVec()
int InputRealEigenVec |
( |
int |
xNsize, |
|
|
const int |
nene, |
|
|
double ** |
vec, |
|
|
const int |
nproc, |
|
|
char * |
filename |
|
) |
| |
Definition at line 134 of file eigenIO.c.
137 fp = fopen(filename,
"rb+");
142 fread(
vec[nene],
sizeof(
double), xNsize, fp);
◆ OutputCmpEigenValue()
int OutputCmpEigenValue |
( |
int |
xNsize, |
|
|
complex double * |
ene, |
|
|
char * |
filename |
|
) |
| |
Definition at line 49 of file eigenIO.c.
References comp().
52 double *buffene = (
double *) malloc(xNsize *
sizeof(
double));
54 for(i = 0; i < xNsize; i++)
55 buffene[i] = creal(ene[i]);
57 qsort(buffene, xNsize,
sizeof(
double),
comp);
59 fp = fopen(filename,
"wb+");
65 fwrite(buffene,
sizeof(
double), xNsize, fp);
int comp(const void *p, const void *q)
◆ OutputCmpEigenVec()
int OutputCmpEigenVec |
( |
int |
xNsize, |
|
|
const int |
nene, |
|
|
complex double ** |
vec, |
|
|
const int |
nproc, |
|
|
char * |
filename |
|
) |
| |
Definition at line 88 of file eigenIO.c.
91 fp = fopen(filename,
"wb+");
96 fwrite(
vec[nene],
sizeof(complex
double), xNsize, fp);
◆ OutputRealEigenValue()
int OutputRealEigenValue |
( |
int |
xNsize, |
|
|
double * |
ene, |
|
|
char * |
filename |
|
) |
| |
Definition at line 25 of file eigenIO.c.
References comp().
28 double *buffene = (
double *) malloc(xNsize *
sizeof(
double));
30 for(i = 0; i < xNsize; i++)
33 qsort(buffene, xNsize,
sizeof(
double),
comp);
35 fp = fopen(filename,
"wb+");
41 fwrite(buffene,
sizeof(
double), xNsize, fp);
int comp(const void *p, const void *q)
◆ OutputRealEigenVec()
int OutputRealEigenVec |
( |
int |
xNsize, |
|
|
const int |
nene, |
|
|
double ** |
vec, |
|
|
const int |
nproc, |
|
|
char * |
filename |
|
) |
| |
Definition at line 73 of file eigenIO.c.
76 fp = fopen(filename,
"wb+");
81 fwrite(
vec[nene],
sizeof(
double), xNsize, fp);