MS-E2140. Short introduction to CPLEX studio

Size: px
Start display at page:

Download "MS-E2140. Short introduction to CPLEX studio"

Transcription

1 Linear Programming MS-E2140 Short introduction to CPLEX studio Disclaimer: This tutorial is not a complete introduction to the full features and potentiality of CPLEX Optimization Studio. More detailed documentation is available at

2 Features CPLEX studio is an optimization package which includes A modeling development tool: IBM ILOG OPL A powerful optimization package: IBM ILOG CPLEX OPL is a modeling language for optimization problems with intutitive syntax that facilitates the implementation of mathematical models CPLEX is one of the state-of-the-art commercial solvers for various types of optimization problems including: Linear programming problems Integer and mixed integer prgramming problems Quadratic programming problems CPLEX studio provides a development environment that facilitates the creation and solution of mathematical programming models and the analysis of the results Models are independent of the data they use meaning, e.g., that the model code needs not be changed for solving different instances of the same problem

3 Resources A full version of CPLEX studio is installed in the lab machines A free trial version (90 days evaluation period and with limitations on the maximum size of solvable problems) is available through the IBM website Full official documentation is available at Examples. Several examples of projects can be opened and explored within CPLEX studio. To load them from the start window main menu click: File -> Import -> Example... (then double click IBM ILOG CPLEX Examples ) OPL keywords. From the start window: Help -> Search (type OPL keywords) OPL functions. From the start window: Help -> Search (type OPL functions)

4 Creating an empty project The main working unit in CPLEX studio is the project which groups one or more models together with data. It is composed of three types of files Model files (.mod): data declarations, model definition (decision variables, objective function, constraints); Data files (.dat): Actual values for the data declared in model files; Settings files (.ops): Specify changes to the default settings in OPL, (parameters for the solution algorithm, display options,...) To create a new project select File -> New -> OPL Project from the main window s menu. Then choose a name and location folder and click Finish. A project contains one or more run configurations each specifying a model instance by linking the model with a particular set of data (and, optionally, settings)

5 Project name Run configuration Model file Data file To create new model or data files in a project right-click on the project name and then select new -> model or new -> data To create an empty run configuration right-click on the Run Configurations icon and then select New -> Run configuration To add a file to a run configuration right-click on the file name, then select Add to Run Configuration and choose the configuration To remove a file from a configuration right-click on its name inside the configuration and select Delete

6 A simple project This section guides you to create a simple project, and to solve the corresponding optimization problem We will implement and solve part (b) of Exercise 1.1 from the first exercise session Create the project Start by creating a project with a model file, a data file, and one run configuration Data declarations The first step is to define the data needed by the model in the model file.

7 First recall the model to be implemented Maximize z = 150 x x 2 80 y y 2 20 y 3 s.t x x y 1 Production time of Department A 0.30 x x y 2 Production time of Department B 0.20 x x y 3 Production time of Department C y 1 10 Max. overtime of Department A y 2 6 Max. overtime of Department B y 3 8 Max. overtime of Department C x 1, x 2 0, y 1, y 2, y 3 0 Non-negativity x 1, x 2 integer Integrality where y i : Total number of overtime hours for department i x j : Total number of units produced of product j

8 A data specification is called data item and consists of a data type Integer (OPL keyword int) Real (OPL keyword float) String (OPL keyword string) and a data structure ( scalar, range, set, array, or tuple) In our model we will need to specify the following data items Model data Data type Data struct. OPL Syntax Set of department names string Set {string} Departments =...; Set of product names string Set {string} Products =...; Departments manufacturing time for each product float 2-d array (matrix) float Manuf_Time[ ][ ] =...; Departments time capacity float 1-d array float Time_Capacity[ ] =...; Products unit revenue float 1-d array float Revenue[ ] =...; Max. Departments overtime float 1-d array float Max_Overtime[ ] =...; Overtime cost for each Dept. float 1-d array float Overtime_Cost[ ] =...;

9 Set data structures The following is the declaration of the Departments set {string} Departments =...; The curly brackets { } indicate that the structure Departments is a set, and the keyword string specifies the type of its elements Array data structures The following is the declaration of the structure specifying the manufacturing time for each product float Manuf_Time[Departments][Products] =...; The double brackets [][] indicate that the structure Manuf_Time is a matrix, and the keyword float specifies the type of its elements The sets Departments and Products are used to index the array. With this declaration each element i, j of Manuf_Time is associated with element i of the set Departments, and element j of set Products To define a one dimensional array just put one single pair of brackets [] Note: All declarations (and other instructions) must end with a ;

10 Note that all data declarations ended with the syntax = ; This indicates that the actual values of the elements in the data item are not specified in the declaration, but somewhere else (e.g., in the data file) -> Double-click on the model file and type the following declarations:

11 Data initializations Data items whose declaration ends with the syntax = ; in the model file can be initialized in the data file Alternatively data items can be intialized directly in the model file by replacing = ; with the initialization when they are declared Set intialization The following is the initialization of the Departments set Departments = { A, B, C }; The initialization just specifies the element values within the brackets. Note that the value types must match those defined in the declaration. In this case, elements are strings, and must be enclosed in, i.e. the syntax for any element s of type string is s. Similarly, we intialize the set Products: Products = {"Prod_1", "Prod_2"};

12 Array initialization For 1-d arrays values of the elements can be simply inserted inside the brackets separated by commas The following is the initialization of the Time_Capacity array Time_Capacity = [100, 36, 50]; Since in the initialization of Departments its elements are listed in the order A, B, C, the value 100 will be associated with A, 36 with B, and 50 with C. For 2-d arrays each row is inserted as it was a 1-d array, and rows are separated by commas. The following is the initialization of the Manuf_Time array Manuf_Time = [[1.00, 0.35], [0.30, 0.20], [0.20, 0.50]];

13 -> Double-click on the data file and type the following definitions:

14 Decision variables Decision variable declarations are similar to those of data items, but do not require initialization. Variables can be of type: Integer (OPL keyword int) Real (OPL keyword float) Boolean (0 1 values, OPL keyword boolean) In our model we need the following variables Model decision variable Var. Type Data struct. Total number of overtime hours for each department i (y i ) Total number of manufactured units for each product j (x j ) OPL Syntax float Array dvar float+ Overtime_h[Departments]; int Array dvar Int+ Production[Products]; Declaration of variables is similar to that of data items and requires: a type, a data structure, a name, optionally a domain (range of values)

15 Declaration of a single variable (a variable z not part of our model) dvar float+ z in ; dvar is the keyword used to identify variable declarations, the variable type is specified by the keyword float; the optional sign + indicates that the variable can take only non-negative values in specifies that the variable can have only values between 0 and 100 (instead of numbers like 0 and 100 data items can also be used) Declaration of an array of variables (variables y i of our model) dvar float+ Overtime_h[Departments]; Overtime_h is the name of the array of variables The variable data structure is defined by the brackets as for data items. In this case, Overtime_h is an array of float variables The argument Departments inside the brackets specifies that each variable in the array is associated with an element of Departments Note: the keyword infinity specifies the largest possible float number, and similarly does maxint for integers

16 -> Add the variable declarations to the model file:

17 Variable expressions and operators Decision variables and data items can be combined to define more complex expressions, constraints, or objective functions For this we need operators and aggregators to combine different variables and data items For example in our model we may want to define the total profit z = 150 x x 2 80 y y 2 20 y 3 To do this we can first define the following variable expressions dexpr float revenue = sum (j in Products) Production[j]*Revenue[j]; dexpr float cost = sum (i in Departments) Overtime_h[i]*Overtime_cost[i]; (150 x x 2 ) (80 y y y 3 ) Note: Variable expressions can then be used to defined constraints or the objective function

18 Consider the first of the two expressions above: dexpr is the OPL keyword used to declare decision expressions float is the type of the new decision expression The aggregator sum( ) expression returns the sum over all the elements indexed in parenthesis of the following expression (j in Products) indexes all items of the set Products, Production[j]*Revenue[j] is the expression summed over all items Note that this works because in the their declaration, the arrays Production and Revenue have both been defined over the set Products (e.g., dvar int+ Production [Products];) Using the two expressions just defined, we can define the profit dexpr float profit = revenue - cost; Note: Don t multiply two variables in a dexpr as that would yield a non-linear model! Also, you can t use the syntax type+ for a dexpr

19 Indexing with filtering When indexing the items of a set it is also possible to restrict the selection according to some criteria. The following are two examples: sum (i in Departments : Overtime_Cost[i] < 60) Overtime_h[i]*Overtime _Cost[i]; Filtering condition sum (j in Products : j > Prod_1 ) Production[j]*Revenue[j]; Note the use of the sintax : to separate the filtering condition from the indexing expession inside the parentheses Common aggregators for integer and float expressions sum (summations) prod (products) minima (min of a collection of related expressions) maxima (max of a collection of related expressions) // selects only elements coming after Prod_1 in the declaration of Products

20 Objective function An obj. function consists of a keyword maximize or minimize followed by an expression to optimize Since in our model we are maximizing the profit, which we already defined as a dexpr, we can just write maximize profit; Note: It is optional to define an objective function. If you don t, you can still solve the model to find just a feasible solution Constraints All constraints must be put inside a block starting with the syntax subject to { and ending with } The quantifier forall( ) can be used to specify multiple constraints compactly, each associated with one element indexed in parenthesis.

21 In our model, we have two types of constraints Constraints on the maximum production time for each Department In mathematical notation these could be written compactly as j P t ij x j T i + y i, i D where D denotes the set of Departments, P the set of products, t ij is the manufacturing time of Dept. i for product j, and T i denotes the time capacity of Dept. i In OPL we can translate the above using quantifiers and aggregators: forall(i in Departments) sum(j in Products) Manuf_Time[i][j]*Production[j] <= Time_Capacity[i] + Overtime_h[i]; Constraints on the maximum overtime for each Department Similarly as above we can write: forall(i in Departments) Overtime_h[i] <= Max_Overtime[i];

22 Note: The last constraints on the max. overtime for each Department actually only express a maximum value each variable y i can assume As mentioned when describing decision variable, the same can be imposed by specifying a domain when declaring the variables y For variables y this can be done by changing their declaration to dvar float+ Overtime_h[i in Departments] in 0.. Max_Overtime[i]; If variables y are declared in this way, then the constraints on the max. overtime for each Department of the previous slide are not needed -> This is generally a preferable way of specifying maximum (or minimum) values for a set of variables

23 Recall that each constraint definition ends with ;, and that all constraints have to be included inside a block like this subject to{... } -> Add the objective function and constraints to the model file

24 The model can now be solved -> Right-click on the run configuration icon and select Run this Righ-click here and select Run this to solve the model After the problem is solved the obj. function value will be displayed here The values of the decision variables and expressions are displayed here, or alternatively you can click here The optimal solution is x 1 = 82, x 2 = 80, y 1 = 10, y 2 = 4.6, y 3 = 6.4 with profit 16,797

25 Other useful commands Here we briefly examine some other useful features and structures of OPL that were not used in the previous example Range data structures Integer ranges are often used in arrays and decision variable declarations, in aggregate operators, queries, and quantifiers An integer range is specified by using the keyword range, and by giving its lower and upper bounds, as in the example below range Rows = 1..10; The above declares a range named Rows with bounds 1 and 10 (i.e., the interval [1,, 10]). The lower and upper bounds can also be expressions int n = 8; range Rows = n+1..2*n+1;

26 Typical uses of ranges are as an array index in an array declaration For example, in our model we could define Departments as a range rather than a set, and still use it in the declaration of the arrays equivalently range Departments = 1..3; float Time_Capacity[Departments]; float Time_Capacity[1..3]; One advantage over using sets, is that CPLEX does not store explicitly all the elements of the range, but it does store all elements of a set to define the domain of a variable We already discussed how to define the domain of a variable or an array of variables

27 as an iteration range For example, for defining constraints range Departments = 1..3; range Products = 1..2; forall(i in Departments) sum(j in Products) Manuf_Time[i][j]*Production[j] Overtime_h[i] <= Time_Capacity[i]; The syntax is the same as if Departments and Products were sets One advantage is that now Departments and Products are numbers, and we can use arithmetic operators in the filtering condition. Example For a description of operators see the summary at forall(i in Departments : i mod 2 == 0) the end or official CPLEX studio documentation sum(j in Products : j < 2 ) Manuf_Time[i][j]*Production[j] Overtime_h[i] <= Time_Capacity[i];

28 More ways of initializing sets Ranges can be converted into sets by using the keyword asset For example, the following declarations (in the model file) range Departments = 1..3 {int} Departments_Sets = asset(departments) define Departments as the interval [1,...,3] and then a corresponding set Departments_Sets = {1, 2, 3} Sets can be initialized as subsets of other sets (in the model file). The following are two examples: {string} Departments = { Dep1, Dep2, Dep3 }; {string} Sub_Departments = {i i in Departments : i!= Dep1 }; {int} Departments = asset(1..3); {int} Sub_Departments = {i i in Departments : i > 1};

29 Some operators (Arithmetic) Type Operator Description +, -, *, / Usual math operators infinity Represents the infinite abs(f) The absolute value of f float ceil(f) The smallest integer greater than or equal to f floor(f) The largest integer less than or equal to f trunc(f) The integer part of f frac(f) The fractional part of f round(f) The nearest integer to f Type Operator Description +, -, *, / Usual math operators int x mod y or x % y The integer remainder of x divided by y abs(f) The absolute value of f maxint The greatest integer

30 Some operators (Symbolic) Type Operator Description first, last First (last) element in the set list item The n-th element in the set card Number of elements in the set set next, prev Next (previous) element in the set list a inter b Intersection a union b Union a diff b Difference Type Operator Description == Equivalent to string!= Different from

31 Some operators (Symbolic) Type Operator Description && Conjunction (logical "and") Disjunction (logical "or") boolean == Equivalence Important!= Difference (exclusive "or")! Negation (logical "not") Get used to the help system included in CPLEX studio: -> Click Help from the main menu and then select Search or Help Contents

Microsoft Access 3: Understanding and Creating Queries

Microsoft Access 3: Understanding and Creating Queries Microsoft Access 3: Understanding and Creating Queries In Access Level 2, we learned how to perform basic data retrievals by using Search & Replace functions and Sort & Filter functions. For more complex

More information

Microsoft Excel 2010 Part 3: Advanced Excel

Microsoft Excel 2010 Part 3: Advanced Excel CALIFORNIA STATE UNIVERSITY, LOS ANGELES INFORMATION TECHNOLOGY SERVICES Microsoft Excel 2010 Part 3: Advanced Excel Winter 2015, Version 1.0 Table of Contents Introduction...2 Sorting Data...2 Sorting

More information

EXCEL SOLVER TUTORIAL

EXCEL SOLVER TUTORIAL ENGR62/MS&E111 Autumn 2003 2004 Prof. Ben Van Roy October 1, 2003 EXCEL SOLVER TUTORIAL This tutorial will introduce you to some essential features of Excel and its plug-in, Solver, that we will be using

More information

A Little Set Theory (Never Hurt Anybody)

A Little Set Theory (Never Hurt Anybody) A Little Set Theory (Never Hurt Anybody) Matthew Saltzman Department of Mathematical Sciences Clemson University Draft: August 21, 2013 1 Introduction The fundamental ideas of set theory and the algebra

More information

Basic Use of the TI-84 Plus

Basic Use of the TI-84 Plus Basic Use of the TI-84 Plus Topics: Key Board Sections Key Functions Screen Contrast Numerical Calculations Order of Operations Built-In Templates MATH menu Scientific Notation The key VS the (-) Key Navigation

More information

Useful Mathematical Symbols

Useful Mathematical Symbols 32 Useful Mathematical Symbols Symbol What it is How it is read How it is used Sample expression + * ddition sign OR Multiplication sign ND plus or times and x Multiplication sign times Sum of a few disjunction

More information

CPLEX Tutorial Handout

CPLEX Tutorial Handout CPLEX Tutorial Handout What Is ILOG CPLEX? ILOG CPLEX is a tool for solving linear optimization problems, commonly referred to as Linear Programming (LP) problems, of the form: Maximize (or Minimize) c

More information

Name: Class: Date: 9. The compiler ignores all comments they are there strictly for the convenience of anyone reading the program.

Name: Class: Date: 9. The compiler ignores all comments they are there strictly for the convenience of anyone reading the program. Name: Class: Date: Exam #1 - Prep True/False Indicate whether the statement is true or false. 1. Programming is the process of writing a computer program in a language that the computer can respond to

More information

Creating Basic Excel Formulas

Creating Basic Excel Formulas Creating Basic Excel Formulas Formulas are equations that perform calculations on values in your worksheet. Depending on how you build a formula in Excel will determine if the answer to your formula automatically

More information

Welcome to Basic Math Skills!

Welcome to Basic Math Skills! Basic Math Skills Welcome to Basic Math Skills! Most students find the math sections to be the most difficult. Basic Math Skills was designed to give you a refresher on the basics of math. There are lots

More information

COMP 250 Fall 2012 lecture 2 binary representations Sept. 11, 2012

COMP 250 Fall 2012 lecture 2 binary representations Sept. 11, 2012 Binary numbers The reason humans represent numbers using decimal (the ten digits from 0,1,... 9) is that we have ten fingers. There is no other reason than that. There is nothing special otherwise about

More information

Special Situations in the Simplex Algorithm

Special Situations in the Simplex Algorithm Special Situations in the Simplex Algorithm Degeneracy Consider the linear program: Maximize 2x 1 +x 2 Subject to: 4x 1 +3x 2 12 (1) 4x 1 +x 2 8 (2) 4x 1 +2x 2 8 (3) x 1, x 2 0. We will first apply the

More information

The Center for Teaching, Learning, & Technology

The Center for Teaching, Learning, & Technology The Center for Teaching, Learning, & Technology Instructional Technology Workshops Microsoft Excel 2010 Formulas and Charts Albert Robinson / Delwar Sayeed Faculty and Staff Development Programs Colston

More information

Linear Programming Notes V Problem Transformations

Linear Programming Notes V Problem Transformations Linear Programming Notes V Problem Transformations 1 Introduction Any linear programming problem can be rewritten in either of two standard forms. In the first form, the objective is to maximize, the material

More information

Chapter One Introduction to Programming

Chapter One Introduction to Programming Chapter One Introduction to Programming 1-1 Algorithm and Flowchart Algorithm is a step-by-step procedure for calculation. More precisely, algorithm is an effective method expressed as a finite list of

More information

Unit 1 Equations, Inequalities, Functions

Unit 1 Equations, Inequalities, Functions Unit 1 Equations, Inequalities, Functions Algebra 2, Pages 1-100 Overview: This unit models real-world situations by using one- and two-variable linear equations. This unit will further expand upon pervious

More information

G563 Quantitative Paleontology. SQL databases. An introduction. Department of Geological Sciences Indiana University. (c) 2012, P.

G563 Quantitative Paleontology. SQL databases. An introduction. Department of Geological Sciences Indiana University. (c) 2012, P. SQL databases An introduction AMP: Apache, mysql, PHP This installations installs the Apache webserver, the PHP scripting language, and the mysql database on your computer: Apache: runs in the background

More information

Oracle Database: SQL and PL/SQL Fundamentals

Oracle Database: SQL and PL/SQL Fundamentals Oracle University Contact Us: +966 12 739 894 Oracle Database: SQL and PL/SQL Fundamentals Duration: 5 Days What you will learn This Oracle Database: SQL and PL/SQL Fundamentals training is designed to

More information

Excel Formulas & Graphs

Excel Formulas & Graphs Using Basic Formulas A formula can be a combination of values (numbers or cell references), math operators and expressions. Excel requires that every formula begin with an equal sign (=). Excel also has

More information

Formulas & Functions in Microsoft Excel

Formulas & Functions in Microsoft Excel Formulas & Functions in Microsoft Excel Theresa A Scott, MS Biostatistician II Department of Biostatistics Vanderbilt University theresa.scott@vanderbilt.edu Table of Contents 1 Introduction 1 1.1 Using

More information

Handout #1: Mathematical Reasoning

Handout #1: Mathematical Reasoning Math 101 Rumbos Spring 2010 1 Handout #1: Mathematical Reasoning 1 Propositional Logic A proposition is a mathematical statement that it is either true or false; that is, a statement whose certainty or

More information

Linear Programs: Variables, Objectives and Constraints

Linear Programs: Variables, Objectives and Constraints 8 Linear Programs: Variables, Objectives and Constraints The best-known kind of optimization model, which has served for all of our examples so far, is the linear program. The variables of a linear program

More information

Solving Math Programs with LINGO

Solving Math Programs with LINGO 2 Solving Math Programs with LINGO 2.1 Introduction The process of solving a math program requires a large number of calculations and is, therefore, best performed by a computer program. The computer program

More information

Excel Basics By Tom Peters & Laura Spielman

Excel Basics By Tom Peters & Laura Spielman Excel Basics By Tom Peters & Laura Spielman What is Excel? Microsoft Excel is a software program with spreadsheet format enabling the user to organize raw data, make tables and charts, graph and model

More information

Overview. Essential Questions. Precalculus, Quarter 4, Unit 4.5 Build Arithmetic and Geometric Sequences and Series

Overview. Essential Questions. Precalculus, Quarter 4, Unit 4.5 Build Arithmetic and Geometric Sequences and Series Sequences and Series Overview Number of instruction days: 4 6 (1 day = 53 minutes) Content to Be Learned Write arithmetic and geometric sequences both recursively and with an explicit formula, use them

More information

Basic Components of an LP:

Basic Components of an LP: 1 Linear Programming Optimization is an important and fascinating area of management science and operations research. It helps to do less work, but gain more. Linear programming (LP) is a central topic

More information

arrays C Programming Language - Arrays

arrays C Programming Language - Arrays arrays So far, we have been using only scalar variables scalar meaning a variable with a single value But many things require a set of related values coordinates or vectors require 3 (or 2, or 4, or more)

More information

Lab Experience 17. Programming Language Translation

Lab Experience 17. Programming Language Translation Lab Experience 17 Programming Language Translation Objectives Gain insight into the translation process for converting one virtual machine to another See the process by which an assembler translates assembly

More information

Linear Programming. Solving LP Models Using MS Excel, 18

Linear Programming. Solving LP Models Using MS Excel, 18 SUPPLEMENT TO CHAPTER SIX Linear Programming SUPPLEMENT OUTLINE Introduction, 2 Linear Programming Models, 2 Model Formulation, 4 Graphical Linear Programming, 5 Outline of Graphical Procedure, 5 Plotting

More information

One Dimension Array: Declaring a fixed-array, if array-name is the name of an array

One Dimension Array: Declaring a fixed-array, if array-name is the name of an array Arrays in Visual Basic 6 An array is a collection of simple variables of the same type to which the computer can efficiently assign a list of values. Array variables have the same kinds of names as simple

More information

VHDL Test Bench Tutorial

VHDL Test Bench Tutorial University of Pennsylvania Department of Electrical and Systems Engineering ESE171 - Digital Design Laboratory VHDL Test Bench Tutorial Purpose The goal of this tutorial is to demonstrate how to automate

More information

Excel 2007 Basic knowledge

Excel 2007 Basic knowledge Ribbon menu The Ribbon menu system with tabs for various Excel commands. This Ribbon system replaces the traditional menus used with Excel 2003. Above the Ribbon in the upper-left corner is the Microsoft

More information

https://williamshartunionca.springboardonline.org/ebook/book/27e8f1b87a1c4555a1212b...

https://williamshartunionca.springboardonline.org/ebook/book/27e8f1b87a1c4555a1212b... of 19 9/2/2014 12:09 PM Answers Teacher Copy Plan Pacing: 1 class period Chunking the Lesson Example A #1 Example B Example C #2 Check Your Understanding Lesson Practice Teach Bell-Ringer Activity Students

More information

Relational Database: Additional Operations on Relations; SQL

Relational Database: Additional Operations on Relations; SQL Relational Database: Additional Operations on Relations; SQL Greg Plaxton Theory in Programming Practice, Fall 2005 Department of Computer Science University of Texas at Austin Overview The course packet

More information

Computers. An Introduction to Programming with Python. Programming Languages. Programs and Programming. CCHSG Visit June 2014. Dr.-Ing.

Computers. An Introduction to Programming with Python. Programming Languages. Programs and Programming. CCHSG Visit June 2014. Dr.-Ing. Computers An Introduction to Programming with Python CCHSG Visit June 2014 Dr.-Ing. Norbert Völker Many computing devices are embedded Can you think of computers/ computing devices you may have in your

More information

8 Primes and Modular Arithmetic

8 Primes and Modular Arithmetic 8 Primes and Modular Arithmetic 8.1 Primes and Factors Over two millennia ago already, people all over the world were considering the properties of numbers. One of the simplest concepts is prime numbers.

More information

Q&As: Microsoft Excel 2013: Chapter 2

Q&As: Microsoft Excel 2013: Chapter 2 Q&As: Microsoft Excel 2013: Chapter 2 In Step 5, why did the date that was entered change from 4/5/10 to 4/5/2010? When Excel recognizes that you entered a date in mm/dd/yy format, it automatically formats

More information

What is Linear Programming?

What is Linear Programming? Chapter 1 What is Linear Programming? An optimization problem usually has three essential ingredients: a variable vector x consisting of a set of unknowns to be determined, an objective function of x to

More information

Linear Programming. March 14, 2014

Linear Programming. March 14, 2014 Linear Programming March 1, 01 Parts of this introduction to linear programming were adapted from Chapter 9 of Introduction to Algorithms, Second Edition, by Cormen, Leiserson, Rivest and Stein [1]. 1

More information

Instant SQL Programming

Instant SQL Programming Instant SQL Programming Joe Celko Wrox Press Ltd. INSTANT Table of Contents Introduction 1 What Can SQL Do for Me? 2 Who Should Use This Book? 2 How To Use This Book 3 What You Should Know 3 Conventions

More information

Discrete Optimization

Discrete Optimization Discrete Optimization [Chen, Batson, Dang: Applied integer Programming] Chapter 3 and 4.1-4.3 by Johan Högdahl and Victoria Svedberg Seminar 2, 2015-03-31 Todays presentation Chapter 3 Transforms using

More information

Engineering Problem Solving and Excel. EGN 1006 Introduction to Engineering

Engineering Problem Solving and Excel. EGN 1006 Introduction to Engineering Engineering Problem Solving and Excel EGN 1006 Introduction to Engineering Mathematical Solution Procedures Commonly Used in Engineering Analysis Data Analysis Techniques (Statistics) Curve Fitting techniques

More information

Formulas, Functions and Charts

Formulas, Functions and Charts Formulas, Functions and Charts :: 167 8 Formulas, Functions and Charts 8.1 INTRODUCTION In this leson you can enter formula and functions and perform mathematical calcualtions. You will also be able to

More information

Classification - Examples

Classification - Examples Lecture 2 Scheduling 1 Classification - Examples 1 r j C max given: n jobs with processing times p 1,...,p n and release dates r 1,...,r n jobs have to be scheduled without preemption on one machine taking

More information

This is a square root. The number under the radical is 9. (An asterisk * means multiply.)

This is a square root. The number under the radical is 9. (An asterisk * means multiply.) Page of Review of Radical Expressions and Equations Skills involving radicals can be divided into the following groups: Evaluate square roots or higher order roots. Simplify radical expressions. Rationalize

More information

T-SQL STANDARD ELEMENTS

T-SQL STANDARD ELEMENTS T-SQL STANDARD ELEMENTS SLIDE Overview Types of commands and statement elements Basic SELECT statements Categories of T-SQL statements Data Manipulation Language (DML*) Statements for querying and modifying

More information

Oracle SQL. Course Summary. Duration. Objectives

Oracle SQL. Course Summary. Duration. Objectives Oracle SQL Course Summary Identify the major structural components of the Oracle Database 11g Create reports of aggregated data Write SELECT statements that include queries Retrieve row and column data

More information

Example of a Java program

Example of a Java program Example of a Java program class SomeNumbers static int square (int x) return x*x; public static void main (String[] args) int n=20; if (args.length > 0) // change default n = Integer.parseInt(args[0]);

More information

X1 Professional Client

X1 Professional Client X1 Professional Client What Will X1 Do For Me? X1 instantly locates any word in any email message, attachment, file or Outlook contact on your PC. Most search applications require you to type a search,

More information

IT2304: Database Systems 1 (DBS 1)

IT2304: Database Systems 1 (DBS 1) : Database Systems 1 (DBS 1) (Compulsory) 1. OUTLINE OF SYLLABUS Topic Minimum number of hours Introduction to DBMS 07 Relational Data Model 03 Data manipulation using Relational Algebra 06 Data manipulation

More information

Lab 9 Access PreLab Copy the prelab folder, Lab09 PreLab9_Access_intro

Lab 9 Access PreLab Copy the prelab folder, Lab09 PreLab9_Access_intro Lab 9 Access PreLab Copy the prelab folder, Lab09 PreLab9_Access_intro, to your M: drive. To do the second part of the prelab, you will need to have available a database from that folder. Creating a new

More information

Relational Databases

Relational Databases Relational Databases Jan Chomicki University at Buffalo Jan Chomicki () Relational databases 1 / 18 Relational data model Domain domain: predefined set of atomic values: integers, strings,... every attribute

More information

Lecture 2: August 29. Linear Programming (part I)

Lecture 2: August 29. Linear Programming (part I) 10-725: Convex Optimization Fall 2013 Lecture 2: August 29 Lecturer: Barnabás Póczos Scribes: Samrachana Adhikari, Mattia Ciollaro, Fabrizio Lecci Note: LaTeX template courtesy of UC Berkeley EECS dept.

More information

AP Computer Science Java Mr. Clausen Program 9A, 9B

AP Computer Science Java Mr. Clausen Program 9A, 9B AP Computer Science Java Mr. Clausen Program 9A, 9B PROGRAM 9A I m_sort_of_searching (20 points now, 60 points when all parts are finished) The purpose of this project is to set up a program that will

More information

Financial Econometrics MFE MATLAB Introduction. Kevin Sheppard University of Oxford

Financial Econometrics MFE MATLAB Introduction. Kevin Sheppard University of Oxford Financial Econometrics MFE MATLAB Introduction Kevin Sheppard University of Oxford October 21, 2013 2007-2013 Kevin Sheppard 2 Contents Introduction i 1 Getting Started 1 2 Basic Input and Operators 5

More information

I PUC - Computer Science. Practical s Syllabus. Contents

I PUC - Computer Science. Practical s Syllabus. Contents I PUC - Computer Science Practical s Syllabus Contents Topics 1 Overview Of a Computer 1.1 Introduction 1.2 Functional Components of a computer (Working of each unit) 1.3 Evolution Of Computers 1.4 Generations

More information

Moving from CS 61A Scheme to CS 61B Java

Moving from CS 61A Scheme to CS 61B Java Moving from CS 61A Scheme to CS 61B Java Introduction Java is an object-oriented language. This document describes some of the differences between object-oriented programming in Scheme (which we hope you

More information

IT2305 Database Systems I (Compulsory)

IT2305 Database Systems I (Compulsory) Database Systems I (Compulsory) INTRODUCTION This is one of the 4 modules designed for Semester 2 of Bachelor of Information Technology Degree program. CREDITS: 04 LEARNING OUTCOMES On completion of this

More information

Using Casio Graphics Calculators

Using Casio Graphics Calculators Using Casio Graphics Calculators (Some of this document is based on papers prepared by Donald Stover in January 2004.) This document summarizes calculation and programming operations with many contemporary

More information

Introduction to Matrix Algebra

Introduction to Matrix Algebra Psychology 7291: Multivariate Statistics (Carey) 8/27/98 Matrix Algebra - 1 Introduction to Matrix Algebra Definitions: A matrix is a collection of numbers ordered by rows and columns. It is customary

More information

Advance DBMS. Structured Query Language (SQL)

Advance DBMS. Structured Query Language (SQL) Structured Query Language (SQL) Introduction Commercial database systems use more user friendly language to specify the queries. SQL is the most influential commercially marketed product language. Other

More information

Keywords are identifiers having predefined meanings in C programming language. The list of keywords used in standard C are : unsigned void

Keywords are identifiers having predefined meanings in C programming language. The list of keywords used in standard C are : unsigned void 1. Explain C tokens Tokens are basic building blocks of a C program. A token is the smallest element of a C program that is meaningful to the compiler. The C compiler recognizes the following kinds of

More information

MICROSOFT EXCEL FORMULAS

MICROSOFT EXCEL FORMULAS MICROSOFT EXCEL FORMULAS Building Formulas... 1 Writing a Formula... 1 Parentheses in Formulas... 2 Operator Precedence... 2 Changing the Operator Precedence... 2 Functions... 3 The Insert Function Button...

More information

Math Review. for the Quantitative Reasoning Measure of the GRE revised General Test

Math Review. for the Quantitative Reasoning Measure of the GRE revised General Test Math Review for the Quantitative Reasoning Measure of the GRE revised General Test www.ets.org Overview This Math Review will familiarize you with the mathematical skills and concepts that are important

More information

Searching. Qvidian Proposal Automation (QPA) Quick Reference Guide. Types of Searches. Browse

Searching. Qvidian Proposal Automation (QPA) Quick Reference Guide. Types of Searches. Browse Qvidian Proposal Automation (QPA) Quick Reference Guide Types of Searches There are three main types of searches within QPA: Browse Search Advanced Search Please also refer to the sections Content Items

More information

SYSTEMS OF EQUATIONS AND MATRICES WITH THE TI-89. by Joseph Collison

SYSTEMS OF EQUATIONS AND MATRICES WITH THE TI-89. by Joseph Collison SYSTEMS OF EQUATIONS AND MATRICES WITH THE TI-89 by Joseph Collison Copyright 2000 by Joseph Collison All rights reserved Reproduction or translation of any part of this work beyond that permitted by Sections

More information

MATLAB Basics MATLAB numbers and numeric formats

MATLAB Basics MATLAB numbers and numeric formats MATLAB Basics MATLAB numbers and numeric formats All numerical variables are stored in MATLAB in double precision floating-point form. (In fact it is possible to force some variables to be of other types

More information

Section IV.1: Recursive Algorithms and Recursion Trees

Section IV.1: Recursive Algorithms and Recursion Trees Section IV.1: Recursive Algorithms and Recursion Trees Definition IV.1.1: A recursive algorithm is an algorithm that solves a problem by (1) reducing it to an instance of the same problem with smaller

More information

FUZZY CLUSTERING ANALYSIS OF DATA MINING: APPLICATION TO AN ACCIDENT MINING SYSTEM

FUZZY CLUSTERING ANALYSIS OF DATA MINING: APPLICATION TO AN ACCIDENT MINING SYSTEM International Journal of Innovative Computing, Information and Control ICIC International c 0 ISSN 34-48 Volume 8, Number 8, August 0 pp. 4 FUZZY CLUSTERING ANALYSIS OF DATA MINING: APPLICATION TO AN ACCIDENT

More information

A Comparison of Database Query Languages: SQL, SPARQL, CQL, DMX

A Comparison of Database Query Languages: SQL, SPARQL, CQL, DMX ISSN: 2393-8528 Contents lists available at www.ijicse.in International Journal of Innovative Computer Science & Engineering Volume 3 Issue 2; March-April-2016; Page No. 09-13 A Comparison of Database

More information

AIMMS Tutorial for Professionals - Quantities and Time

AIMMS Tutorial for Professionals - Quantities and Time AIMMS Tutorial for Professionals - Quantities and Time This file contains only one chapter of the book. For a free download of the complete book in pdf format, please visit www.aimms.com Aimms 3.13 Copyright

More information

Least-Squares Intersection of Lines

Least-Squares Intersection of Lines Least-Squares Intersection of Lines Johannes Traa - UIUC 2013 This write-up derives the least-squares solution for the intersection of lines. In the general case, a set of lines will not intersect at a

More information

Algebra 2 Chapter 1 Vocabulary. identity - A statement that equates two equivalent expressions.

Algebra 2 Chapter 1 Vocabulary. identity - A statement that equates two equivalent expressions. Chapter 1 Vocabulary identity - A statement that equates two equivalent expressions. verbal model- A word equation that represents a real-life problem. algebraic expression - An expression with variables.

More information

Oct: 50 8 = 6 (r = 2) 6 8 = 0 (r = 6) Writing the remainders in reverse order we get: (50) 10 = (62) 8

Oct: 50 8 = 6 (r = 2) 6 8 = 0 (r = 6) Writing the remainders in reverse order we get: (50) 10 = (62) 8 ECE Department Summer LECTURE #5: Number Systems EEL : Digital Logic and Computer Systems Based on lecture notes by Dr. Eric M. Schwartz Decimal Number System: -Our standard number system is base, also

More information

5.1 Bipartite Matching

5.1 Bipartite Matching CS787: Advanced Algorithms Lecture 5: Applications of Network Flow In the last lecture, we looked at the problem of finding the maximum flow in a graph, and how it can be efficiently solved using the Ford-Fulkerson

More information

MS Access: Advanced Tables and Queries. Lesson Notes Author: Pamela Schmidt

MS Access: Advanced Tables and Queries. Lesson Notes Author: Pamela Schmidt Lesson Notes Author: Pamela Schmidt Tables Text Fields (Default) Text or combinations of text and numbers, as well as numbers that don't require calculations, such as phone numbers. or the length set by

More information

Database Applications Microsoft Access

Database Applications Microsoft Access Database Applications Microsoft Access Lesson 4 Working with Queries Difference Between Queries and Filters Filters are temporary Filters are placed on data in a single table Queries are saved as individual

More information

Microsoft Excel Basics

Microsoft Excel Basics COMMUNITY TECHNICAL SUPPORT Microsoft Excel Basics Introduction to Excel Click on the program icon in Launcher or the Microsoft Office Shortcut Bar. A worksheet is a grid, made up of columns, which are

More information

Accentuate the Negative: Homework Examples from ACE

Accentuate the Negative: Homework Examples from ACE Accentuate the Negative: Homework Examples from ACE Investigation 1: Extending the Number System, ACE #6, 7, 12-15, 47, 49-52 Investigation 2: Adding and Subtracting Rational Numbers, ACE 18-22, 38(a),

More information

Regular Languages and Finite Automata

Regular Languages and Finite Automata Regular Languages and Finite Automata 1 Introduction Hing Leung Department of Computer Science New Mexico State University Sep 16, 2010 In 1943, McCulloch and Pitts [4] published a pioneering work on a

More information

ML for the Working Programmer

ML for the Working Programmer ML for the Working Programmer 2nd edition Lawrence C. Paulson University of Cambridge CAMBRIDGE UNIVERSITY PRESS CONTENTS Preface to the Second Edition Preface xiii xv 1 Standard ML 1 Functional Programming

More information

Adaptive Stable Additive Methods for Linear Algebraic Calculations

Adaptive Stable Additive Methods for Linear Algebraic Calculations Adaptive Stable Additive Methods for Linear Algebraic Calculations József Smidla, Péter Tar, István Maros University of Pannonia Veszprém, Hungary 4 th of July 204. / 2 József Smidla, Péter Tar, István

More information

So let us begin our quest to find the holy grail of real analysis.

So let us begin our quest to find the holy grail of real analysis. 1 Section 5.2 The Complete Ordered Field: Purpose of Section We present an axiomatic description of the real numbers as a complete ordered field. The axioms which describe the arithmetic of the real numbers

More information

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS Systems of Equations and Matrices Representation of a linear system The general system of m equations in n unknowns can be written a x + a 2 x 2 + + a n x n b a

More information

Access Queries (Office 2003)

Access Queries (Office 2003) Access Queries (Office 2003) Technical Support Services Office of Information Technology, West Virginia University OIT Help Desk 293-4444 x 1 oit.wvu.edu/support/training/classmat/db/ Instructor: Kathy

More information

Creating QBE Queries in Microsoft SQL Server

Creating QBE Queries in Microsoft SQL Server Creating QBE Queries in Microsoft SQL Server When you ask SQL Server or any other DBMS (including Access) a question about the data in a database, the question is called a query. A query is simply a question

More information

Oracle Database: SQL and PL/SQL Fundamentals

Oracle Database: SQL and PL/SQL Fundamentals Oracle University Contact Us: 1.800.529.0165 Oracle Database: SQL and PL/SQL Fundamentals Duration: 5 Days What you will learn This course is designed to deliver the fundamentals of SQL and PL/SQL along

More information

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS. + + x 2. x n. a 11 a 12 a 1n b 1 a 21 a 22 a 2n b 2 a 31 a 32 a 3n b 3. a m1 a m2 a mn b m

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS. + + x 2. x n. a 11 a 12 a 1n b 1 a 21 a 22 a 2n b 2 a 31 a 32 a 3n b 3. a m1 a m2 a mn b m MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS 1. SYSTEMS OF EQUATIONS AND MATRICES 1.1. Representation of a linear system. The general system of m equations in n unknowns can be written a 11 x 1 + a 12 x 2 +

More information

Numerical Matrix Analysis

Numerical Matrix Analysis Numerical Matrix Analysis Lecture Notes #10 Conditioning and / Peter Blomgren, blomgren.peter@gmail.com Department of Mathematics and Statistics Dynamical Systems Group Computational Sciences Research

More information

Introduction to tuple calculus Tore Risch 2011-02-03

Introduction to tuple calculus Tore Risch 2011-02-03 Introduction to tuple calculus Tore Risch 2011-02-03 The relational data model is based on considering normalized tables as mathematical relationships. Powerful query languages can be defined over such

More information

Continued Fractions and the Euclidean Algorithm

Continued Fractions and the Euclidean Algorithm Continued Fractions and the Euclidean Algorithm Lecture notes prepared for MATH 326, Spring 997 Department of Mathematics and Statistics University at Albany William F Hammond Table of Contents Introduction

More information

EXCEL Tutorial: How to use EXCEL for Graphs and Calculations.

EXCEL Tutorial: How to use EXCEL for Graphs and Calculations. EXCEL Tutorial: How to use EXCEL for Graphs and Calculations. Excel is powerful tool and can make your life easier if you are proficient in using it. You will need to use Excel to complete most of your

More information

Formulas & Functions in Microsoft Excel

Formulas & Functions in Microsoft Excel Formulas & Functions in Microsoft Excel Theresa A Scott, MS Biostatistician III Department of Biostatistics Vanderbilt University theresa.scott@vanderbilt.edu Table of Contents 1 Introduction 1 1.1 Using

More information

Oracle Database 12c: Introduction to SQL Ed 1.1

Oracle Database 12c: Introduction to SQL Ed 1.1 Oracle University Contact Us: 1.800.529.0165 Oracle Database 12c: Introduction to SQL Ed 1.1 Duration: 5 Days What you will learn This Oracle Database: Introduction to SQL training helps you write subqueries,

More information

Digital System Design Prof. D Roychoudhry Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

Digital System Design Prof. D Roychoudhry Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Digital System Design Prof. D Roychoudhry Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Lecture - 04 Digital Logic II May, I before starting the today s lecture

More information

Sources: On the Web: Slides will be available on:

Sources: On the Web: Slides will be available on: C programming Introduction The basics of algorithms Structure of a C code, compilation step Constant, variable type, variable scope Expression and operators: assignment, arithmetic operators, comparison,

More information

POLYNOMIAL FUNCTIONS

POLYNOMIAL FUNCTIONS POLYNOMIAL FUNCTIONS Polynomial Division.. 314 The Rational Zero Test.....317 Descarte s Rule of Signs... 319 The Remainder Theorem.....31 Finding all Zeros of a Polynomial Function.......33 Writing a

More information

Vocabulary Words and Definitions for Algebra

Vocabulary Words and Definitions for Algebra Name: Period: Vocabulary Words and s for Algebra Absolute Value Additive Inverse Algebraic Expression Ascending Order Associative Property Axis of Symmetry Base Binomial Coefficient Combine Like Terms

More information

CHAPTER 2 DATABASE MANAGEMENT SYSTEM AND SECURITY

CHAPTER 2 DATABASE MANAGEMENT SYSTEM AND SECURITY CHAPTER 2 DATABASE MANAGEMENT SYSTEM AND SECURITY 2.1 Introduction In this chapter, I am going to introduce Database Management Systems (DBMS) and the Structured Query Language (SQL), its syntax and usage.

More information