alpaqa 1.0.0a15
Nonconvex constrained optimization
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
MaxHistory< T > Class Template Reference

#include <alpaqa/util/max-history.hpp>

Detailed Description

template<class T>
class alpaqa::MaxHistory< T >

Keep track of the maximum value over a specified horizon length.

Definition at line 11 of file max-history.hpp.

+ Collaboration diagram for MaxHistory< T >:

Public Member Functions

 MaxHistory (size_t memory)
 
void add (T newt)
 
const Tmax () const
 

Private Attributes

std::vector< Tbuffer
 
bool full = false
 
decltype(buffer.begin()) it = buffer.begin()
 
T max_ {}
 

Constructor & Destructor Documentation

◆ MaxHistory()

template<class T >
MaxHistory ( size_t  memory)
inline

Definition at line 13 of file max-history.hpp.

Member Function Documentation

◆ add()

template<class T >
void add ( T  newt)
inline

Definition at line 15 of file max-history.hpp.

◆ max()

template<class T >
const T & max ( ) const
inline

Definition at line 38 of file max-history.hpp.

Member Data Documentation

◆ buffer

template<class T >
std::vector<T> buffer
private

Definition at line 41 of file max-history.hpp.

◆ full

template<class T >
bool full = false
private

Definition at line 42 of file max-history.hpp.

◆ it

template<class T >
decltype(buffer.begin()) it = buffer.begin()
private

Definition at line 43 of file max-history.hpp.

◆ max_

template<class T >
T max_ {}
private

Definition at line 44 of file max-history.hpp.


The documentation for this class was generated from the following file: