Base type to define an abstract system. All other system types defined
in LightKrylov
derive from this fundamental one.
Warning
Users should not extend this abstract class to define their own types.
Finalize timer and print complete history
Finalize the system evaluation timer and print summary. Note: Wrapper of the corresponding routine from lightkrylov_timer
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(abstract_system), | intent(inout) | :: | self |
Return eval counter value
Getter function for the number of system evaluations.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(abstract_system), | intent(in) | :: | self |
Print current timing data
Print the current timing data for the system evaluation. Note: Wrapper of the corresponding routine from lightkrylov_timer
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(abstract_system), | intent(inout) | :: | self |
Reset eval counter
Setter function to reset the system evaluation counter.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(abstract_system), | intent(inout) | :: | self | |||
character(len=*), | intent(in) | :: | procedure |
name of the caller routine |
||
integer, | intent(in), | optional | :: | counter |
optional flag to reset to an integer other than zero. |
|
logical, | intent(in), | optional | :: | reset_timer |
optional flag to reset also the timer |
|
logical, | intent(in), | optional | :: | soft_reset |
optional flag to choose whether to save previous timing data (default: .true.) |
|
logical, | intent(in), | optional | :: | clean_timer |
optional flag to choose whether to fully reset the timer (default: .false.) |
Reset current timing data
Setter routine to reset the system evaluation timer. Note: Wrapper of the corresponding routine from lightkrylov_timer
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(abstract_system), | intent(inout) | :: | self | |||
logical, | intent(in), | optional | :: | soft | ||
logical, | intent(in), | optional | :: | clean |
type, abstract, public :: abstract_system !! Base type to define an abstract system. All other system types defined !! in `LightKrylov` derive from this fundamental one. !! !! @warning !! Users should not extend this abstract class to define their own types. !! @endwarning private integer :: eval_counter = 0 type(lightkrylov_timer) :: eval_timer = lightkrylov_timer('system eval timer') contains procedure, pass(self), public :: get_eval_counter !! Return eval counter value procedure, pass(self), public :: reset_eval_counter !! Reset eval counter procedure, pass(self), public :: print_timer_info !! Print current timing data procedure, pass(self), public :: reset_timer => reset_eval_timer !! Reset current timing data procedure, pass(self), public :: finalize_timer => finalize_eval_timer !! Finalize timer and print complete history end type abstract_system