1 Complete this to a Pfaffian orientation (all internal faces have an odd number of clockwise arcs).

Slides:



Advertisements
Similar presentations
Divide-and-Conquer CIS 606 Spring 2010.
Advertisements

1 CSE 417: Algorithms and Computational Complexity Winter 2001 Lecture 4 Instructor: Paul Beame TA: Gidon Shavit.
Strassen's Matrix Multiplication Sibel KIRMIZIGÜL.
Divide-and-Conquer Matrix multiplication and Strassen’s algorithm Median Problem –In general finding the kth largest element of an unsorted list of numbers.
Lecture 10 Jianjun Hu Department of Computer Science and Engineering University of South Carolina CSCE350 Algorithms and Data Structure.
1 Reduction between Transitive Closure & Boolean Matrix Multiplication Presented by Rotem Mairon.
CS Section 600 CS Section 002 Dr. Angela Guercio Spring 2010.
1 Fast Sparse Matrix Multiplication Raphael Yuster Haifa University (Oranim) Uri Zwick Tel Aviv University ESA 2004.
Divide-and-Conquer Matrix multiplication and Strassen’s algorithm.
Towards Communication Avoiding Fast Algorithm for Sparse Matrix Multiplication Part I: Minimizing arithmetic operations Oded Schwartz CS294, Lecture #21.
CSE 421 Algorithms Richard Anderson Lecture 11 Recurrences.
Exponent Rules Repeated Multiplication Remember: so and.
EXAMPLE 2 Find a least common multiple (LCM)
4.3 The Inverse of a Matrix Warm-up (IN)
Table of Contents Matrices - Inverse Matrix Definition The inverse of matrix A is a matrix A -1 such that... and Note that... 1) For A to have an inverse,
The Answer is RIGHT.
Objectives: Standard 15.0 I will find the LCM (Least Common Multiple) of the given denominators I will simplify the rational expressions by using the LCM.
Matrix Equations Step 1: Write the system as a matrix equation. A three-equation system is shown below.
4.2 Operations with Matrices Scalar multiplication.
Multiples 1 X 2 = 22 X 2 = 43 X 2 = 6 4 X 2 = 8 What do you call 2,4,6,8 ?Multiples of 2 Why?
Prof. Swarat Chaudhuri COMP 482: Design and Analysis of Algorithms Spring 2013 Lecture 12.
MA/CSSE 473 Day 17 Divide-and-conquer Convex Hull Strassen's Algorithm: Matrix Multiplication.
PROPERTIES OF EXPONENTS
Exponents Power base exponent means 3 factors of 5 or 5 x 5 x 5.
Numerical Algorithms Quiz questions ITCS4145/5145, Parallel Programming March 14, 2013.
8.2 Operations With Matrices
1 Chapter 4-2 Divide and Conquer Slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved.
ADA: 4.5. Matrix Mult.1 Objective o an extra divide and conquer example, based on a question in class Algorithm Design and Analysis (ADA) ,
Lecture 5 Today, how to solve recurrences We learned “guess and proved by induction” We also learned “substitution” method Today, we learn the “master.
Divide and Conquer. Recall Divide the problem into a number of sub-problems that are smaller instances of the same problem. Conquer the sub-problems by.
EXAMPLE 1 Add and subtract matrices
1.7 Linear Independence. in R n is said to be linearly independent if has only the trivial solution. in R n is said to be linearly dependent if there.
1 How to Multiply Slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved. integers, matrices, and polynomials.
Calculating with Negatives THE FOUR RULES AND NEGATIVE NUMBERS.
Divide and Conquer Faculty Name: Ruhi Fatima Topics Covered Divide and Conquer Matrix multiplication Recurrence.
3.6 Multiplying Matrices Homework 3-17odd and odd.
CSE 421 Algorithms Richard Anderson Lecture 13 Recurrences, Part 2.
CSCI-256 Data Structures & Algorithm Analysis Lecture Note: Some slides by Kevin Wayne. Copyright © 2005 Pearson-Addison Wesley. All rights reserved. 16.
Notes Over 4.2 Finding the Product of Two Matrices Find the product. If it is not defined, state the reason. To multiply matrices, the number of columns.
§9-3 Matrix Operations. Matrix Notation The matrix has 2 rows and 3 columns.
Algorithms for Supercomputers Upper bounds: from sequential to parallel Oded Schwartz Seminar: Sunday, 12-2pm, B410 Workshop: Sunday, 2-5pm High performance.
POLYNOMIALS – Monomial Times a Polynomial
Introduction to Algorithms: Divide-n-Conquer Algorithms
12-1 Organizing Data Using Matrices
Chapter 4: Divide and Conquer
Knowing your math operation terms
Partial Products Algorithm for Multiplication
CSCE350 Algorithms and Data Structure
Exponent Rules
Matrix arithmetic: addition, subtraction and scalar multiplication
WarmUp 2-3 on your calculator or on paper..
Adaptive Strassen and ATLAS’s DGEMM
Worksheet Key 12/1/2018 8:08 PM Multiply Matrices.
[ ] [ ] [ ] [ ] EXAMPLE 3 Scalar multiplication Simplify the product:
Solving Linear Systems Using Inverse Matrices
Richard Anderson Lecture 13 Recurrences and Divide and Conquer
Ch 4: Recurrences Ming-Te Chi
Numerical Algorithms Quiz questions
Richard Anderson Lecture 12 Recurrences and Divide and Conquer
Richard Anderson Lecture 13 Recurrences, Part 2
Section 11.4 Matrix Algebra
Fast Sparse Matrix Multiplication
Designing Algorithms for Multiplication of Fractions
CSCI 256 Data Structures and Algorithm Analysis Lecture 12
Least common multiple of three numbers
1.11 Use Inverse Matrices to Solve Linear Systems
What is the dimension of the matrix below?
Richard Anderson Lecture 13, Winter 2019 Recurrences, Part 2
Matrix Multiplication
Use of Submatrices If the original matrix is n x n, the four submatrices are n/2 x n/2 each; for simplicity we assume powers of two To find the result.
Presentation transcript:

1 Complete this to a Pfaffian orientation (all internal faces have an odd number of clockwise arcs).

2

3

4

5

6

7

8 Announcements: The deadline for the slides for the research proposal has been extended to Thursday Nov. 1.

9 Strassen’s Algorithm for Matrix Multiplication c 11 c 12 c 21 c 22 a 11 a 12 a 21 a 22 b 11 b 12 b 21 b 22 =*

10 d 1 = (a 11 +a 22 ) * (b 11 +b 22 ) d 2 = (a 12 -a 22 ) * (b 21 +b 22 ) d 3 = (a 11 -a 21 ) * (b 11 +b 12 ) d 4 = (a 11 +a 12 ) * (b 22 ) d 5 = (a 21 +a 22 ) * (b 11 ) d 6 =(a 11 ) * (b 12 -b 22 ) d 7 =(a 22 ) *(-b 11 +b 21 ) C 11 = d 1 + d 2 –d 4 + d 7 C 12 = d 4 + d 6 C 21 = d 5 + d 7 C 22 = d 1 - d 3 –d 5 + d 6

11 d 1 = (a 11 +a 22 ) * (b 11 +b 22 ) d 2 = (a 12 -a 22 ) * (b 21 +b 22 ) d 3 = (a 11 -a 21 ) * (b 11 +b 12 ) d 4 = (a 11 +a 12 ) * (b 22 ) d 5 = (a 21 +a 22 ) * (b 11 ) d 6 =(a 11 ) * (b 12 -b 22 ) d 7 =(a 22 ) *(-b 11 +b 21 ) 7 Multiplications C 11 = d 1 + d 2 –d 4 + d 7 C 12 = d 4 + d 6 C 21 = d 5 + d 7 C 22 = d 1 - d 3 –d 5 + d 6

12 d 1 = (a 11 +a 22 ) * (b 11 +b 22 ) d 2 = (a 12 -a 22 ) * (b 21 +b 22 ) d 3 = (a 11 -a 21 ) * (b 11 +b 12 ) d 4 = (a 11 +a 12 ) * (b 22 ) d 5 = (a 21 +a 22 ) * (b 11 ) d 6 =(a 11 ) * (b 12 -b 22 ) d 7 =(a 22 ) *(-b 11 +b 21 ) C 11 = d 1 + d 2 – d 4 + d 7 C 12 = d 4 + d 6 C 21 = d 5 + d 7 C 22 = d 1 - d 3 –d 5 + d 6 18 Additions or Subtractions

13 Strassen’s Algorithm for Matrix Multiplication C 11 C 12 C 21 C 22 A 11 A 12 A 21 A 22 B 11 B 12 B 21 B 22 =* T(n) = Time to multiply two n by n matrices. T(n)= 7 T(n/2) + 18(n/2) 2 Solution: T(n)= O( n k ) where k= log 2 (7).

14 Coppersmith–Winograd algorithm: named after Don Coppersmith and Shmuel Winograd, O (n ) time. Trivial algorithm: O (n 3 ) time. Strassen’s algorithm: O (n ) time. It might be possible to time improve the exponent further; however, the exponent must be at least 2 (because an matrix has n 2 values, and all of them have to be read at least once to calculate the exact result).

15 The Coppersmith–Winograd algorithm is frequently used as a building block in other algorithms to prove theoretical time bounds. However, unlike the Strassen algorithm, it is not used in practice because it only provides an advantage for matrices so large that they cannot be processed by modern hardware.