Several special modes have been created for using the .exe file. The modes are:
1. Normal Mode (1 argument).
Arg1 = mode number (i.e. 1).
Example: IFs.exe 1 This behaves just like calling IFs.exe without an argument.
2. Drill Down Mode (3 arguments). This was created so that a program that was executing IFs (such as the Computer Assisted Reasoning System or CARS of the RAND Pardee Center and Evolving Logics) can identify and load a particular scenario or case from the SensitivityInput.mdb file (see below), run it, and be positioned for further analysis of it using the IFs interface.
Arg1 = mode number (i.e. 2).
Arg2 = run number from the SensitivityInput.mdb file (see below).
Arg3 (optional) = run horizon (e.g. 2050).
Example: IFs.exe 2 54 2020. This would pick the 54th scenario from the input file, load the parameters associated with it, run the model, and turn control to the user.
3. Invisible Mode (2 arguments). This was created so that a program that was executing IFs (again like CARS) or the sensitivity option of IFs itself could run multiple scenarios, placing results for selected variables into an input file. The scenario descriptions must again be in the SensitivityInput.mdb file. The variables that the user wants to see as outputs must be specified in the SensitivityOutputVars.mdb. The results generated by IFs will be put for each scenario into a SensitivityOutput.mdb file.
Arg1 = mode number (i.e. 3)
Arg2 = run horizon (e.g. 2015)
Example: IFs.exe 3 2015. If there are many scenarios in the SensitivityInput.mdb file, this can create an execution of IFs that runs for a very long time (even days). It does not need a run number from SensitivityINput.mdb because it runs all scenarios/cases in that file.
4. Invisible Single Run Mode (2 arguments). This mode was created so that a user can load a particular scenario, run it, and put selected results into an output file. The variables that the user wants to see as outputs must be specified in the SensitivityOutputVars.mdb. The results generated by IFs will be put for the selected scenario or case into a SensitivityOutput.mdb file.
Arg1=mode number (i.e. 4)
Arg2 = run number from the SensitivityInput.mdb file.
Example: IFs.exe 4 8
5. Invisible Web Mode (3 arguments). This mode was created specifically to run IFs.exe on the web. The web-based version of IFs only includes the interface or GUI elements of IFs. For actual calculations it relies on the .exe file of IFs created in Visual Basic development mode. When a model run is called for on the web, it passes appropriate arguments to the .exe. The result is a run of the model with full results put into the working.run file.
Arg1 = mode number (i.e. 5)
Arg2 = run horizon (e.g. 2020)
Example: IFs.exe 5 2020
6. Invisible Batch Scenario Mode (3 arguments). This mode loads and runs all of the .sce files in the Scenario directory of IFs and puts results into .run files with the same name as the .sce files. It processes also all subdirectories of the Scenario directory. If there are many .sce files, this can take a very long time to run.
Arg1 = mode number (i.e. 6)
Arg2 = run horizon (e.g. 2100)
Arg3 = -1 if it is being run on a stand-alone, non-web installation; = session number if it is being run on the web (i.e. the session number where it is going to look for the scenario file directory and subdirectories (e.g. ifs\scenario\session0)
Example: IFs.exe 6 2100 -1 (will run all scenarios for a stand-alone application).
All of the above examples assume that IFs is being initiated from a command line or inside a program (and the full path for the model’s .exe must be given). In a VB development environment, the modes can be turned on by going to the Project option, IFs Properties sub-option, the Make Tab, and setting the appropriate arguments in the command line (e.g. 6 2005 -1). Note that the name of the model is not specified in the command line.
Some of the above modes require one or all of three files. These were once text files (.dat) but have been converted to .mdb (Access) files to make them more transparent to the user. See examples in the IFs Sensitivity directory so as to understand the field specifications.
SensitivitiyOutputVars.mdb file. It is necessary to select the output variables of interest to you in the set of sensitivity runs. The model stores these in a file named SensitivityOutputVars.dat. You can select up to 500 of these (each country/region counts as one output variable even for the same variable).