Neko
0.8.1
A portable framework for high-order spectral element flow simulations
|
File format for .csv files, used for any read/write operations involving floating point data. More...
Data Types | |
type | csv_file_t |
Functions/Subroutines | |
subroutine | csv_file_write (this, data, t) |
Writes data to an output file. More... | |
subroutine | csv_file_write_vector (f, data, t) |
Writes a vector_t object to an output file, in a row format. If the parameter t is present, it will be appended at the start of the row, followed by the contents of the vector. More... | |
subroutine | csv_file_write_matrix (f, data, t) |
Writes a matrix_t object to an output file. If the parameter t is present, it will be appended at the start of each row. More... | |
subroutine | csv_file_read (this, data) |
Reads data from an input file. More... | |
subroutine | csv_file_read_vector (f, vec) |
Read a vector (i.e. data on a single row) from a csv file. More... | |
subroutine | csv_file_read_matrix (f, mat) |
Read a matrix from a csv file. More... | |
subroutine | csv_file_set_header (this, hd) |
Sets the header for a csv file. For example: hd = "u,v,w,p" . More... | |
integer function | csv_file_count_lines (this) |
Count the number of lines in a file by going through it entirely until the end is reached. More... | |
File format for .csv files, used for any read/write operations involving floating point data.
integer function csv_file::csv_file_count_lines | ( | class(csv_file_t), intent(in) | this | ) |
Count the number of lines in a file by going through it entirely until the end is reached.
Definition at line 307 of file csv_file.f90.
subroutine csv_file::csv_file_read | ( | class(csv_file_t) | this, |
class(*), intent(inout), target | data | ||
) |
Reads data from an input file.
this | csv file in which to read. |
data | matrix_t or vector_t , will contain the read data. |
Definition at line 183 of file csv_file.f90.
subroutine csv_file::csv_file_read_matrix | ( | type(csv_file_t), intent(inout) | f, |
type(matrix_t), intent(inout) | mat | ||
) |
Read a matrix from a csv file.
d | csv file from which to read. |
vec | Matrix object in which to store the file contents. |
mat
, it will be assumed that a one-line header is present. Definition at line 267 of file csv_file.f90.
subroutine csv_file::csv_file_read_vector | ( | type(csv_file_t), intent(inout) | f, |
type(vector_t), intent(inout) | vec | ||
) |
Read a vector (i.e. data on a single row) from a csv file.
d | csv file from which to read. |
vec | Vector object in which to store the file contents. |
nrows = 1
and ncols = N
. To read a vector in a column format, use a matrix_t
with ncols = 1
. Definition at line 238 of file csv_file.f90.
subroutine csv_file::csv_file_set_header | ( | class(csv_file_t), intent(inout) | this, |
character(len=*), intent(in) | hd | ||
) |
Sets the header for a csv file. For example: hd = "u,v,w,p"
.
hd | Header. |
Definition at line 297 of file csv_file.f90.
subroutine csv_file::csv_file_write | ( | class (csv_file_t), intent(inout) | this, |
class(*), intent(in), target | data, | ||
real(kind=rp), intent(in), optional | t | ||
) |
Writes data to an output file.
this | csv file to write in. |
data | Data to write, can be vector_t or matrix_t. |
t | Time. |
Definition at line 65 of file csv_file.f90.
subroutine csv_file::csv_file_write_matrix | ( | class(csv_file_t), intent(inout) | f, |
type(matrix_t), intent(in) | data, | ||
real(kind=rp), intent(in), optional | t | ||
) |
Writes a matrix_t
object to an output file. If the parameter t
is present, it will be appended at the start of each row.
f | csv file in which to write. |
data | Matrix to write. |
Time. |
Definition at line 153 of file csv_file.f90.
subroutine csv_file::csv_file_write_vector | ( | class(csv_file_t), intent(inout) | f, |
type(vector_t), intent(in) | data, | ||
real(kind=rp), intent(in), optional | t | ||
) |
Writes a vector_t
object to an output file, in a row format. If the parameter t
is present, it will be appended at the start of the row, followed by the contents of the vector.
f | csv file in which to write. |
data | Vector to write. |
Time. |
nrows = 1
and ncols = N
. To write a vector in a column format, use a matrix_t
with ncols = 1
. Definition at line 121 of file csv_file.f90.