					META Integrated Tool Engine Demo

*************************************************************************************************************************************             

DARPA Marking
 
Delivered to the U.S. Government in Accordance with Contract FA8650-10-C-7080.
 
 
Export Control Marking
 
	EXPORT CONTROLLED
	ECCN#             EAR99  
	Warning:  This document contains technical data which is controlled under the Bureau of Industry & Security’s Export 
	Administration Regulations and may not be exported or re-exported without authorization by the Bureau of Industry & Security.
	Diversion contrary to US law is prohibited.

License Marking
 
       (c) 2011 United Technologies Corp.
       Developed with the sponsorship of the Defense Advanced Research Projects Agency (DARPA).
 
       Permission is hereby granted, free of charge, to any person obtaining a copy of this data, 
       including any software or models in source or binary form, as well as any drawings, specifications, and 
       documentation (collectively "the Data"), to deal in the Data without restriction, including without limitation the rights to use, 
       copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Data, and to permit persons to whom the Data is 
       furnished to do so, subject to the following conditions:
 
       The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Data.
 
       THE DATA IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 
       MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS, SPONSORS, DEVELOPERS, 
       CONTRIBUTORS, OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 
       TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE DATA OR THE USE OR OTHER DEALINGS IN THE DATA.

*************************************************************************************************************************************

1. Compilation

This software requires Java environment, and the following third party software to compile.  It is your responsibility to determine whether you 
can download, or buy or use them. 

1) JAVA: 
http://www.java.com

2) ANT 
http://ant.apache.org

3)JDOM:
http://www.jdom.org

4)AMPL
http://www.ampl.com
You also need Ipopt solver for it.
https://projects.coin-or.org/Ipopt

5)JAXEN 
http://www.jaxen.org/

The current folder name is CURFOLDER (for example: EngineDemo3_3)
Install AMPL in CURFOLDER\ampl or any preferred folder

Put the jdom.jar file from above in CURFOLDER\lib
Put the jaxen-1.1.1.jar file from above in CURFOLDER\lib
Install AMPL in CURFOLDER\ampl or whereever you want

Make sure that Java and Ant are properly configured:
1) The environment variables JAVA_HOME, CLASSPATH and ANT_HOME  are set.
2) java, and ant are on the path. (...;c:\ant\apache-ant-1.7.0\bin;c:\java\jdk1.6.0\bin;....)
 
cd CURFOLDER\Engine
ant -f make.xml all

Then copy the CURFOLDER\Engine\src\dist\engine.jar to CURFOLDER.
Also copy jdom.jar to CURFOLDER

cd CURFOLDER\RMI
ant -f make.xml all
Then copy the CURFOLDER\Engine\src\dist\rmi.jar to CURFOLDER\lib.

2. Configuration

2.1 opt.bat

Change "-DAMPL_HOME" to point to CURFOLDER\ampl or whereever your AMPL is.
If you have spaces in your path, make sure to double quotes your path.

2.2 GGFF Demo New L0 Engine9.xlsm

Select "FileIO" sheet, and set:

 InputFolderPath=CURFOLDER
 OutputFolderPath=CURFOLDER\data

If you have spaces in the path, please make sure NOT to put in quotes.

2.3 startdemo1.bat and startdemo2.bat

Change ALL the "set DemoPath=xxx" to point to CURFOLDER.
Example:

set DemoPath=D:\EngineDemoV3_3built


3. Run

Enter CURFOLDER folder under DOS prompt:

type in:

  startdemo1.bat

It will prompt you to press a key.  Wait until the RMI Reigstry finished popping up, press a key.
Wait until SOA Server popped up, type in:

startdemo2.bat

Again, press a key.  It will start all the services and one GUI: META II Integrated Tool.

Click “Load Script”, you will see the job control language file EngineL0Analysis.xml where all the tasks are listed there.

Click “Execute”, all the tasks in that file will be executed:

You will first see the AEE is enumerating, and then the optimization will be performed, and results are stored to repository, 
and then the adaptability and cost module produce the analysis result:
by clicking "prev Algo" and "new algo", you can select the previous algorithm and the new algorithm.
After selecting one of them, the analysis is finished.
The META II Integrated Tool will show "All completed".


Note:

After running the above, shut down following the shut down procedure below, and you can run it again.

Shutdown procedure:
Close "META II Integrated Tool", close ALL DOS windows including "RMI Registry", "SOA Server".
Use task manager to remove the AEEController.
