RMOL Logo Get Revenue Management Optimisation Library at SourceForge.net. Fast, secure and Free Open Source software downloads

rmol.cpp File Reference

#include <assert.h>
#include <iostream>
#include <sstream>
#include <fstream>
#include <string>
#include <boost/date_time/posix_time/posix_time.hpp>
#include <boost/date_time/gregorian/gregorian.hpp>
#include <boost/program_options.hpp>
#include <rmol/RMOL_Service.hpp>
#include <rmol/config/rmol-paths.hpp>

Go to the source code of this file.

Functions

const std::string K_RMOL_DEFAULT_LOG_FILENAME ("rmol.log")
const std::string K_RMOL_DEFAULT_INPUT_FILENAME ("class.csv")
void initDefaultValuesForSellupProbabilityVector (RMOL::SellupProbabilityVector_T &ioSellUpProbabilityVector)
template<class T >
std::ostream & operator<< (std::ostream &os, const std::vector< T > &v)
int readConfiguration (int argc, char *argv[], int &ioRandomDraws, double &ioCapacity, RMOL::SellupProbabilityVector_T &ioSellupProbabilityVector, short &ioMethod, std::string &ioInputFilename, std::string &ioLogFilename)
int main (int argc, char *argv[])

Variables

const int K_RMOL_DEFAULT_RANDOM_DRAWS = 100000
const double K_RMOL_DEFAULT_CAPACITY = 500.0
const short K_RMOL_DEFAULT_METHOD = 0
const int K_RMOL_EARLY_RETURN_STATUS = 99

Function Documentation

const std::string K_RMOL_DEFAULT_LOG_FILENAME ( "rmol.log"  )

Default name and location for the log file.

Referenced by readConfiguration().

const std::string K_RMOL_DEFAULT_INPUT_FILENAME ( "class.csv"  )

Default name and location for the (CSV) input file.

Referenced by readConfiguration().

void initDefaultValuesForSellupProbabilityVector ( RMOL::SellupProbabilityVector_T ioSellUpProbabilityVector)

Fill a vector of default sell-up probability values.

Definition at line 47 of file rmol.cpp.

Referenced by readConfiguration().

template<class T >
std::ostream& operator<< ( std::ostream &  os,
const std::vector< T > &  v 
)

Definition at line 57 of file rmol.cpp.

int readConfiguration ( int  argc,
char *  argv[],
int &  ioRandomDraws,
double &  ioCapacity,
RMOL::SellupProbabilityVector_T ioSellupProbabilityVector,
short &  ioMethod,
std::string &  ioInputFilename,
std::string &  ioLogFilename 
)

Variable Documentation

const int K_RMOL_DEFAULT_RANDOM_DRAWS = 100000

Default number of random draws to be generated (best if over 100).

Definition at line 25 of file rmol.cpp.

Referenced by readConfiguration().

const double K_RMOL_DEFAULT_CAPACITY = 500.0

Default value for the capacity of the resource (e.g., a flight cabin).

Definition at line 28 of file rmol.cpp.

Referenced by readConfiguration().

const short K_RMOL_DEFAULT_METHOD = 0

Default probability that a demand group buys the next higher fare products when the products which they came for are not available. Default name and location for the Revenue Management method to be used.

  • 0 = Monte-Carlo
  • 1 = Dynamic Programming
  • 2 = EMSR
  • 3 = EMSR-a
  • 4 = EMSR-b
  • 5 = EMSR-a with sell up

Definition at line 44 of file rmol.cpp.

Referenced by readConfiguration().

Early return status (so that it can be differentiated from an error).

Definition at line 64 of file rmol.cpp.

Referenced by main(), and readConfiguration().