You are on page 1of 67

Maxima and Minima of Functions of Two Variables

The problem of determining the maximum or minimum of function is encountered in geometry, mechanics, physics, and other fields, and was one of the motivating factors in the development of the calculus in the seventeenth century. Let us recall the procedure for the case of a function of one variable y=f(x). First, we determine points x_c where f'(x)=0. These points are called critical points. At critical points the tangent line is horizontal. This is shown in the figure below.

The second derivative test is employed to determine if a critical point is a relative maximum or a relative minimum. If f''(x_c)>0, then x_c is a relative minimum. If f''(x_c)<0, then x_c is a maximum. If f''(x_c)=0, then the test gives no information. The notions of critical points and the second derivative test carry over to functions of two variables. Let z=f(x,y). Critical points are points in the xy-plane where the tangent plane is horizontal.

Since the normal vector of the tangent plane at (x,y) is given by

The tangent plane is horizontal if its normal vector points in the z direction. Hence, critical points are solutions of the equations:

because horizontal planes have normal vector parallel to z-axis. The two equations above must be solved simultaneously. Example Let us find the critical points of

The partial derivatives are

f_x=0 if 1-x^2=0 or the exponential term is 0. f_y=0 if -2y=0 or the exponential term is 0. The exponential term is not 0 except in the degenerate case. Hence we require 1-x^2=0 and 2y=0, implying x=1 or x=-1 and y=0. There are two critical points (-1,0) and (1,0). The Second Derivative Test for Functions of Two Variables How can we determine if the critical points found above are relative maxima or minima? We apply a second derivative test for functions of two variables. Let (x_c,y_c) be a critical point and define

We have the following cases:

If D>0 and f_xx(x_c,y_c)<0, then f(x,y) has a relative maximum at (x_c,y_c). If D>0 and f_xx(x_c,y_c)>0, then f(x,y) has a relative minimum at (x_c,y_c). If D<0, then f(x,y) has a saddle point at (x_c,y_c). If D=0, the second derivative test is inconclusive.

An example of a saddle point is shown in the example below. Example: Continued For the example above, we have

For x=1 and y=0, we have D(1,0)=4exp(4/3)>0 with f_xx(1,0)=-2exp(2/3)<0. Hence, (1,0) is a relative maximum. For x=-1 and y=0, we have D(-1,0)=-4exp(-4/3)<0. Hence, (-1,0) is a saddle point. The figure below plots the surface z=f(x,y).

Notice the relative maximum at (x=1,y=0). (x=-1,y=0) is a relative maximum if one travels in the y direction and a relative minimum if one travels in the x-direction. Near (-1,0) the surface looks like a saddle, hence the name. Maxima and Minima in a Bounded Region Suppose that our goal is to find the global maximum and minimum of our model function above in the square -2<=x<=2 and -2<=y<=2? There are three types of points that can potentially be global maxima or minima: 1. Relative extrema in the interior of the square. 2. Relative extrema on the boundary of the square. 3. Corner Points. We have already done step 1. There are extrema at (1,0) and (-1,0). The boundary of square consists of 4 parts. Side 1 is y=-2 and -2<=x<=2. On this side, we have

The original function of 2 variables is now a function of x only. We set g'(x)=0 to determine relative extrema on Side 1. It can be shown that x=1 and x=-1 are the relative extrema. Since y=-2, the relative extrema on Side 1 are at (1,-2) and (-1,-2). On Side 2 (x=-2 and -2<=y<=2)

We set h'(y)=0 to determine the relative extrema. It can be shown that y=0 is the only critical point, corresponding to (-2,0).

We play the same game to determine the relative extrema on the other 2 sides. It can be shown that they are (2,0), (1,2), and (-1,2). Finally, we must include the 4 corners (-2,-2), (-2,2), (2,-2), and (2,2). In summary, the candidates for global maximum and minimum are (-1,0), (1,0), (1,-2), (-1,-2), (-2,0), (2,0), (1,2), (-1,2), (-2,-2), (-2,2), (2,-2), and (2,2). We evaluate f(x,y) at each of these points to determine the global max and min in the square. The global maximum occurs (-2,0) and (1,0). This can be seen in the figure above. The global minimum occurs at 4 points: (-1,2), (1,-2), (2,2), and (2,-2). Example: Maxima and Minima in a Disk Another example of a bounded region is the disk of radius 2 centered at the origin. We proceed as in the previous example, determining in the 3 classes above. (1,0) and (-1,0) lie in the interior of the disk. The boundary of the disk is the circle x^2+y^2=4. To find extreme points on the disk we parameterize the circle. A natural parameterization is x=2cos(t) and y=2sin(t) for 0<=t<=2*pi. We substitute these expressions into z=f(x,y) and obtain

On the circle, the original functions of 2 variables is reduced to a function of 1 variable. We can determine the extrema on the circle using techniques from calculus of on variable. In this problem there are not any corners. Hence, we determine the global max and min by considering points in the interior of the disk and on the circle. An alternative method for finding the maximum and minimum on the circle is the method of Lagrange multipliers. Maxima and Minima for Functions of More than 2 Variables The notion of extreme points can be extended to functions of more than 2 variables. Suppose z=f(x_1,x_2,...,x_n). (a_1,a_2,...,a_n) is extreme point if it satisfies the n equations

There is not a general second derivative test to determine if a point is a relative maximum or minimum for functions of more than two variables.

[Vector Calculus Home] [Math 254 Home] [Math 255 Home] [Notation] [References] Copyright 1996 Department of Mathematics, Oregon State University If you have questions or comments, don't hestitate to contact us.


Enter question or phrase...

Search: All sources Community Q&A Reference topics

Browse: Unanswered questions New questions New answers Reference library

What are applications for matrices?

In: Abstract Algebra, Linear Algebra [Edit categories]

Thinking matters to us.

Thinking ahead even more. Do you want to think ahead with us?

Class 1 to Class 12

Lessons, Animations, Videos & more Math, EVS, Science, English, SST

Ads > Wiki Answers > Categories > Jobs & Education > Education > School Subjects > Math > Algebra > Abstract Algebra > What are applications for matrices?



Matrices are used basically to solve linear equations....... Equations are generally solved to get value of unknown variables.......

Variable values are calculated (or assumed) to know all working or constant parameters of a system...

e.g. for a reaction generally pressure, temperature, concentration of reactant etc. such parameters can work as variables.

If these parameters are varied resultant yield get affected.........

We never know all properties at start, we first found relations between variables by doing practicals & form equations.........

Then these equations can be solved by many methods.......

Out of these many methods matrices is one......

So which ever system can be represented by equations, matrices have application there........

e.g. computer programmes, financial calculations, chemical processes, construction calculations etc...........

CPR Certificate Online

Get Certified Online In Minutes. ECC-Compliant. Rated "Best" By CNN.

CBSE Classes 6th to 12th

Maths/Science Solutions,Tests,Video NCERT Textbook. Regt now for Free!

NCERT 8th, 9th & 10th

CBSE Math, Science, Social, English Papers, Tests. Join for Free.


First answer by Satya jit5. Last edit by Satya jit5. Contributor trust: 0 [recommend contributor]. Question popularity: 0 [recommend question]. [report abuse]

Can you answer these Abstract Algebra questions?

Why is algebra 1 AB?

Answer it!

What percent of 30 is 31?

Answer it!

Are all asymmetric relations negatively transitive?

Answer it!

What is the answer to pre algebra with pizzazz page 59?

Answer it!

What is the answer to -13m equals -377?

Answer it!

Relevant answers:

What are the applications of matrices? we can measure the expansion of the world by matrices cause in magnetic fields vectors can be streched up to a certain limit which are the eigen values.

Application of matrices in your daily life? Matrices are used to figure who is seeded in a contest like the NCAA basketball final four. Matrices are used in any calculation that has to do with multiple variables. In business the maximum that...

What are the application of matrices in field of engineering?

Matrices have a wider application in engg.Many problems can be transformed in to simultaneous equation and their solution can easily be find with the help of matrices.

What are the engineering applications of complex numbers and matrices? I suggest asking separate questions for complex numbers, and for matrices.Complex numbers are used in a variety of fields, one of them is electrical engineering. As soon as AC circuits are analyzed,...

Applications of Linear Algebra

Fish Pages

About the Blog About NDU About us Another teacher at NDU EduBlogging

Tuesday, April 26, 2011

The Application of Matrices to Business and Economics.
Problem: Suppose that the economy of a certain region depends on three industries: service, electricity and oil production. Monitoring the operations of these three industries over a period of one year, we were able to come up with the following observations: 1- To produce 1 unit worth of service, the service industry must consume 0.3 units of its own production, 0.3 units of electricity and 0.3 units of oil to run its operations. 2-To produce 1 unit of electricity, the power-generating plant must buy 0.4 units of

service, 0.1 units of its own production, and 0.5 units of oil. 3-Finally, the oil production company requires 0.3 units of service, 0.6 units of electricity and 0.2 units of its own production to produce 1 unit of oil. Find the production level of each of these industries in order to satisfy the external and the internal demands assuming that the above model is closed, that is, no goods leave or enter the system. Solution:

Consider 1. 2. p1= p2=

the production production level level for the

following for the service plant

variables: industry (electricity)


3. p3= production level for the oil production company Since the model is closed, the total consumption of each industry must equal its total production. This gives the following linear system: 0.3p1 + 0.3p2 + 0.3p3 = p1 0.4p1 + 0.1p2 + 0.5p3 = p2 0.3p1 + 0.6p2 + 0.2p3 = p3 The input matrix is: A= 0.3 0.3 0.3 0.4 0.1 0.5 0.3 0.6 0.2 and the above system can be written as (A-I)P=0. Note that this homogeneous system has infinitely many

solutions (and consequently a nontrivial solution) since each column in the coefficient matrix sums to 1. The augmented matrix of this homogeneous system is : -0.7 0.3 0.3 0 0.4 -0.9 0.5 0 0.3 0.6 -0.8 0 which can be reduced to : 1 0 -0.82 0 0 1 -0.92 0 0000 To solve the system, we let p3 =t (a parameter), then the general solution is : p1= 0.82t p2=0.92t p3=t The values of the variables in this system must be nonnegative in order for the model to make sense. In other words, t 0. Taking t=100 for example would give the solution : p1= 82 units p2= 92 units p3= 100 units. I chose an example of real life problem related to economics that shows how matrices can be effective and helpful when it comes to solving complicated problems. Matrices let us arrange numbers and get solutions to our problem in a quick and easy way !
Posted by Mary El Saify at 5:46 PM Email ThisBlogThis!Share to TwitterShare to Facebook Labels: Economics



Zeina Nehme said... Dear Mary, Very nice post! Is it possible to decrease the font size in your post? so it becomes a bit smaller... Thanks, Zeina April 26, 2011 9:35 PM

Anonymous said... Interesting Technique to find the production levels, Never Thought there are so many wide range of areas where matrix calculations can be used .. !! Elie Nassif May 20, 2011 1:22 PM

Post a Comment
Newer Post Older Post Home Subscribe to: Post Comments (Atom)

Through our Blog, is Linear Algebra becoming more meaningful to you? Subscribe via email
Enter your email address:




Delivered by FeedBurner


2007 (1) 3D (5) Abstract Thinking (1) Arts (1) Business Math (10) Chemistry (6) Communication (1) computer graphics (2) Cryptography (1) Cryptology (11) decoding matrix (1) Economics (6) Electricity (4) encoding matrix (1) Engineering (10) Finance (2) Geometry (8) Germany February 21 (1) GPS (1) History (1) (1) Introduction (6) inverse (1) Marketing (1) Matlab (3) Matrices in the real world (1) Music (1) Photography (2) Physics (4) Potsdam (1) Programming a Robot (1) Quantum Mechanics (1) RSS FEED (1) sociology (1) The linear algebra behind google (1) TIME MANAGEMENT (1) Traffic (1) Video (1) Wolfgang Kohler (1)

Latest Posts

Linear algebra and electricity of a car

- 23 May 2011 - charbelazzi


- 22

May 2011 - Mariella B. Programming a Robot - 20 May 2011 - ricardo assaad matrices in 4d x y z and position - 19 May 2011 - majd - 17 May 2011 - Abdo Hilany

Blog Archive

2011 (50)

May (33) Linear algebra and electricity of a car THE $25,000,000,000 EIGENVECTOR THE LINEAR ALGEBR... Programming a Robot matrices in 4d x y z and position LCD (Liquid crystal display) Television: Passive m... Matrices and mechanics Linear Application To Sociology The Geometry of Linear Equations Quadratic equation a 44 coding messeges by matrices Moving a ship Projection Matrices Application of Invertible Matrices: Coding Matrix Representation of Special Relativity Introducing Abstract Thinking to your mind Balancing Equations Using Matrices Chemistry and the Z-Matrix Linear Algebra in Physics - Subspaces Matrices in Geometric Transformation BOILER WATER SOFTENER SYSTEM Since a 2 x 2 matrix corresponds uniquely to a li... Mirroring a point on a 3D plane 4. Matrix Operations in Excel. Matrix Manipulation... Matrix in Piezoelectricity Matrices of String Input Application of Matrices to Cryptography. MATLAB Importance of Linear Algebra in Physics Mechanical Vibrations and Matrices Using Matrices for Incryption and Decryption CAPPS: A Framework for PowerPerformance Tradeoffs... Traffic engineering with estimated traffic matrice... Matrices And Economics April (17) Chemistry & Matrices Matrix Transforms Linear Algebra and Electricity A Video Screen is One Type of Matrix Balancing Chemical Equations Using Matrices The Application of Matrices to Business and Econom... Matrices used in physics Cryptography With Matrices The ciphers used in c... The Decision Matrix: Buying a CarUse a decision ma... matrix and rotation (NEW york times For rota... Matrices make Statics easier Matrix Calculations for Digital Photography The Use of Matrices in Space Shuttle Control Syste... Using Matrix Transformations in Works of Visual Ar... TIME MANAGEMENT MATRIX Linear Algebra in Electrical Engineering Problem. Tuesday, April 5, 2011

2010 (43) o June (3) o March (2) o January (38) 2009 (17) o December (17)

Simple template. Template images by RBFried. Powered by Blogger.

Writing professional Solicitation and Selection (Procurement) Letters:

Learn secrets used by countless organizations to win contracts through an RFP-based selection process. Get your FREE RFP Letters Toolkit, 2011 Edition

Tuesday October 25, 2011

About Us |

Site Map |

Home |

How to write an RFP Letter |

FREE RFP Letters Templates and Samples

Free of charge Immediate delivery to your email Call 1-800-496-1303 ext. 273

FREE RFP Documents including:

Successfull RFPs in Construction NEW! RFP Template Acquisition Plan Template NEW! RFP Cover Letter Proposal Cover Letter Executive Summary Template NEW! FREE Company Profile Template Disqualification Letter Rejection Letter Non-Binding Letter of Intent Decision Matrix No-Bid Letter Protest Letter Sole Source Protest Letter Sole Source Justification & Approval (J&A) Letter to Decline a Proposal Contract Award Letter

FREE Requests for Proposals (RFP) Template Samples:

Software RFP Template Process ERP RFP Template Discrete ERP RFP Template

CRM RFP Template Accounting RFP Template

The Best Proposal-related Book

Latest Procurement News & Bids Opportunities from Federal Agencies

FAQ about RFP and Proposals:

MADM-Based ERP Software Selection Compare ERP NEW! Sealed Bids NEW! What is Competitive Procurement? Uniform Contract Format (UCF) What is Sole Source? Abstract vs. Executive Summary: Discover The Main Differences NEW! The Bid/No-Bid Analysis NEW! Best-known Readability Scores Bormuth Readability Score List of Work Words NEW! 47 FREE Affidavit Form Samples NEW! Bidder Responsibility Determination Bid Responsiveness Determination Food Court RFP Examples NEW! Meta Tag Generator NEW!

More FAQ...

The Best RFP-related Book

RFP Templates > Application of Matrices PDF

Application of Matrices PDF

Search :
Application of

Sort by :


Related searches to "Application Matrices PDF":

Application Example of Decision Making Technique for Work Ethics | Application of Multi Criteria Decision Making Process | Application Templates for Sole Distributor | Decision Analysis Application in Real Life | Decision Matrix for Application Development |

Recent Searches: A B C D

E F G H I J K L M N O P Q R S T U V W X Y Z Others Results for Application of Matrices PDF

COTS Acquisition Process Definition and Application Experience

Description: Defining a systematic and repeatable COTS acquisition process (CAP). COTS Acquisition Process Method and References. Siemens COTS Acquisition Process Case Study. This paper introduces and describes a well-defined, systematic, and repeatable COTS acquisition process (CAP) and experience of using a tailored version of the process in a Siemens Business Unit. Abstract: COTS Acquisition Process, CAP, COTS, Commercial-Off-The-Shelf Software, COTS Acquisition, COTS, Acquisition Process. A COTS Acquisition ProcessDefinition and Application Experience. by Michael Ochs, Dietmar Pfahl, Gunther Chrobok-Diening, and Beate Nothhelfer-Kolb. Defining a systematic and repeatable COTS acquisition process (CAP). Abstract. The use of Commercial-Off-TheShelf (COTS) softwar...

What is a Decision Matrix

Description: Decision matrix: a decision-support tool allowing decision makers to solve their problem by evaluating, rating, and comparing different alternatives on multiple criteria Abstract: What is a Decision Matrix?. Also known as: decision-making matrix, solutions prioritization matrix, cost/benefit analysis matrix, problem/solution matrix, options/criteria matrix,vendor selection matrix, criteria/alternatives matrix, RFP evaluation matrix, COWS decision matrix, supplier rating spreadsheet, comparison matrix template, importance/performance matrix, criteria-bas...

Business Intelligence (BI) RFP Template (FREE sample)

Description: A Business Intelligence (BI) model embeds modules like Business Performance Management (BPM), Core Analytics, Application-Centered Data Warehouse, Analysis and Exploration Tools, Alerting and Notification Systems, Scorecards, Portals, and Dashboards, Integrated Reporting and Queries, Workflow, Mobile Options, Industry Vertical Module Availability, Product Technology, and Technical Support Abstract: bi, business intelligence, business performance management (bpm) core analytics, application-centered data warehouse, analysis and exploration tools, alerting and notification systems, scorecards, portals, and dashboards, integrated reporting and queries, workflow, mobile options, industry vertical module availability, product technology, technical support. Business Performance Management (BPM). ...

Customer Relationship Management (CRM) RFP Template (FREE sample)

Description: A Customer Relationship Management (CRM) system model embeds modules like Business-to-Business (B2B) CRM, Marketing Automation, Sales Force Automation, Customer Service and Support, Partner Management, Contract Management and Creation, Project and Team Management, Business-to-Consumer (B2C) CRM, Internet Sales, E-Mail Response Management, B2C Analytics and Business Intelligence, ther CRM-Related Application Areas, E-mail marketing, Customer reference, Commission management, Field service, Relationship capital management, Survey software, Sales proposal software, Product and price configuration, Web conferencing, Mobile computing, Channel management, Retail solutions, Technical Functionality and Support, Business Functionality, Technical Functionality, and Ongoing CRM Solution Support Abstract: Business-to-Business (B2B) CRM. The Business-to-Business (B2B) CRM enables organizations to manage the whole customer/partner lifecycle and rapidly establish a selling channel, whether merely conventional or online through web-based applications (E-Sales)It encompasses modules from marketing automation to project execution, and contract management.. Marketing Automation. Marketing automation crea...

Decision Making Methods MCDM MCDA in The News

Description: Learn tips on how to write professional Request for Proposal (RFP) letters. FREE Templates and Samples of RFP cover letter, intent, rejection letter, disqualification, decline proposal, protest against unfair contract award Abstract: rfp cover, letter of intent, disqualification, to decline a proposal, rejection letter, rejected, disqualified, declined, rfp response letters, protest, request for proposal, evaluation, comparison, and selection process, request for information, rfi, requests for quote, rfq, invitation to bid, itb, invitation to tender, itt. Decision-making methods (MCDM, MCDA) in the news. ...

Product Lifecycle Management (PLM) RFP Template (FREE sample)

Description: A Product Lifecycle Management (PLM) model embeds modules like Core PLM for Discrete Industries, Core PLM for Process Industries, Product Development and Portfolio Management, Manufacturing Process Management (MPM), Ideation and Requirements Management, Service Data Management, Regulatory and Compliance, and Application Technology Abstract: plm, product lifecycle management, core plm for discrete industries, core plm for process industries, product development and portfolio management, manufacturing process management (mpm) ideation and requirements management, service data management, regulatory and compliance, application technology. Core PLM for Discrete Industries. Engineering Change Management. Engineering Change Definition. ...

Abstract vs Executive Summary

Description: Abstract vs. Executive Summary: definitions, differences, templates, examples, books on writing executive summary, how to write an executive summary

Abstract: Abstract vs Executive Summary. Also known as: abstract vs executive summary dilemma,. executive summary versus abstract, summary vs abstract, abstract summary vs executive summary, abstract vs. executive summary dilemma, abstract vs executive summary battle.Give me a place to stand and a long enough lever, and I will move the Earth" Archimedes In this page, you will find:the terms abstract vs exe...

Accounting Software RFP Template (FREE sample)

Description: An Accounting software solution model embeds modules like General Ledger, Accounts Payable, Accounts Receivable, Payroll, Inventory, Job and Project Costing, Fixed Assets, Order Entry, Budgeting, Manufacturing, Multinational Accounting, General Accounting, and Technology Abstract: Accounting Software RFP Template. General Ledger. Chart of Accounts. The Chart of Accounts is for all practical purposes the business managment system. If it is not set up properly so that revenues and costs are captured and segregated into the best suited categories, the financial statements produced will be useless.Chart of Accounts (Set Up). Chart of Accounts Set Up: The single most importan...

Acquisition Plan (AP) Template

Description: What is an Acquisition Plan (AP)? Acquisition Plan Definition: "An Acquisition plan (AP) is the comprehensive document that sets forth the acquisition strategy, defines the efforts required to implement it, and ensures coordination of all human and organizational resources involved in fulfilling the organization's needs in a timely manner and at a reasonable cost.". Who Shouldor Shouldn'tWrite the Acquisition Plan? When is a Written Acquisition Plan Required? Informal vs. Formal Acquisition Plan Template. How Does The Acquisition Plan Contribute to Acquisition Process Improvement? Writing an acquisition plan is a procedure referenced and defined by several software engineering (SE) standards (e.g., ISO/IEC 12207, IEEE 1062), software acquisition improvement models (e.g., CMMI for Acquisition [CMMI-ACQ]), and IT governance frameworks (e.g., CObIT) that organizations implement as part of their acquisition process improvement initiative. How to Write an Acquisition Plan? Acquisition PlanOnline Resources. Abstract: Acquisition Plan (AP) Template. Writing an Acquisition Plan (AP) Made Easy!. Also known as: acquisition plan outline, acquisition plan guidelines, acquisition plan format, acquisition plan template requirements, acquisition plan handbook, acquisition plan template model, acquisition plan template guide, acquisition management plan template, acquisition plan wizard, acquisiti...

Business Process Management (BPM) RFP Template (FREE sample)

Description: A Business Process Management (BPM) model embeds modules like Process Modeling, Security Management, Process Collaboration, Form Management, Workflow Portal, Monitoring and Management, Process Analytics, Product Technology and Support Abstract: bpm, business process management, process modeling, security management, process collaboration, form management, workflow portal, monitoring and management, process analytics, product technology and support. Process Modeling. Due Dates. Graphical Designer. Workflows can be graphically designed. Top-level status diagram (for business users). Detailed technical diagram (for implementers). ...

Related searches to Application Matrices PDF

matrices applicati


Email address:

slidedow n

Federal Contract Oversight

by Project on Government Oversight (POGO)
Podcast: How Bad Performance Can Be Good for Business in Government Contracting

POGO Provides Post-hearing Supplemental Materials to the Commission on Wartime Contracting

Solution: How the Government Can Stop Doing Business With Risky Contractors

U.S.Government Rarely Suspends or Debars Those Responsible for Billions in Tax Dollars Lost to Fraud, Waste, Abuse in War Zones

Commercial Item Exceptions Must be Eliminated From New Suspension and Debarment Rule

Should Debarred Contractors Be Allowed to Build Military Aircraft?

Pentagon Cuts Back Contract Audits, Opens Door for Contractor Overpayments

Testimony of POGO's Nick Schwellenbach on "Improving Federal Contract Auditing"

Federal Government Needs Strong, Independent Auditor to Oversee Billions in Contract Spending, POGO Tells Senate Panel

Last Modified: Tuesday, March 22, 2011 1:05:58 PM

Add our news feed to your favorites:






GALT:#6C82B5;G en

Enter your search terms Submit search form



This site

Recent Searches: A B C D E F G H I J K L M N O P Q

R S T U V W X Y Z Others
Home | How to write an RFP Letter | FREE RFP Letters Templates and Samples

About Us | Site Map | Privacy Policy | Copyright October 2011 by RFP Evaluation Centers. All rights reserved (Tuesday October 25, 2011) RFP Evaluation Centers 740 Saint-Maurice Street, 4th floor Montral (Qubec) H3C 1L5, Canada 1-800-496-1303 ext. 273 (toll free) 1-514-954-3665 ext. 273 (office) 1-514-954-9739 (fax) Email: Disclaimer: We maintain this web site as a service we gracefully offer you, decision makers working at organizations whether requesting or providing external services and products, and who are interested in finding online free templates and samples of documents related to solicitation and selection processes. You are hereby cautioned not to consider the content provided on this web site and all its ancillary documents as a legal or contracting policy advice whatsoever. Indeed, this information should not be relied upon as a substitution for consulting a lawyer. We provide you, only as a convenience, with external references (books, links, etc.) that are not under our control. We are not responsible for their content and, therefore, assume no liability. We are eager to help you out in your information quest, call us at our toll-free number 1-800-496-1303 ext. 273.


The following problems are maximum/minimum optimization problems. They illustrate one of the most important applications of the first derivative. Many students find these problems intimidating because they are "word" problems, and because there does not appear to be a pattern to these problems. However, if you are patient you can minimize your anxiety and maximize your success with these problems by following these guidelines :


1. Read each problem slowly and carefully. Read the problem at least three times before trying to solve it. Sometimes words can be ambiguous. It is imperative to know exactly what the problem is asking. If you misread the problem or hurry through it, you have NO chance of solving it correctly.

2. If appropriate, draw a sketch or diagram of the problem to be solved. Pictures are a great help in organizing and sorting out your thoughts. 3. Define variables to be used and carefully label your picture or diagram with these variables. This step is very important because it leads directly or indirectly to the creation of mathematical equations. 4. Write down all equations which are related to your problem or diagram. Clearly denote that equation which you are asked to maximize or minimize. Experience will show you that MOST optimization problems will begin with two equations. One equation is a "constraint" equation and the other is the "optimization" equation. The "constraint" equation is used to solve for one of the variables. This is then substituted into the "optimization" equation before differentiation occurs. Some problems may have NO constraint equation. Some problems may have two or more constraint equations. 5. Before differentiating, make sure that the optimization equation is a function of only one variable. Then differentiate using the well-known rules of differentiation. 6. Verify that your result is a maximum or minimum value using the first or second derivative test for extrema.

The following problems range in difficulty from average to challenging.

PROBLEM 1 : Find two nonnegative numbers whose sum is 9 and so that the product of one number and the square of the other number is a maximum.

Click HERE to see a detailed solution to problem 1.

PROBLEM 2 : Build a rectangular pen with three parallel partitions using 500 feet of fencing. What dimensions will maximize the total area of the pen ?

Click HERE to see a detailed solution to problem 2.

PROBLEM 3 : An open rectangular box with square base is to be made from 48 ft.2 of material. What dimensions will result in a box with the largest possible volume ?

Click HERE to see a detailed solution to problem 3.

PROBLEM 4 : A container in the shape of a right circular cylinder with no top has surface area 3 ft.2 What height h and base radius r will maximize the volume of the cylinder ?

Click HERE to see a detailed solution to problem 4.

PROBLEM 5 : A sheet of cardboard 3 ft. by 4 ft. will be made into a box by cutting equal-sized squares from each corner and folding up the four edges. What will be the dimensions of the box with largest volume ?

Click HERE to see a detailed solution to problem 5.

PROBLEM 6 : Consider all triangles formed by lines passing through the point (8/9, 3) and both the x- and y-axes. Find the dimensions of the triangle with the shortest hypotenuse.

Click HERE to see a detailed solution to problem 6.

PROBLEM 7 : Find the point (x, y) on the graph of

nearest the point (4, 0).

Click HERE to see a detailed solution to problem 7.

PROBLEM 8 : A cylindrical can is to hold 20 m.3 The material for the top and bottom costs $10/m.2 and material for the side costs $8/m.2 Find the radius r and height h of the most economical can.

Click HERE to see a detailed solution to problem 8.

PROBLEM 9 : You are standing at the edge of a slow-moving river which is one mile wide and wish to return to your campground on the opposite side of the river. You can swim at 2 mph and walk at 3 mph. You must first swim across the river to any point on the opposite bank. From there walk to the campground, which is one mile from the point directly across the river from where you start your swim. What route will take the least amount of time ?

Click HERE to see a detailed solution to problem 9.

PROBLEM 10 : Construct a window in the shape of a semi-circle over a rectangle. If the distance around the outside of the window is 12 feet, what dimensions will result in the rectangle having largest possible area ?

Click HERE to see a detailed solution to problem 10.

PROBLEM 11 : There are 50 apple trees in an orchard. Each tree produces 800 apples. For each additional tree planted in the orchard, the output per tree drops by 10 apples. How many trees should be added to the existing orchard in order to maximize the total output of trees ?

Click HERE to see a detailed solution to problem 11.

PROBLEM 12 : Find the dimensions of the rectangle of largest area which can be inscribed in the closed region bounded by the x-axis, y-axis, and graph of y=8-x3 . (See diagram.)

Click HERE to see a detailed solution to problem 12.

PROBLEM 13 : Consider a rectangle of perimeter 12 inches. Form a cylinder by revolving this rectangle about one of its edges. What dimensions of the rectangle will result in a cylinder of maximum volume ?

Click HERE to see a detailed solution to problem 13.

PROBLEM 14 : A movie screen on a wall is 20 feet high and 10 feet above the floor. At what distance x from the front of the room should you position yourself so that the viewing angle of the movie screen is as large as possible ? (See diagram.)

Click HERE to see a detailed solution to problem 14.

PROBLEM 15 : Find the dimensions (radius r and height h) of the cone of maximum volume which can be inscribed in a sphere of radius 2.

Click HERE to see a detailed solution to problem 15.

PROBLEM 16 : What angle between two edges of length 3 will result in an isosceles triangle with the largest area ? (See diagram.)

Click HERE to see a detailed solution to problem 16.

PROBLEM 17 : Of all lines tangent to the graph of lines of mimimum slope and maximum slope.

, find the tangent

Click HERE to see a detailed solution to problem 17.

PROBLEM 18 : Find the length of the shortest ladder that will reach over an 8-ft. high fence to a large wall which is 3 ft. behind the fence. (See diagram.)

Click HERE to see a detailed solution to problem 18.

PROBLEM 19 : Find the point P = (x, 0) on the x-axis which minimizes the sum of the squares of the distances from P to (0, 0) and from P to (3, 2).

Click HERE to see a detailed solution to problem 19.

PROBLEM 20 : Car B is 30 miles directly east of Car A and begins moving west at 90 mph. At the same moment car A begins moving north at 60 mph. What will be the minimum distance between the cars and at what time t does the minimum distance occur ?

Click HERE to see a detailed solution to problem 20.

PROBLEM 21 : A rectangular piece of paper is 12 inches high and six inches wide. The lower right-hand corner is folded over so as to reach the leftmost edge of the paper (See diagram.).

Find the minimum length of the resulting crease.

Click HERE to see a detailed solution to problem 21.

Click HERE to return to the original list of various types of calculus problems.

Your comments and suggestions are welcome. Please e-mail any correspondence to Duane Kouba by clicking on the following address :

About this document ...

Duane Kouba 1998-06-16


<script language="JavaScript" src=";navArea=DUMMIES2_CONTENT;pageType =Article;contentType=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_ DERIVATIVES;cat=EDUCATION;cat=MATH;tile=1;dcopt=ist;sz=728x90;abr=!ie;ord=781164 9515560246?" type="text/javascript"></script><a href=";navArea=DUMMIES2_CONTENT;pageTy pe=Article;contentType=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULU S_DERIVATIVES;cat=EDUCATION;cat=MATH;tile=1;sz=728x90;ord=123456789?" target="_blank"><img src=";navArea=DUMMIES2_CONTENT;pageType =Article;contentType=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_ DERIVATIVES;cat=EDUCATION;cat=MATH;tile=1;sz=728x90;ord=123456789?" width="728" height="90" border="0" alt=""></a>


See All Topics

Business & CareersComputers & SoftwareConsumer ElectronicsCrafts & HobbiesEducation & LanguagesFood & DrinkHealth & FitnessHome & GardenInternetMusic & Creative ArtsPersonal FinancePetsPhotography & VideoRelationships & FamilyReligion & SpiritualitySports & OutdoorsGamesTravel

Education & Languages CollegeHistoryHolidays & ObservancesHomeschoolingLanguage ArtsLanguages & CulturesLiteratureMathPhilosophyPsychologyPolitics & GovernmentScienceTest Prep Math Basic Math & Pre-AlgebraAlgebraCalculusGeometryTrigonometryStatisticsProbability Calculus Pre-Algebra and Algebra BasicsTrigonometry BasicsPre-CalculusGraphing EquationsFunctionsLimitsDerivativesCurves & LinesFinding AreaIntegrationIntegrals and Trig FunctionsFinding VolumeSeriesPractical ApplicationsDerivatives

Add a Comment

Print Share This

Calculus: How to Solve Differentiation Problems

By Mark Ryan Part of the Calculus Workbook For Dummies Cheat Sheet In calculus, the way you solve a derivative problem depends on what form the problem takes. Common problem types include the chain rule; optimization; position, velocity, and acceleration; and related rates. Here are a few things to remember when solving each type of problem: Chain Rule problems 1. 2. 3. 4. Use the chain rule when the argument of the function youre differentiating is more than a plain old x. Work from outside, in. Dont touch the inside stuff. Do only one derivative per step.

Optimization problems 1. 2. 3. Express the thing you want to minimize or maximize as a function of the unknown. Differentiate and set the derivative equal to zero. Solve and plug the solution into the original function.

Position, velocity, and acceleration problems 1. The derivative of position is velocity and the antiderivative of velocity is position.


The derivative of velocity is acceleration and the antiderivative of acceleration is velocity.

Related rates problems 1. 2. 3. Assign variables to changing quantities, but not to unchanging things. Differentiate before plugging in variable values. Use the Pythagorean Theorem for right triangle problems and use similar triangles for problems involving cones or shapes that have a triangular cross-section.

Add a Comment


Print Share This

How to Differentiate Exponential and Logarithmic Functions How to Differentiate the Trigonometric Functions The Difference Quotient: The Bridge between Algebra (Slope) and Calculus (the Derivative) How to Find Derivatives Using the Product and Quotient Rules How to Know When a Derivative Doesn't Exist How to Find the Derivative of a Line How to Use the Chain Rule to Find the Derivative of Nested Functions The Basic Differentiation Rules How to Find a Function's Derivative by Using the Chain Rule

The Most Important Derivatives and Antiderivatives to Know Sponsored Links IIT JEE Self Study Course Self Study Course From IIT Alumni For Classes 10, 11, 12 Enroll Free Class 1 to Class 12 Lessons, Animations, Videos & more Math, EVS, Science, English, SST IIT JEE Maths Material Theory, IIT Solutions in Video form Prepared by Topper. Free Demo Please enable JavaScript to view the <a href="">comments powered by Disqus.</a>blog comments powered by Disqus <script language="JavaScript" src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=2;sz=234x60;abr=!ie;ord=7811649515560246?" type="text/javascript"></script><a href=";navArea=DUMMIES2_CONTENT;pageType=Article;contentTy pe=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat= MATH;tile=2;sz=234x60;ord=123456789?" target="_blank"><img src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=2;sz=234x60;ord=123456789?" width="234" height="60" border="0" alt=""></a>

SERIES Calculus Workbook For Dummies Cheat Sheet PREVIOUS Evaluating Limits in Calculus NEXT Calculus: Techniques of Integration

<script language="JavaScript" src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=3;dcopt=ist;sz=300x250;abr=!ie;ord=7811649515560246?" type="text/javascript"></script><a href=";navArea=DUMMIES2_CONTENT;pageType=Article;contentTy pe=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat= MATH;tile=3;sz=300x250;ord=123456789?" target="_blank"><img src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=3;sz=300x250;ord=123456789?" width="300" height="250" border="0" alt=""></a>

<script language="JavaScript" src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=4;dcopt=ist;sz=300x250;abr=!ie;ord=7811649515560246?" type="text/javascript"></script><a href=";navArea=DUMMIES2_CONTENT;pageType=Article;contentTy pe=article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat= MATH;tile=4;sz=300x250;ord=123456789?" target="_blank"><img src=";navArea=DUMMIES2_CONTENT;pageType=Article;contentType =article;articleProduct=076458782X;cat=CALCULUS;cat=CALCULUS_DERIVATIVES;cat=EDUCATION;cat=MA TH;tile=4;sz=300x250;ord=123456789?" width="300" height="250" border="0" alt=""></a> Get the Book

Calculus Workbook For Dummies US $16.99 Newsletters Sign up for one of our newsletters... Computers, Mobile Devices & Gadgets Digital Photography Add to Cart

eBay & Online Business Food, Home & Garden Health & Wellness Mac Microsoft Windows & Office Online & Social Networking Personal Finance & Investing
enter E-Mail addre

Privacy Policy


High school, college, pro, or fantasy get in the game with help from

Put LinkedIn to work as your online professional networking place to be.

Its free, its fun, and the possibilities are endless! Make and share now.

Make everything easier on the go! Get helpful information with our best selling apps for iPhone and iPod touch.

About For Dummies

Subscribe or Unsubscribe to E-Mail Newsletters

My Account Store

Shopping Cart Topics A-Z

Help Privacy Policy

Terms and Conditions Advertise with Us

Contact Us Copyright 2011 & Trademark by John Wiley & Sons, Inc. All rights reserved.

Programming Techniques, Tools and Languages Group Home | Research | Blog | Calendar

Concept Based Optimization

Group / Research / Concept Based Optimization /

eShare Inc. All rights reserved. 00759748749027 FORID:0

Section Links

Motivations for Concept-Based Optimizations Concept-Based Optimizations Using the Prototype for Concept-Based Optimizations Adobe Benchmark


Jaakko Jrvi Xiaolong Tang Motivations for Concept-Based Optimizations Traditional compilers typically simplify expressions via a set of built-in optimizing rules whose correctness is generally justified by certain algebraic laws. These optimizing rules, however, are hard-coded and only apply to expressions of built-in types. For example, a C++ compiler will simplify the integer addition x + 0 via the optimizing rule i + 0 -> i justified by the algebraic right identity law . The same law also holds for the user-defined string operator+(x, y) in C++, and that is, we can safely rewrite s + string() into s. The C++ compiler, however, fails to conduct this rewriting, because the compiler's optimizing rules are hard-coded with specific built-in types, neither allowing users to specify optimizing rules nor automatically proving the validation of the right identity law for string and applying this law to s + string(). Instead, to optimize s + string(), the compiler has to inline the default constructor of the string class, the string operator+(x, y), and analyze the expanded code against the built-in optimizing rules, which means significant amount of work. A straightforward means to enable the compiler to apply the right identity law to the string operator+(x, y) is supplying the compiler with this

rewrite rule s + string() -> s. Obviously, directly encoding this rule in the compiler is not the standard course of programming compilers. A preprocessor or source-to-source translator may allow users to specify rewrite rules and preprocess users' code via these customized rules. This approach's limitations consist of: 1) users need to specify different rewrite rules for different types, though all of these rewrite rules are instances of one algebraic law such as the algebraic identity law; 2) this pre-processor or source-to-source translator hardly utilizes the results of compilers' analyses and optimizations that can reveal new facts for rewriting; for example, in the sequence code string s; string t=string(); string l = s + t, accessing the code's data flow graph reveals s + t == s + string(), which in turn justifies applying the rewrite rule s + string() -> s. A second approach is allowing users to specify generic algebraic laws, and declare the validation of applying these laws to certain expressions

SlideShare. Present yourself.



Upload Login or Signup Go PRO Remove this ad

Matrices And Application Of Matrices

2 years ago

Email Favorite Download Embed

Copy and paste this code into your blog or website

Copy 340 x 284425 x 355510 x 426595 x


Shortcode for blogs


Write a comment...

Matrices And Application Of Matrices - Presentation Transcript

1. 2.

Matrices & Application of Matrices Matrices o Matrix ( plural matrices ) is a rectangular table of elements (or entries) These elements are abstract quantities that can be added and multiplied. Numbers 3. o Matrices come in all possible rectangular shapes, the following are a number of examples of matrices o In general, we denote a matrix by o Each a ij is called an element of the matrix (or an entry of the matrix); this denotes the element in row i and column j . The entries of the matrix are organized in horizontal rows and vertical columns 4. o The size, or dimension, of the matrix is n x m, where, n is the number of rows of the matrix, m is the number of column of the matrix. o For example, the following matrices are of dimensions 1x4, 3x1, 2x3, and 4x2 respectively o A special kind of matrix is a square matrix , i.e. a matrix with the same number of rows and columns. If a square matrix has n rows and n columns, we say that the matrix has order n. The matrix is a square matrix of order 3. 5. Application of Matrices o Graph theory The adjacency matrix of a finite graph is a basic notion of graph theory. o Linear combinations of quantum states in Physics The first model of quantum mechanics by Heisenberg in 1925 represented the theory's operators by infinite-dimensional matrices acting on quantum states. This is also referred to as matrix mechanics . o Computer graphics 44 transformation rotation matrices are commonly used in computer graphics. o Solving linear equations Using Row reduction Cramer's Rule ( Determinants) Using the inverse matrix o Cryptography. 6. Application of Matrices in Cryptography 7. o Cryptography, is concerned with keeping communications private. o Cryptography mainly consists of Encryption and Decryption o Encryption is the transformation of data into some unreadable form. Its purpose is to ensure privacy by keeping the information hidden from anyone for whom it is not intended, even those who can see the encrypted data. o Decryption is the reverse of encryption It is the transformation of encrypted data back into some intelligible form. o Encryption and Decryption require the use of some secret information, usually referred to as a key. o Depending on the encryption mechanism used, the same key might be used for both encryption and decryption, while for other mechanisms, the keys used for encryption and decryption might be different. Cryptography 8. Application of matrix to Cryptography One type of code, which is extremely difficult to break, makes use of a large matrix to encode a message. The receiver of the message decodes it using the inverse of the matrix. This first matrix, used by the sender is called the encoding matrix and its inverse is called the decoding matrix, which is used by the receiver. 9. o Message to be sent: PREPARE TO NEGOTIATE and the encoding matrix be We assign a number for each letter of the alphabet. Such that A is 1, B is 2, and so on. Also, we assign the number 27 to space between two words. Thus the message becomes: 10. o Since we are using a 3 by 3 matrix, we break the enumerated message above into a sequence of 3 by 1 vectors: o Note that it was necessary to add a space at the end of the message to complete the last vector. o We encode the message by multiplying each of the above vectors by the encoding matrix.

o o o

We represent above vectors as columns of a matrix and perform its matrix multiplication with the encoding matrix Encoding

11. We get The columns of this matrix give the encoded message. Encoding is complete 12. Transmission o The message is transmitted in a linear form 13. Decoding o To decode the message: The receiver writes this string as a sequence of 3 by 1 column matrices and repeats the technique using the inverse of the encoding matrix. The inverse of this encoding matrix is the decoding matrix. To decode the message, perform the matrix multiplication Matrix obtained is 14. Decoded Message o The columns of this matrix, written in linear form, give the original message o Message received: PREPARE TO NEGOTIATE 15. o Thank You ! o

o o o

mailrenuka+ Follow 6500 views, 0 favs, 1 embed more


Matrices 11158 views

Matrices777 views

MATRICES247 views

Matrices and determinats272 views

Matrices1035 views

CPSC 125 Ch 4 Sec 6273 views

Matrices & determinants87 views

CPSC 125 Ch 4 Sec 6400 views

Math 1300: Section 4-5 Inverse of a Square Matrix222 views


Matrixes (Addition, subtraction, inverse part 1)419 views

MATRICES1566 views

Lesson 1 Feb 08 2010220 views

Matrix multiplication, inverse367 views

Matrices and determinants1377 views

Matrices and determinants481 views

Harvard_University_-_Linear_Al199 views

Harvard_University_-_Linear_Al361 views

Matrices y determinants166 views

Week2492 views

More by user

Matrices191 views

Entry Of Pepsi In India2213 views

Meditation Techniques372 views

Simulation Techniques2698 views

Software Development Life Cycle.566 views

View all presentations from this user

About this presentation


All Rights Reserved


0 Favorites 0 Comments 0 Downloads 6,494 Views on SlideShare 6 Views on Embeds 6,500 Total Views

6 views on

View text version


Also on LinkedIn Uploaded via SlideShare Uploaded as Microsoft PowerPoint Flag as inappropriate File a copyright complaint 4 4 0



LEARN ABOUT US About Careers Our Blog Press Contact us Help & Support USING SLIDESHARE SlideShare 101 Terms of Use Privacy Policy Copyright & DMCA Community Guidelines SLIDESHARE OUTSIDE SlideShare Mobile Facebook App LinkedIn App Widgets for your blog PRO & MORE Go PRO Business Solutions Advertise with us Get featured on homepage DEVELOPERS & API Developers Section Developers Group

Engineering Blog SlideShare is the world's largest community for sharing presentations. Upload and share on blogs, Twitter, Facebook or LinkedIn. Over 60 million people use SlideShare every month for research, sharing ideas, connecting with others, and generating business leads. SlideShare also supports documents, PDFs, and videos.Get an account.

Follow @SlideShare

2011 SlideShare Inc. All rights reserved.

< !-- Quantcast noscript tracking-->< img src="" height="1" alt="Quantcast" style="border:0;display:none" width="1" />< !-- Comscore noscript tracking -->< img src="" height="1" alt=" " width="1" />

of specific types (both built-in and user-defined), and designating the compiler to accomplish the application. Because it is the compiler that performs the rewriting on expressions, this approach can be integrated with the compiler's analyses and optimizations. Concept-Based Optimizations Concept-Based Optimizations is essentially the above second approach. It exploits the principles and techniques of generic programming to build compiler optimizations generically, such that compiler optimizations apply not only to built-in types and operations, but to user-defined types and operations. You can find more discussions on concept-based optimizations in the following paper: 1. Xiaolong Tang and Jaakko Jrvi. Concept-based optimization. In ACM SIGPLAN Symposium on Library-Centric Software Design (LCSD'07), October 2007. The project group is Jaakko Jrvi, Xiaolong Tang. For further information, please contact

Using Our Prototype for Concept-Based Optimizations We already built a prototype that supports concept-based optimizations and the following describes how to use this prototype in detail. The prototype is built on Douglas Gregor's ConceptGCC (Douglas Gregor is from the Open Systems Laboratory in Indiana University) which implements the generic programming features in the forthcoming revision of C++, known as C++0X. The compiler ConceptGCC, built on GCC, implements a preliminary version of the concepts feature in C++0X. A detailed description on ConceptGCC can be found via this link: ConceptGCC. The remainder of this webpage describes how to check out the source code of this prototype, build the source code, install the just built compiler, and experience concept-based optimizations with it.

Obtaining the Source Code of the Prototype

Our prototype is available only as source code now. To retrieve the source code, you will need an installed Subversion client on your system. To checkout a latest copy of our prototype, use:
svn co

Configure, Build, and Install the Source Code

Configuration, building and installation follow the same procedure for ConceptGCC. Please find it via this link: installing ConceptGCC.

Experiencing Algebraic Simplifications for User-defined Types

As an example, we show how to enable identity optimizations for userdefined types. Three steps are involved into this process:
Step 1: Specifying Algebraic Identity Law

Generic algebraic laws are specified via invariants defined in axioms of concepts. We use algebraic concepts to encode the generic laws. More discussions about algebraic concepts can be found in the following paper:

Peter Gottschling and Walter E. Brown. Toward a more complete taxonomy of algebraic properties for numeric libraries. Technique Report N2650 08-0160, ISO/IEC JTC 1, Information Technology, Subcommittee SC 22, Programming Language C++, May 2008. In our example, we encode the identity laws in the algebraic concept.
concept Monoid : std::Semiregular, std::DefaultConstructible { requires std::Callable2; requires std::SameType<std::Callable2::result_type, T>; T identity_element(Op, T); axiom Identity(Op op, T x) { op(x, identity_element(op, x)) == x; op(identity_element(op, x), x) == x; } } </std::Callable2

Note that the two invariants in the axiom Identity are to be interpreted as generic right identity rewrite rules and left identity rule. A more complete definition for algebraic concepts can be found in this header file: algconcept.hpp.
Step 2: Declaring the identity law validation for user-defined types

The correctness of applying identity laws to specific types is established by corresponding Monoid's concept maps to these specific types. For example, to enable algebraic laws for string, what users need is defining this concept map:
concept_map Monoid< std::plus, std::string>{ std::string identity_element( std::string op, string x) { return string(""); } };

Step 3: Compiling with Concept-Based Optimizations

Our prototype uses the flag -fconcept-simplify to turn on concept-based optimizations. Note that, currently, to enable the proper running of

concept-based optimizations, these flags -O2 and -fno-exceptions must be specified as well. To optimize the following code in the file string_add.cpp, use this command:
conceptg++ -fno-exceptions -fconcept-simplify -O2 -o string_add.exe string_add.cpp #include #include #include #include "algconcept.hpp" concept_map Monoid<std::plus, std::string>{ std::string identity_element(std::plus op, std::string x) { return std::string(""); } }; inline std::string test1 () { std::string x(""); std::string y("text"); return x + y; } int main(int argc, char* argv[]) { std::string z = test1(); return 0; } </std::plus

To tell if concept-based optimizations work or not, you can supplement the compiling command with the flag -fdump-tree-all and check the output when issuing this command:
grep -n -A10 "Matching" *.axiommatch1

The output will be like the following snippet. 1. Line 1032 tells a successful match with the expression operator+(&x, &y); 2. Line 1059 tells a rewriting operations from operator+(&x, 3. Line 1061 tells the resulting expression after rewriting.

&y) -> y;

1032:Candidate Matching Statement:operator+ (&x, &y) [return slot optimization]; 1033-

1034- Subject Pattern 1035-----------------begin---------------------1036-The subject term is as follows: 1037-(1,1) [postion: (null) code call_expr type: 3a8dcb0 node 3c3d6f0 pck_fun_cell] 1038-(1,2) [postion: (null) code function_decl type: 3445620 node 3c38380 pck_code_cell] 1039-(1,3) [postion: (null) code array_ref type: 41c1f770 node 3c3d5d0 pck_ref_cell] 1040-(1,4) [postion: (null) code string_cst type: 3460bd0 node 2e96820 pck_const_cell] 1041-(1,5) [postion: (null) code integer_cst type: 41c16000 node 41c052d0 pck_const_cell] 1042-(1,6) [postion: (null) code integer_cst type: 41c16000 node 41c052d0 pck_const_cell] -1053:Checking Matching Succeed! 1054-The statement:x_2(D) 10551056-The tree node: x_2(D) 1057-Founc cell: [postion: (null) code var_decl type: 10581059-Changed into:y 10601061-The whole statement at tage 1:*D.142756_1 = y; 1062-The statement used to bsi_replace is:__comp_ctor (D.142756_1, &y); 1063-

3a8dd20 node

In the future, we will provide a convenient way to tell the effects of concept-based optimizations when compiling code with -fconceptsimplify . Adobe Benchmark We have done experiments with the Adobe Benchmark. The benchmark contains a suite of benchmark for C++ performance that are written by Chris Cox from Adobe. Amongst this suite, custom_types_algebraic_simplification.cpp aims for measuring C++ abstraction penalties regarding algebraic simplifications for user-defined types. Please check the website C++ performance for the complete introduction on this benchmark. Here we only list some necessary files for reference. 1. custom_types.h

Upcoming Events

Share This Article



About Us | Parasol Lab | Computer Science and Engineering | 2010 Texas A&M University




Recent site activity

Help center

Browse categories

Random question

Promoted questions

Community forum

Answer these

What mottling can you get with a blue moon and a black love berry?

In: Computer Games

Answer it!

How many immigrants does Australia let in each year?

In: Australia

Answer it!

What are the names of the shrimps?

In: Shrimp

Answer it!

What Pokemon in Pokemon platinum don't evolve normally?

In: Pokemon Diamond Pearl and Platinum

Answer it!

Featured guides

How to Write Job Descriptions

All About Online Trading

Vegan Recipes For Kids

How To Save On Airport Parking

What To Look For When Buying A Car

Ads by Google


Construction Jobs

Solve Math Equations

School of Education

Site Sitemap ReferenceAnswers WikiAnswers VideoAnswers blufr Guides

Company About Jobs Press


Terms of Use Privacy Policy IP Issues Disclaimer

Tools 1-Click Answers AnswerTips Webmasters Apps/Add-ons

Community Guidelines Reputation Roles Help

Updates Email Watchlist RSS Blog

International sites English Deutsch Espaol Franais Italiano Tagalog

Copyright 2011 Answers Corporation