TIM file reader - the stage information for a stochastic programming instance in SMPS format.
This is a reader for the time file of a stochastic programming instance in SMPS format. The three files that must be read are:
Alternatively, it is possible to create a .smps file with the relative path to the .cor, .tim and .sto files. A file reader is available for the .smps file.
Details regarding the SMPS file format can be found at: Birge, J. R.; Dempster, M. A.; Gassmann, H. I.; Gunn, E.; King, A. J. & Wallace, S. W. A standard input format for multiperiod stochastic linear programs IIASA, Laxenburg, Austria, WP-87-118, 1987
Definition in file reader_tim.h.
#include "scip/def.h"#include "scip/type_cons.h"#include "scip/type_reader.h"#include "scip/type_result.h"#include "scip/type_retcode.h"#include "scip/type_scip.h"#include "scip/type_var.h"Go to the source code of this file.
Functions | |
| SCIP_RETCODE | SCIPincludeReaderTim (SCIP *scip) |
| SCIP_RETCODE | SCIPreadTim (SCIP *scip, const char *filename, SCIP_RESULT *result) |
| SCIP_RETCODE | SCIPfreeReaderdataTim (SCIP *scip) |
| SCIP_Bool | SCIPtimHasRead (SCIP_READER *reader) |
| int | SCIPtimGetNStages (SCIP *scip) |
| const char * | SCIPtimGetStageName (SCIP *scip, int stagenum) |
| const char * | SCIPtimConsGetStageName (SCIP *scip, const char *consname) |
| int | SCIPtimFindStage (SCIP *scip, const char *stage) |
| SCIP_VAR ** | SCIPtimGetStageVars (SCIP *scip, int stagenum) |
| SCIP_CONS ** | SCIPtimGetStageConss (SCIP *scip, int stagenum) |
| int | SCIPtimGetStageNVars (SCIP *scip, int stagenum) |
| int | SCIPtimGetStageNConss (SCIP *scip, int stagenum) |
| SCIP_RETCODE SCIPfreeReaderdataTim | ( | SCIP * | scip | ) |
frees the reader data for the tim file
| scip | the SCIP data structure |
Definition at line 934 of file reader_tim.c.
References assert(), freeReaderdata(), NULL, READER_NAME, SCIP_OKAY, SCIPfindReader(), SCIPfreeReaderdataTim(), and SCIPreaderGetData().
Referenced by SCIP_DECL_READERREAD(), SCIPfreeReaderdataTim(), and SCIPreadCor().
| SCIP_Bool SCIPtimHasRead | ( | SCIP_READER * | reader | ) |
| reader | the file reader itself |
Definition at line 960 of file reader_tim.c.
References assert(), FALSE, NULL, READER_NAME, SCIP_Bool, SCIP_STRINGEQ, SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimHasRead().
Referenced by SCIP_DECL_READERREAD(), and SCIPtimHasRead().
| int SCIPtimGetNStages | ( | SCIP * | scip | ) |
| scip | SCIP data structure |
Definition at line 978 of file reader_tim.c.
References assert(), NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetNStages().
Referenced by addScenariosToReaderdata(), addScenarioVarsAndConsToProb(), readSto(), removeCoreVariablesAndConstraints(), SCIP_DECL_READERREAD(), and SCIPtimGetNStages().
| const char * SCIPtimGetStageName | ( | SCIP * | scip, |
| int | stagenum ) |
| scip | SCIP data structure |
| stagenum | the number of the requested stage |
Definition at line 998 of file reader_tim.c.
References assert(), TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetStageName().
Referenced by buildScenarioTree(), createReaderdata(), and SCIPtimGetStageName().
| const char * SCIPtimConsGetStageName | ( | SCIP * | scip, |
| const char * | consname ) |
| scip | SCIP data structure |
| consname | the constraint to search for |
Definition at line 1020 of file reader_tim.c.
References assert(), i, TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPconsGetName(), SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimConsGetStageName().
Referenced by readIndep(), and SCIPtimConsGetStageName().
| int SCIPtimFindStage | ( | SCIP * | scip, |
| const char * | stage ) |
| scip | SCIP data structure |
| stage | the name of the requested stage |
Definition at line 1062 of file reader_tim.c.
References assert(), i, NULL, READER_NAME, SCIP_STRINGEQ, SCIPABORT, SCIPerrorMessage, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimFindStage().
Referenced by addScenarioVarsAndConsToProb(), readScenarios(), and SCIPtimFindStage().
| scip | SCIP data structure |
| stagenum | the number of the requested stage |
Definition at line 1101 of file reader_tim.c.
References assert(), TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetStageVars().
Referenced by addScenarioVarsAndConsToProb(), removeCoreVariablesAndConstraints(), and SCIPtimGetStageVars().
| scip | SCIP data structure |
| stagenum | the number of the requested stage |
Definition at line 1123 of file reader_tim.c.
References assert(), TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetStageConss().
Referenced by addScenarioVarsAndConsToProb(), removeCoreVariablesAndConstraints(), and SCIPtimGetStageConss().
| int SCIPtimGetStageNVars | ( | SCIP * | scip, |
| int | stagenum ) |
| scip | SCIP data structure |
| stagenum | the number of the requested stage |
Definition at line 1145 of file reader_tim.c.
References assert(), TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetStageNVars().
Referenced by addScenarioVarsAndConsToProb(), removeCoreVariablesAndConstraints(), and SCIPtimGetStageNVars().
| int SCIPtimGetStageNConss | ( | SCIP * | scip, |
| int | stagenum ) |
| scip | SCIP data structure |
| stagenum | the number of the requested stage |
Definition at line 1167 of file reader_tim.c.
References assert(), TimInput::nstages, NULL, READER_NAME, SCIP_STRINGEQ, SCIPfindReader(), SCIPreaderGetData(), SCIPreaderGetName(), and SCIPtimGetStageNConss().
Referenced by addScenarioVarsAndConsToProb(), removeCoreVariablesAndConstraints(), and SCIPtimGetStageNConss().