openjij
Framework for the Ising model and QUBO.
Loading...
Searching...
No Matches
openjij::utility::IntegerVariable Struct Reference

#include <variable.hpp>

Public Member Functions

 IntegerVariable (const std::int64_t lower_bound, const std::int64_t upper_bound)
 
template<typename RandomNumberEngine >
void SetRandomValue (RandomNumberEngine &random_number_engine)
 
void SetValue (const std::int64_t value)
 
template<typename RandomNumberEngine >
std::int64_t GenerateCandidateValue (RandomNumberEngine &random_number_engine) const
 
template<typename RandomNumberEngine >
std::int64_t GenerateRandomValue (RandomNumberEngine &random_number_engine) const
 
std::int64_t GetValueFromState (std::int64_t state) const
 
std::int64_t GetStateFromValue (std::int64_t value) const
 

Public Attributes

std::int64_t lower_bound
 
std::int64_t upper_bound
 
std::int64_t num_states
 
std::int64_t value
 

Constructor & Destructor Documentation

◆ IntegerVariable()

openjij::utility::IntegerVariable::IntegerVariable ( const std::int64_t  lower_bound,
const std::int64_t  upper_bound 
)
inline

Member Function Documentation

◆ GenerateCandidateValue()

template<typename RandomNumberEngine >
std::int64_t openjij::utility::IntegerVariable::GenerateCandidateValue ( RandomNumberEngine &  random_number_engine) const
inline

References lower_bound, upper_bound, and value.

◆ GenerateRandomValue()

template<typename RandomNumberEngine >
std::int64_t openjij::utility::IntegerVariable::GenerateRandomValue ( RandomNumberEngine &  random_number_engine) const
inline

References lower_bound, and upper_bound.

◆ GetStateFromValue()

std::int64_t openjij::utility::IntegerVariable::GetStateFromValue ( std::int64_t  value) const
inline

References lower_bound, upper_bound, and value.

◆ GetValueFromState()

std::int64_t openjij::utility::IntegerVariable::GetValueFromState ( std::int64_t  state) const
inline

References lower_bound.

◆ SetRandomValue()

template<typename RandomNumberEngine >
void openjij::utility::IntegerVariable::SetRandomValue ( RandomNumberEngine &  random_number_engine)
inline

References lower_bound, upper_bound, and value.

◆ SetValue()

void openjij::utility::IntegerVariable::SetValue ( const std::int64_t  value)
inline

References lower_bound, upper_bound, and value.

Member Data Documentation

◆ lower_bound

std::int64_t openjij::utility::IntegerVariable::lower_bound

◆ num_states

std::int64_t openjij::utility::IntegerVariable::num_states

Referenced by IntegerVariable().

◆ upper_bound

std::int64_t openjij::utility::IntegerVariable::upper_bound

◆ value

std::int64_t openjij::utility::IntegerVariable::value

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