Professional Documents
Culture Documents
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.
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
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
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.
vvvvvvv
English
Thinking ahead even more. Do you want to think ahead with us?
Lessons, Animations, Videos & more Math, EVS, Science, English, SST
Ads
Answers.com > Wiki Answers > Categories > Jobs & Education > Education > School Subjects > Math > Algebra > Abstract Algebra > What are applications for matrices?
Answer:
Improve
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.
We never know all properties at start, we first found relations between variables by doing practicals & form equations.........
So which ever system can be represented by equations, matrices have application there........
e.g. computer programmes, financial calculations, chemical processes, construction calculations etc...........
CBSE Math, Science, Social, English Papers, Tests. Join for Free.
Ads
First answer by Satya jit5. Last edit by Satya jit5. Contributor trust: 0 [recommend contributor]. Question popularity: 0 [recommend question]. [report abuse]
Answer it!
Answer it!
Answer it!
Answer it!
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...
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,...
Fish Pages
About the Blog About NDU About us Another teacher at NDU EduBlogging
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:
power-generating
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
Reactions:
2 comments:
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:
blogspot/eGnV
en_US
Subscribe
Delivered by FeedBurner
Labels
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) http://www.sosmath.com/matrix/coding/coding.html (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
- 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)
About Us |
Site Map |
Search
Home |
Free of charge Immediate delivery to your email Call 1-800-496-1303 ext. 273
More FAQ...
Sort by :
Relevance
Recent Searches: A B C D
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...
matrices applicati
Email address:
slidedow n
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
Pentagon Cuts Back Contract Audits, Opens Door for Contractor Overpayments
Federal Government Needs Strong, Independent Auditor to Oversee Billions in Contract Spending, POGO Tells Senate Panel
pub-4874703045
3371756846 rfptemplates.tech
ISO-8859-1
ISO-8859-1
active
GALT:#6C82B5;G en
Web
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: rfp2009@rfp-templates.com 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.
MAXIMUM/MINIMUM PROBLEMS
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 :
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.
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.
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 ?
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 ?
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 ?
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 ?
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.
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.
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 ?
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 ?
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 ?
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.)
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 ?
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.)
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.
PROBLEM 16 : What angle between two edges of length 3 will result in an isosceles triangle with the largest area ? (See diagram.)
PROBLEM 17 : Of all lines tangent to the graph of lines of mimimum slope and maximum slope.
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.)
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).
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 ?
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.).
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 : kouba@math.ucdavis.edu
Advertisement
<script language="JavaScript" src="http://ad.doubleclick.net/adj/DummiesSite/;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="http://ad.doubleclick.net/jump/DummiesSite/;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="http://ad.doubleclick.net/ad/DummiesSite/;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>
Search
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
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.
2.
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
Related
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 www.topIITcoaching.com Class 1 to Class 12 Lessons, Animations, Videos & more Math, EVS, Science, English, SST www.MeritNation.com IIT JEE Maths Material Theory, IIT Solutions in Video form Prepared by Topper. Free Demo ExponentEducation.com/IIT_Maths Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a>blog comments powered by Disqus <script language="JavaScript" src="http://ad.doubleclick.net/adj/DummiesSite/;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="http://ad.doubleclick.net/jump/DummiesSite/;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="http://ad.doubleclick.net/ad/DummiesSite/;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
Advertisement
<script language="JavaScript" src="http://ad.doubleclick.net/adj/DummiesSite/;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="http://ad.doubleclick.net/jump/DummiesSite/;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="http://ad.doubleclick.net/ad/DummiesSite/;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>
Advertisement
<script language="JavaScript" src="http://ad.doubleclick.net/adj/DummiesSite/;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="http://ad.doubleclick.net/jump/DummiesSite/;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="http://ad.doubleclick.net/ad/DummiesSite/;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
Inside Dummies.com
FOOTBALL FUN FOR EVERYONE POWER UP YOUR CONNECTIONS CREATE A FOR DUMMIES COVER FOR DUMMIES MOBILE APPS
High school, college, pro, or fantasy get in the game with help from Dummies.com
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.
My Account Store
Help
Contact Us Copyright 2011 & Trademark by John Wiley & Sons, Inc. All rights reserved.
Programming Techniques, Tools and Languages Group Home | Research | Blog | Calendar
Section Links
Motivations for Concept-Based Optimizations Concept-Based Optimizations Using the Prototype for Concept-Based Optimizations Adobe Benchmark
People
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
Search
497
Copy
0 comments
Write a comment...
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
Related
Matrices777 views
MATRICES247 views
Matrices1035 views
DETERMINANTS971 views
MATRICES1566 views
Harvard_University_-_Linear_Al199 views
Harvard_University_-_Linear_Al361 views
Week2492 views
More by user
Matrices191 views
0 Favorites 0 Comments 0 Downloads 6,494 Views on SlideShare 6 Views on Embeds 6,500 Total Views
EMBED VIEWS
6 views on http://www.slideshare.net
ACCESSIBILITY
Also on LinkedIn Uploaded via SlideShare Uploaded as Microsoft PowerPoint Flag as inappropriate File a copyright complaint 4 4 0
footer
Search
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
New
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
< !-- Quantcast noscript tracking-->< img src="http://pixel.quantserve.com/pixel/p-abU44ONrAuwk2.gif" height="1" alt="Quantcast" style="border:0;display:none" width="1" />< !-- Comscore noscript tracking -->< img src="http://b.scorecardresearch.com/p?c1=2&c2=7400849&c3=&c4=&c5=&c6=&c15=&cj=1" 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 jarvi@cs.tamu.edu.
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.
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(""); } };
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;
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
Tweet
Headlines
About Us | Parasol Lab | Computer Science and Engineering | 2010 Texas A&M University
fc
Home
Welcome
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?
Answer it!
In: Australia
Answer it!
In: Shrimp
Answer it!
Answer it!
Featured guides
Ads by Google
Algebra
Construction Jobs
School of Education
Legal