没有合适的资源?快使用搜索试试~ 我知道了~
首页IBM.ILOG.CPLEX.Optimization.Studio.Getting.Start.with.CPLEX.v12.4
IBM.ILOG.CPLEX.Optimization.Studio.Getting.Start.with.CPLEX.v12....
3星 · 超过75%的资源 需积分: 32 28 下载量 184 浏览量
更新于2023-03-16
评论 1
收藏 369KB PDF 举报
CPLEX英文学习资料。 IBM.ILOG.CPLEX.Optimization.Studio.Getting.Start.with.CPLEX.v12.4
资源详情
资源评论
资源推荐
IBM ILOG CPLEX Optimization Studio
Getting Started with CPLEX
Version12Release4
Copyright notice
Describes general use restrictions and trademarks related to this document and the software described in this document.
© Copyright IBM Corp. 1987, 2011
US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with
IBM Corp.
Trademarks
IBM, the IBM logo, ibm.com
®
, WebSphere
®
, and ILOG are trademarks or registered trademarks of International Business
Machines Corp., in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other
companies. A current list of IBM trademarks is available on the Web at Copyright and trademark information.
Adobe, the Adobe logo, PostScript, and the PostScript logo are either registered trademarks or trademarks of Adobe
Systems Incorporated in the United States, and/or other countries.
Linux is a registered trademark of Linus Torvalds in the United States, other countries, or both.
UNIX is a registered trademark of The Open Group in the United States and other countries.
Microsoft, Windows, Windows NT, and the Windows logo are trademarks of Microsoft Corporation in the United States,
other countries, or both.
Java and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and/or its affiliates.
Other company, product, or service names may be trademarks or service marks of others.
Further acknowledgements
IBM ILOG CPLEX states these additional registered trademarks and acknowledgements.
Additional registered trademarks
Python is a registered trademark of the Python Software Foundation.
MATLAB is a registered trademark of The MathWorks, Inc.
Acknowledgement of use: dtoa routine of the gdtoa package
IBM ILOG CPLEX acknowledges use of the dtoa routine of the gdtoa package, available at
http://www.netlib.org/fp/.
The author of this software is David M. Gay.
All Rights Reserved.
Copyright (C) 1998, 1999 by Lucent Technologies
Permission to use, copy, modify, and distribute this software and its documentation for any purpose and without
fee is hereby granted, provided that the above copyright notice appears in all copies and that both that the
copyright notice and this permission notice and warranty disclaimer appear in supporting documentation, and that
the name of Lucent or any of its entities not be used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission.
LUCENT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL LUCENT OR ANY OF ITS
ENTITIES BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF
CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH
THE USE OR PERFORMANCE OF THIS SOFTWARE.
(end of acknowledgement of use of dtoa routine of the gdtoa package)
© Copyright IBM Corporation 1987, 2011.
US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract
with IBM Corp.
Contents
Introducing CPLEX ..........v
What is CPLEX? .............v
Types of problems solved .........v
CPLEX components...........vi
Optimizer options ...........vii
Parallel optimizers ............vii
Data entry options............viii
What CPLEX is not ...........viii
What you need to know ..........viii
What’s in this manual ...........ix
Notation in this manual ..........ix
Related documentation ...........x
Chapter 1. Setting up CPLEX......1
Installing CPLEX .............1
Setting up CPLEX on Windows ........1
Setting up CPLEX for on GNU/Linux ......2
Setting up Eclipse for the Java API of CPLEX . . . 4
Setting up the Python API of CPLEX ......5
Directory structure of CPLEX .........5
Using the Component Libraries ........6
Chapter 2. Solving an LP with CPLEX . . 9
Overview ...............9
Problem statement ............9
Using the Interactive Optimizer ........9
Using Concert Technology in C++ .......10
Using Concert Technology in Java .......11
Using Concert Technology in .NET ......11
Using the Callable Library .........12
Using the Python API ...........14
Chapter 3. Interactive Optimizer tutorial 17
Starting CPLEX .............17
Using help...............17
Entering a problem ............19
Overview ..............19
Entering the example ..........19
Using the LP format ..........20
Entering data .............22
Displaying a problem ...........22
Verifying a problem with the display command 22
Displaying problem statistics .......23
Specifying item ranges..........24
Displaying variable or constraint names ....25
Ordering variables ...........26
Displaying constraints ..........26
Displaying the objective function ......26
Displaying bounds ...........26
Displaying a histogram of nonzero counts . . . 27
Solving a problem ............27
Overview ..............28
Solving the example ..........28
Solution options ............29
Displaying post-solution information .....30
Performing sensitivity analysis ........31
Writing problem and solution files.......32
Overview ..............32
Selecting a write file format ........32
Writing LP files ............33
Writing basis files ...........33
Using path names ...........34
Reading problem files ...........34
Overview ..............34
Selecting a read file format ........34
Reading LP files ............35
Using file extensions ..........36
Reading MPS files ...........36
Reading basis files ...........36
Setting CPLEX parameters .........37
Adding constraints and bounds .......38
Changing a problem ...........39
Overview ..............39
What can be changed?..........40
Changing constraint or variable names ....40
Changing sense ............40
Changing bounds ...........41
Removing bounds ...........41
Changing coefficients of variables ......41
Objective and RHS coefficients .......42
Deleting entire constraints or variables ....42
Changing small values to zero .......43
Executing operating system commands .....43
Quitting CPLEX .............44
Advanced features of the Interactive Optimizer . . 44
Chapter 4. Concert Technology tutorial
for C++ users ............47
The design of CPLEX in Concert Technology C++
applications ..............47
Compiling CPLEX in Concert Technology C++
applications ..............48
Testing your installation on UNIX ......48
Testing your installation on Windows .....48
In case of problems...........48
The anatomy of an Concert Technology C++
application ..............49
Constructing the environment: IloEnv ....49
Creating a model: IloModel ........50
Solving the model: IloCplex ........52
Querying results............52
Handling errors ............53
Building and solving a small LP model in C++ . . 53
Overview ..............54
Modeling by rows ...........55
Modeling by columns ..........55
Modeling by nonzero elements .......56
Writing and reading models and files......56
Selecting an optimizer ...........57
Reading a problem from a file: example ilolpex2.cpp 58
© Copyright IBM Corp. 1987, 2011 iii
Overview ..............58
Reading the model from a file .......58
Selecting the optimizer .........58
Accessing basis information ........59
Querying quality measures ........59
Modifying and re-optimizing ........59
Modifying an optimization problem: example
ilolpex3.cpp ..............60
Overview ..............60
Setting CPLEX parameters ........61
Modifying an optimization problem .....61
Starting from a previous basis .......61
Complete program ...........61
Chapter 5. Concert Technology tutorial
for Java users ...........63
Overview ...............63
Compiling CPLEX in Concert Technology Java
applications ..............63
Paths and JARs ............63
Adapting build procedures to your platform . . 63
In case problems arise ..........64
The design of CPLEX in Concert Technology Java
applications ..............65
The anatomy of a Concert Technology Java
application ..............65
Structure of an application ........65
Create the model ...........66
Solve the model ............67
Query the results ...........68
Building and solving a small LP model in Java . . 68
Example: LPex1.java ..........68
Modeling by rows ...........70
Modeling by columns ..........70
Modeling by nonzeros..........71
Chapter 6. Concert Technology tutorial
for .NET users ...........73
Presenting the tutorial ...........73
What you need to know: prerequisites .....73
What you will be doing ..........74
Describe ...............75
Model ................76
Solve ................79
Complete program ............80
Chapter 7. Callable Library tutorial. . . 81
The design of the CPLEX Callable Library ....81
Compiling and linking Callable Library applications 81
Overview ..............81
Building Callable Library applications on UNIX
platforms ..............82
Building Callable Library applications on Win32
platforms ..............82
How CPLEX works............83
Overview ..............83
Opening the CPLEX environment ......83
Instantiating the problem object ......84
Populating the problem object .......84
Changing the problem object .......84
Creating a successful Callable Library application 85
Overview ..............85
Prototype the model ..........85
Identify the routines to call ........85
Test procedures in the application ......85
Assemble the data ...........86
Choose an optimizer ..........86
Observe good programming practices ....87
Debug your program ..........87
Test your application ..........87
Use the examples ...........87
Building and solving a small LP model in C . . . 88
Reading a problem from a file: example lpex2.c . . 89
Adding rows to a problem: example lpex3.c . . . 90
Performing sensitivity analysis ........92
Chapter 8. Python tutorial ......95
Design of CPLEX in a Python application ....95
Starting the CPLEX Python API .......95
Accessing the module cplex .........95
Building and solving a small LP with Python . . . 96
Reading and writing CPLEX models to files with
Python ................97
Selecting an optimizer in Python .......98
Example: reading a problem from a file lpex2.py . . 98
Modifying and re-optimizing in the CPLEX Python
API.................99
Example: modifying a model lpex3.py .....99
Using CPLEX parameters in the CPLEX Python
API.................100
Chapter 9. MSF tutorial for CPLEX
users ...............103
CPLEX connector for MSF .........103
Using CPLEX as a plug-in SFS of MSF .....104
Using CPLEX as the class CplexSolver in MSF . . 107
Using CPLEX parameters in MSF connector . . . 109
Index ...............113
iv
Getting Started with CPLEX
Introducing CPLEX
This preface introduces CPLEX
®
.
What is CPLEX?
CPLEX consists of software components and options.
Types of problems solved
Defines the kind of problems that CPLEX solves.
IBM
®
ILOG
®
CPLEX Optimizer is a tool for solving linear optimization problems,
commonly referred to as Linear Programming (LP) problems, of the form:
Maximize (or Minimize) c
1
x
1
+c
2
x
2
+...+ c
n
x
n
subject to
a
11
x
1
+a
12
x
2
+...+ a
1n
x
n
~b
1
a
21
x
1
+a
22
x
2
+...+ a
2n
x
n
~b
2
...
a
m1
x
1
+a
m2
x
2
+...+ a
mn
x
n
~b
m
with these bounds
l
1
≤ x
1
≤ u
1
...
l
n
≤ x
n
≤ u
n
where ~ can be ≤, ≥, or =, and the upper bounds u
i
and lower bounds l
i
may be
positive infinity, negative infinity, or any real number.
The elements of data you provide as input for this LP are:
Objective function coefficients c
1
,c
2
, ... , c
n
Constraint coefficients
a
11
,a
21
, ... , a
n1
...
a
m1
,a
m2
, ... , a
mn
Righthand sides b
1
,b
2
,...,b
m
Upper and lower bounds u
1
,u
2
,...,u
n
and l
1
,l
2
, ... , l
n
The optimal solution that CPLEX computes and returns is:
Variables x
1
,x
2
,...,x
n
CPLEX also can solve several extensions to LP:
v Network Flow problems, a special case of LP that CPLEX can solve much faster
by exploiting the problem structure.
© Copyright IBM Corp. 1987, 2011 v
剩余131页未读,继续阅读
u010922835
- 粉丝: 1
- 资源: 15
上传资源 快速赚钱
- 我的内容管理 收起
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
会员权益专享
最新资源
- stc12c5a60s2 例程
- Android通过全局变量传递数据
- c++校园超市商品信息管理系统课程设计说明书(含源代码) (2).pdf
- 建筑供配电系统相关课件.pptx
- 企业管理规章制度及管理模式.doc
- vb打开摄像头.doc
- 云计算-可信计算中认证协议改进方案.pdf
- [详细完整版]单片机编程4.ppt
- c语言常用算法.pdf
- c++经典程序代码大全.pdf
- 单片机数字时钟资料.doc
- 11项目管理前沿1.0.pptx
- 基于ssm的“魅力”繁峙宣传网站的设计与实现论文.doc
- 智慧交通综合解决方案.pptx
- 建筑防潮设计-PowerPointPresentati.pptx
- SPC统计过程控制程序.pptx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
评论1