This presentation was placed on a course project of reading course in the university of texas, san Antonio. This is a group project and the project lead was Lishu Li
Problem solving strategies in mathematics and computer science
1. Problem Solving in mathematics and computer science Team 4 Chapter 13 Reading in Mathematics Team members: Lishu Liu Yun Zhang ProsunjitBiswas Tahmina Ahmed
2. How ideas and relationships are expressed in mathematics? Ideas and relationships are expressed through notations, symbols, numbers and formulas. Symbol: =,<,>,+,-,*,/ etc. Number: 1,2,3,0.1,1/2,logn etc. Formula: ex. y = x+2
3. Thought pattern in mathematics The three patterns are: Process Problem solving Comparison and contrast
5. Problem solving in mathematics- step1 Define the problem Everyone must kiss each other. We define one kiss as occurring when two people kiss each other, any number of times. Q: How many kisses will occur if we have n people?
6. Problem solving in mathematics- step2 Try to solvethe problem for simple cases
7. Problem solving in mathematics- step3 Look for a pattern or clue n=2: 1 kiss n=1: 0 kiss 3 1 2 3 1 4 2 n=4: 3+2+1 kisses n=3: 2+1 kisses
8. Problem solving in mathematics- step3 (continuing…) n = 5, kisses = 4 + 3 + 2 + 1 n = 6, kisses = 5 + 4 + 3 + 2 +1 n= 7, kisses = 6 + 5 + 4 + 3 + 2 + 1 So, what can be the pattern for the kissing problem?
9. Problem solving in mathematics- step4 Guess and check What if we have n people? ?
10. Problem solving in mathematics- step5 Use knowledge to solve the problem and extend the solution Kisses = (n-1) + (n-2) + … + 1
11. Problem solving in mathematics- step6 Try to find a better solution Kisses = (n-1) + (n-2) + … + 1 = (n + n + … + n) – (1 + 2 + … + (n-1)) = n(n-1) – n(n-1)/2 = n(n-1)/2 (n-(n-1)) (n-1) factors (n-1) factors (n-1) factors
13. Problem solving in computer science - step1 Define the problem Everyone must kiss each other. We define one kiss as occurring when two people kiss each other, any number of times. Q: For N number of People how many kisses there will be ?
14. Problem solving in computer science - step2 Get sample input and output for simple cases Define input 1, 2, 3, 4 … | | | | Define output 0, 1, 3, 6 …
15. Problem solving in computer science - step3 Construct logic with the pattern For first two input So, We can assume that for n people n -1 kisses. n=1: 0 kiss n=2 : 1 kiss
16. Problem solving in computer science - step3 We consider more input & output to justify our guess(kiss=n-1). n=1: 0 kiss n=2: 1 kiss n=3: 2 kisses n=4: 3 kisses But this time we are indeed wrong. So, need to improve our guess.
17. Problem solving in computer science - step4 We will improve our solution through trial & error. what will happen if we cannot reach the exact solution ?
18. Problem solving in computer science – step4 So, we will construct & justify our logic using mathematical formula. Kisses = n (n-1) / 2
19. Problem solving in computer science - step5 Now we have the solution Now its time to code ! FIND NO OF KISSES( N) KISS=N(N-1)/2 RETURN KISS
20. Problem solving in computer science - step6 Problem solved! Why do we really need a computer to solve the problem?
23. Historical relation between mathematics & computer science Donald Knuth (Professor of Stanford) -- Father of Analysis of Algorithm Graduated in Mathematics (Case Institute of Tech.) PhD in Mathematics (Caltech)