|
Globals Library 1.0
|
Data structure containing values of a variable possibly depending on time (e.g., forcing function). More...
Public Member Functions | |
| procedure, pass, public | init (this, stderr, inputfdescr, dimdata, ndata, default_data) |
| Static constructor for timeinputs::timedata. | |
| procedure, pass, public | kill (this, lun) |
| Static destructor for timeinputs::timedata. | |
| procedure, pass, public | info (this, lun, nsample) |
| Info procedure for timeinputs::timedata. | |
| procedure, pass, public | set (this, stderr, inputfdescr, time, endfile, info) |
| Set (read if necessary) non-steady time data. | |
| procedure, pass, public | eval_ninput (this) |
| Compute number of non zero elements of ::tdactual. | |
Public Attributes | |
| logical | built |
| Logical flag to check if object is initialized. | |
| integer | dimdata |
| Dimension of real data array. | |
| integer | ndata |
| Number of data arrays. | |
| real(kind=double), dimension(:, :, :), allocatable | tdval |
| Dimension (::dimdata,::ndata,2). Input values. If data is steady state, then ::tdval(:,:,1) == ::tdval(:,:,2). | |
| real(kind=double), dimension(:), allocatable | tdtime |
| Dimension (2) Time values. If data is steady state, then ::tdtime(2) = ::huge. | |
| integer | nnonzeros = 0 |
| Number of current non-zeros values. | |
| real(kind=double), dimension(:, :), allocatable | tdactual |
| Dimension (::dimdata,::ndata). Actual values. If data is steady state, then ::tdactual = ::tdval(:,:,1). | |
| real(kind=double), dimension(:), allocatable | val |
| Dimension (::dimdata) Scratch array for reading values. | |
| real(kind=double) | time |
| Time of evaluated ::tdactual. | |
| logical | steadytd |
| .true. if data do not depend on time, .false. if data depend on time | |
| logical | steadytd_written = .false. |
| .true. if closing time has been written, .false. if closing time has not been written | |
Data structure containing values of a variable possibly depending on time (e.g., forcing function).
Definition at line 13 of file modTimeInputs.f90.
| procedure, pass, public timeinputs::timedata::init | ( | class(timedata), intent(out) | this, |
| integer, intent(in) | stderr, | ||
| type(file), intent(in) | inputfdescr, | ||
| integer, intent(in), optional | dimdata, | ||
| integer, intent(in), optional | ndata, | ||
| real(kind=double), dimension(:), intent(in), optional | default_data ) |
Static constructor for timeinputs::timedata.
Read data from input file or from input vector.
Input file for steady state data must be written in the form
If input data depend on time, the input file must be in the form:
Steady state input data can also be given using the input vector default_data. In this case:
| [in] | stderr | unit number for error message |
| [in] | InputFdescr | file for input data. If file does not exist, default_data must be given. |
| [in] | dimdata | valaue to be assigned to timedata::dimdata. Optional if file is provided, otherwise must be given. |
| [in] | ndata | value to be assigned to timedata::ndata. Optional if file is provided, otherwise must be given. |
| [in] | default_data | steady state input data. This variable is required only if input file does not exist. |
Definition at line 47 of file modTimeInputs.f90.
| procedure, pass, public timeinputs::timedata::kill | ( | class(timedata), intent(inout) | this, |
| integer, intent(in) | lun ) |
Static destructor for timeinputs::timedata.
| [in] | lun | unit number for error message output |
Definition at line 49 of file modTimeInputs.f90.
| procedure, pass, public timeinputs::timedata::info | ( | class(timedata), intent(in) | this, |
| integer, intent(in) | lun, | ||
| integer, intent(in) | nsample ) |
Info procedure for timeinputs::timedata.
Print the first nsample non-zero terms of timedata::tdval(:,:.1), timedata::tdactual(:,:) and timedata::tdval(:,:,2).
| [in] | lun | unit number for error message output. |
| [in] | nsample | number of first non-zero samples to be printed |
Definition at line 51 of file modTimeInputs.f90.
| procedure, pass, public timeinputs::timedata::set | ( | class(timedata), intent(inout) | this, |
| integer, intent(in) | stderr, | ||
| type(file), intent(in) | inputfdescr, | ||
| real(kind=double), intent(in) | time, | ||
| logical, intent(inout) | endfile, | ||
| integer, intent(inout), optional | info ) |
Set (read if necessary) non-steady time data.
If timedata::steadytd = .true., do nothing. Set the value of timedata::tdactual using a linear interpolation in time of the values in timedata::tdval.
| [in] | stderr | unit number for error message |
| [in] | InputFdescr | input file for reading data |
| [in] | time | time for the computation of timedata::tdactual |
| [in,out] | endfile | .true. if end of file is reached |
| [in,out] | info | error code (optional) |
Definition at line 53 of file modTimeInputs.f90.
| procedure, pass, public timeinputs::timedata::eval_ninput | ( | class(timedata), intent(in) | this | ) |
Compute number of non zero elements of ::tdactual.
Definition at line 55 of file modTimeInputs.f90.
| logical timeinputs::timedata::built |
Logical flag to check if object is initialized.
Definition at line 15 of file modTimeInputs.f90.
| integer timeinputs::timedata::dimdata |
Dimension of real data array.
Definition at line 17 of file modTimeInputs.f90.
| integer timeinputs::timedata::ndata |
Number of data arrays.
Definition at line 19 of file modTimeInputs.f90.
| real(kind=double), dimension(:, :, :), allocatable timeinputs::timedata::tdval |
Dimension (::dimdata,::ndata,2). Input values. If data is steady state, then ::tdval(:,:,1) == ::tdval(:,:,2).
Definition at line 23 of file modTimeInputs.f90.
| real(kind=double), dimension(:), allocatable timeinputs::timedata::tdtime |
Dimension (2) Time values. If data is steady state, then ::tdtime(2) = ::huge.
Definition at line 27 of file modTimeInputs.f90.
| integer timeinputs::timedata::nnonzeros = 0 |
Number of current non-zeros values.
Definition at line 29 of file modTimeInputs.f90.
| real(kind=double), dimension(:, :), allocatable timeinputs::timedata::tdactual |
Dimension (::dimdata,::ndata). Actual values. If data is steady state, then ::tdactual = ::tdval(:,:,1).
Definition at line 33 of file modTimeInputs.f90.
| real(kind=double), dimension(:), allocatable timeinputs::timedata::val |
Dimension (::dimdata) Scratch array for reading values.
Definition at line 36 of file modTimeInputs.f90.
| real(kind=double) timeinputs::timedata::time |
Time of evaluated ::tdactual.
Definition at line 38 of file modTimeInputs.f90.
| logical timeinputs::timedata::steadytd |
.true. if data do not depend on time, .false. if data depend on time
Definition at line 41 of file modTimeInputs.f90.
| logical timeinputs::timedata::steadytd_written = .false. |
.true. if closing time has been written, .false. if closing time has not been written
Definition at line 44 of file modTimeInputs.f90.