CSCI 104 Sorting Algorithms. Mark Redekopp David Kempe

Size: px
Start display at page:

Download "CSCI 104 Sorting Algorithms. Mark Redekopp David Kempe"

Transcription

1 CSCI 104 Sortng Algorthms Mark Redekopp Davd Kempe

2 Algorthm Effcency SORTING 2

3 Sortng If we have an unordered lst, sequental search becomes our only choce If we wll perform a lot of searches t may be benefcal to sort the lst, then use bnary search Many sortng algorthms of dfferng complexty (.e. faster or slower) Sortng provdes a "classcal" study of algorthm analyss because there are many mplementatons wth dfferent pros and cons Lst ndex Lst ndex Orgnal Sorted 3

4 Sortng Stablty A sort s stable f the order of equal tems n the orgnal lst s mantaned n the sorted lst Good for searchng wth multple crtera Example: Spreadsheet search Lst of students n alphabetcal order frst Then sort based on test score I'd want student's wth the same test score to appear n alphabetcal order stll As we ntroduce you to certan sort algorthms consder f they are stable or not Lst ndex Lst ndex Lst ndex 7,a 3,b 5,e 8,c 5,d Orgnal 3,b 5,e 5,d 7,a 8,c Stable Sortng 3,b 5,d 5,e 7,a 8,c Unstable Sortng 4

5 Bubble Sortng Man Idea: Fnd and move largest number to top of the lst then repeat on lst of sze n-1 Have one loop to count each pass, (a.k.a. ) to dentfy whch ndex we need to stop at Have an nner loop start at the lowest ndex and count up to the stoppng locaton fndng the maxmum as we go Lst Lst Lst Lst Lst Orgnal After Pass After Pass After Pass Lst After Pass After Pass 5 5

6 Bubble Sort Algorthm vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) Pass 1 Pass 2 Pass n no no

7 Bubble Sort Value Courtesy of wkpeda.org Lst Index 7

8 Bubble Sort Analyss Best Case Complexty: When already but stll have to O( ) Worst Case Complexty: When O( ) vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) 8

9 Bubble Sort Analyss Best Case Complexty: When already sorted (no s) but stll have to do all compares O(n 2 ) Worst Case Complexty: When sorted n descendng order O(n 2 ) vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) 9

10 Loop Invarants Loop nvarant s a statement about what s true ether before an teraton begns or after one ends Consder bubble sort and look at the data after each teraton (pass) What can we say about the patterns of data after the k-th teraton? vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) Pass no Pass no

11 Loop Invarants What s true after the k-th teraton? All data at ndces n-k and above, n k: All data at ndces below n-k are, < n k: vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) Pass Pass no no

12 Loop Invarants What s true after the k-th teraton? All data at ndces n-k and above are sorted, n k: a < a + 1 All data at ndces below n- k are less than the value at n-k, < n k: a < a n k vod bsort(vector<nt> mylst) { nt ; for(=mylst.sze()-1; > 0; --){ for(=0; < ; ++){ f(mylst[] > mylst[+1]) { (, +1) Pass Pass no no

13 Selecton Sort Selecton sort does away wth the many s and ust records where the mn or max value s and performs one at the end The lst/array can agan be thought of n two parts Sorted Unsorted The problem starts wth the whole array unsorted and slowly the sorted porton grows 13

14 Selecton Sort Algorthm vod ssort(vector<nt> mylst) { for(=0; < mylst.sze()-1; ++){ nt mn = ; for(=+1; < mylst.sze; ++){ f(mylst[] < mylst[mn]) { mn = (mylst[], mylst[mn]) Pass 1 Pass 2 Pass n-2 mn=0 mn=1 mn=4 mn= mn= mn=4 mn=1 mn=1 mn=1 mn= mn= mn= mn=

15 Selecton Sort Value Courtesy of wkpeda.org Lst Index 15

16 Best Case Complexty: O( ) Worst Case Complexty: O( ) Selecton Sort Analyss vod ssort(vector<nt> mylst) { for(=0; < mylst.sze()-1; ++){ nt mn = ; for(=+1; < mylst.sze; ++){ f(mylst[] < mylst[mn]) { mn = (mylst[], mylst[mn]) 16

17 Best Case Complexty: Sorted already O(n 2 ) Worst Case Complexty: When sorted n descendng order O(n 2 ) Selecton Sort Analyss vod ssort(vector<nt> mylst) { for(=0; < mylst.sze()-1; ++){ nt mn = ; for(=+1; < mylst.sze; ++){ f(mylst[] < mylst[mn]) { mn = (mylst[], mylst[mn]) 17

18 Loop Invarant What s true after the k-th teraton? All data at ndces less than k are, < k: All data at ndces k and above are, k: vod ssort(vector<nt> mylst) { for(=0; < mylst.sze()-1; ++){ nt mn = ; for(=+1; < mylst.sze; ++){ f(mylst[] < mylst[mn]) { mn = (mylst[], mylst[mn]) Pass 1 mn=0 mn=1 Pass 2 mn= mn= mn=1 mn=1 mn= mn=1 mn= mn=1 mn=

19 Loop Invarant What s true after the k-th teraton? All data at ndces less than k are sorted, < k: a < a + 1 All data at ndces k and above are greater than the value at k, k: a k < a vod ssort(vector<nt> mylst) { for(=0; < mylst.sze()-1; ++){ nt mn = ; for(=+1; < mylst.sze; ++){ f(mylst[] < mylst[mn]) { mn = (mylst[], mylst[mn]) Pass 1 mn=0 mn=1 Pass 2 mn= mn= mn=1 mn=1 mn= mn=1 mn= mn=1 mn=

20 Inserton Sort Algorthm Imagne we pck up one element of the array at a tme and then ust nsert t nto the rght poston Smlar to how you sort a hand of cards n a card game You pck up the frst (t s by nature sorted) You pck up the second and nsert t at the rght poston, etc. Start 1 st Card 2 nd Card 3 rd Card 4 th Card 5 th Card????? 7???? 7 3??? 3 7 8?? ? ??? 3 7 8?? ?

21 Inserton Sort Algorthm vod sort(vector<nt> mylst) { for(nt =1; < mylst.sze()-1; ++){ nt val = mylst[]; hole = whle(hole > 0 && val < mylst[hole-1]){ mylst[hole] = mylst[hole-1]; hole--; mylst[hole] = val; Pass 1 Pass 2 Pass 3 Pass 4 h val= h val= h val= h val= h h h h h h h h h 21

22 Inserton Sort Value Courtesy of wkpeda.org Lst Index 22

23 Best Case Complexty: Sorted already Worst Case Complexty: When sorted n descendng order Inserton Sort Analyss vod sort(vector<nt> mylst) { for(nt =1; < mylst.sze()-1; ++){ nt val = mylst[]; hole = whle(hole > 0 && val < mylst[hole-1]){ mylst[hole] = mylst[hole-1]; hole--; mylst[hole] = val; 23

24 Inserton Sort Analyss Best Case Complexty: Sorted already O(n) Worst Case Complexty: When sorted n descendng order O(n 2 ) Consder nserton sort on an array or lnk-based lst mplementaton, what are the pros and cons Same pros and cons of runnng nsert() on an array-based or lnkbased lst vod sort(vector<nt> mylst) { for(nt =1; < mylst.sze()-1; ++){ nt val = mylst[]; hole = whle(hole > 0 && val < mylst[hole-1]){ mylst[hole] = mylst[hole-1]; hole--; mylst[hole] = val; 24

25 Loop Invarant What s true after the k-th teraton? All data at ndces less than, Can we make a clam about data at k+1 and beyond? vod sort(vector<nt> mylst) { for(nt =1; < mylst.sze()-1; ++){ nt val = mylst[]; hole = whle(hole > 0 && val < mylst[hole-1]){ mylst[hole] = mylst[hole-1]; hole--; mylst[hole] = val; h Pass h Pass 2 val= h val= h 25

26 Loop Invarant What s true after the k-th teraton? All data at ndces less than k+1 are sorted, < k + 1: a < a + 1 Can we make a clam about data at k+1 and beyond? No, t's not guaranteed to be smaller or larger than what s n the sorted lst vod sort(vector<nt> mylst) { for(nt =1; < mylst.sze()-1; ++){ nt val = mylst[]; hole = whle(hole > 0 && val < mylst[hole-1]){ mylst[hole] = mylst[hole-1]; hole--; mylst[hole] = val; h Pass h h Pass 2 val= h val=8 26

27 MERGESORT 27

28 Merge Two Sorted Lsts Consder the problem of mergng two sorted lsts nto a new combned sorted lst Can be done n O(n) Can we merge n place or need an output array? Inputs Lsts Merged Result r1 r2 r1 r2 r1 r2 r1 r2 r1 r w w w w w

29 Recursve Sort (MergeSort) Break sortng problem nto smaller sortng problems and merge the results at the end Mergesort(0..n) If lst s sze 1, return Else Mergesort(0..n/2-1) Mergesort(n/2.. n) Combne each sorted lst of n/2 elements nto a sorted n- element lst Mergesort(0,2) Mergesort(2,4) Mergesort(4,6) Mergesort(6,8) Mergesort(0,8) Mergesort(0,4) Mergesort(4,8)

30 Recursve Sort (MergeSort) Run-tme analyss # of recurson levels = Log 2 (n) Total operatons to merge each level = n operatons total to merge two lsts over all recursve calls at a partcular level Mergesort = O(n * log 2 (n) ) Mergesort(0,2) Mergesort(2,4) Mergesort(4,6) Mergesort(6,8) Usually has hgh constant factors due to extra array needed for merge Mergesort(0,8) Mergesort(0,4) Mergesort(4,8)

31 MergeSort Run Tme Let's prove ths more formally: T(1) = Θ(1) T(n) = 31

32 MergeSort Run Tme Let's prove ths more formally: T(1) = Θ(1) T(n) = 2*T(n/2) + Θ(n) k=1 T(n) = 2*T(n/2) + Θ(n) T(n/2) = 2*T(n/4) + Θ(n/2) k=2 k=3 = 2*2*T(n/4) + 2*Θ(n) = 8*T(n/8) + 3*Θ(n) = 2 k *T(n/2 k ) + k*θ(n) T(1) [.e. n = 2 k ] k=log 2 n = 2 k *T(n/2 k ) + k*θ(n) = 2 log2(n) *Θ(1) + log 2 *Θ(n) = n+log 2 *Θ(n) = Θ(n*log 2 n) 32

33 Merge Sort Value Courtesy of wkpeda.org Lst Index 33

34 Recursve Sort (MergeSort) vod mergesort(vector<nt>& mylst) { msort(mylst, 0, mylst.sze() ); vod msort(vector<nt>& mylst, nt start, nt end) { // base case f(start >= end) return; // recursve calls nt md = (start+end)/2; msort(mylst, start, md); msort(mylst, md, end); // merge merge(mylst, start, md, md, end); vod merge(vector<nt>& mylst, nt s1, nt e1, nt s2, nt e2) {... 34

35 Dvde & Conquer Strategy Mergesort s a good example of a strategy known as "dvde and conquer" 3 Steps: Dvde Splt problem nto smaller versons (usually partton the data somehow) Recurse Solve each of the smaller problems Combne Put solutons of smaller problems together to form larger soluton Another example of Dvde and Conquer? Bnary Search 35

36 QUICKSORT 36

37 Partton & QuckSort Partton algorthm (arbtrarly) pcks one number as the 'pvot' and puts t nto the 'correct' locaton left rght rght left unsorted numbers p < pvot p > pvot nt partton(vector<nt> mylst, nt start, nt end, nt p) { nt pvot = mylst[p]; (mylst[p], mylst[end]); // move pvot out of the //way for now nt left = start; nt rght = end-1; whle(left < rght){ whle(mylst[left] <= pvot && left < rght) left++; whle(mylst[rght] >= pvot && left < rght) rght--; f(left < rght) (mylst[left], mylst[rght]); (mylst[rght], mylst[end]); // put pvot back return rght; Partton(mylst,0,6,5) l r,p l r p l r p l,r p l,r p 37

38 Partton & QuckSort Partton algorthm (arbtrarly) pcks one number as the 'pvot' and puts t nto the 'correct' locaton left rght rght left unsorted numbers p < pvot p > pvot nt partton(vector<nt> mylst, nt start, nt end, nt p) { nt pvot = mylst[p]; (mylst[p], mylst[end]); // move pvot out of the //way for now nt left = start; nt rght = end-1; whle(left < rght){ whle(mylst[left] <= pvot && left < rght) left++; whle(mylst[rght] >= pvot && left < rght) rght--; f(left < rght) (mylst[left], mylst[rght]); (mylst[rght], mylst[end]); // put pvot back return rght; Partton(mylst,0,5,5) l p,r l r p l r p l,r p l,r p 38

39 QuckSort Use the partton algorthm as the bass of a sort algorthm Partton on some number and the recursvely call on both sdes < pvot p > pvot vod qsort(vector<nt>& mylst, nt start, nt end) { // base case f(start >= end) return; l p,r // pck a random pvot locaton [0..sze-1] nt p = rand() % (end); // partton nt loc = partton(mylst,start,end,p) // recurse on both sdes qsort(mylst,start,loc); qsort(mylst,loc+1,end); l r p l r p l,r p l,r p 39

40 Quck Sort Value Courtesy of wkpeda.org Lst Index 40

41 QuckSort Analyss Worst Case Complexty: When pvot chosen ends up beng Runtme: Best Case Complexty: Pvot pont chosen ends up beng the Runtme: 41

42 QuckSort Analyss Worst Case Complexty: When pvot chosen ends up beng mn or max tem Runtme: T(n) = T(n-1) + T(1) + Θ(n) Best Case Complexty: Pvot pont chosen ends up beng the medan tem Runtme: Smlar to MergeSort T(n) = 2T(n/2) + Θ(n) 42

43 QuckSort Analyss Average Case Complexty: O(n*log(n)) choose a pvot

44 QuckSort Analyss Worst Case Complexty: When pvot chosen ends up beng max or mn of each lst O(n 2 ) Best Case Complexty: Pvot pont chosen ends up beng the mddle tem O(n*lg(n)) Average Case Complexty: O(n*log(n)) Randomly choose a pvot Pvot and qucksort can be slower on small lsts than somethng lke nserton sort Many qucksort algorthms use pvot and qucksort recursvely untl lsts reach a certan sze and then use nserton sort on the small peces 44

45 Comparson Sorts Bg O of comparson sorts It s mathematcally provable that comparson-based sorts can never perform better than O(n*log(n)) So can we ever have a sortng algorthm that performs better than O(n*log(n))? Yes, but only f we can make some meanngful assumptons about the nput 45

46 OTHER SORTS 46

47 Sortng n Lnear Tme Radx Sort Sort numbers one dgt at a tme startng wth the least sgnfcant dgt to the most. Bucket Sort Assume the nput s generated by a random process that dstrbutes elements unformly over the nterval [0, 1) Countng Sort Assume the nput conssts of an array of sze N wth ntegers n a small range from 0 to k. 47

48 Other Resources rthms/muscal_sortng_algorthms.html Awesome muscal accompanment: 48

Today s Outline. Sorting: The Big Picture. Why Sort? Selection Sort: Idea. Insertion Sort: Idea. Sorting Chapter 7 in Weiss.

Today s Outline. Sorting: The Big Picture. Why Sort? Selection Sort: Idea. Insertion Sort: Idea. Sorting Chapter 7 in Weiss. Today s Outlne Sortng Chapter 7 n Wess CSE 26 Data Structures Ruth Anderson Announcements Wrtten Homework #6 due Frday 2/26 at the begnnng of lecture Proect Code due Mon March 1 by 11pm Today s Topcs:

More information

Sorting. Sorted Original. index. index

Sorting. Sorted Original. index. index 1 Unt 16 Sortng 2 Sortng Sortng requres us to move data around wthn an array Allows users to see and organze data more effcently Behnd the scenes t allows more effectve searchng of data There are MANY

More information

Insertion Sort. Divide and Conquer Sorting. Divide and Conquer. Mergesort. Mergesort Example. Auxiliary Array

Insertion Sort. Divide and Conquer Sorting. Divide and Conquer. Mergesort. Mergesort Example. Auxiliary Array Inserton Sort Dvde and Conquer Sortng CSE 6 Data Structures Lecture 18 What f frst k elements of array are already sorted? 4, 7, 1, 5, 1, 16 We can shft the tal of the sorted elements lst down and then

More information

Sorting: The Big Picture. The steps of QuickSort. QuickSort Example. QuickSort Example. QuickSort Example. Recursive Quicksort

Sorting: The Big Picture. The steps of QuickSort. QuickSort Example. QuickSort Example. QuickSort Example. Recursive Quicksort Sortng: The Bg Pcture Gven n comparable elements n an array, sort them n an ncreasng (or decreasng) order. Smple algorthms: O(n ) Inserton sort Selecton sort Bubble sort Shell sort Fancer algorthms: O(n

More information

Sorting Review. Sorting. Comparison Sorting. CSE 680 Prof. Roger Crawfis. Assumptions

Sorting Review. Sorting. Comparison Sorting. CSE 680 Prof. Roger Crawfis. Assumptions Sortng Revew Introducton to Algorthms Qucksort CSE 680 Prof. Roger Crawfs Inserton Sort T(n) = Θ(n 2 ) In-place Merge Sort T(n) = Θ(n lg(n)) Not n-place Selecton Sort (from homework) T(n) = Θ(n 2 ) In-place

More information

CSE 326: Data Structures Quicksort Comparison Sorting Bound

CSE 326: Data Structures Quicksort Comparison Sorting Bound CSE 326: Data Structures Qucksort Comparson Sortng Bound Steve Setz Wnter 2009 Qucksort Qucksort uses a dvde and conquer strategy, but does not requre the O(N) extra space that MergeSort does. Here s the

More information

Sorting. Sorting. Why Sort? Consistent Ordering

Sorting. Sorting. Why Sort? Consistent Ordering Sortng CSE 6 Data Structures Unt 15 Readng: Sectons.1-. Bubble and Insert sort,.5 Heap sort, Secton..6 Radx sort, Secton.6 Mergesort, Secton. Qucksort, Secton.8 Lower bound Sortng Input an array A of data

More information

CSE 326: Data Structures Quicksort Comparison Sorting Bound

CSE 326: Data Structures Quicksort Comparison Sorting Bound CSE 326: Data Structures Qucksort Comparson Sortng Bound Bran Curless Sprng 2008 Announcements (5/14/08) Homework due at begnnng of class on Frday. Secton tomorrow: Graded homeworks returned More dscusson

More information

Searching & Sorting. Definitions of Search and Sort. Linear Search in C++ Linear Search. Week 11. index to the item, or -1 if not found.

Searching & Sorting. Definitions of Search and Sort. Linear Search in C++ Linear Search. Week 11. index to the item, or -1 if not found. Searchng & Sortng Wee 11 Gadds: 8, 19.6,19.8 CS 5301 Sprng 2014 Jll Seaman 1 Defntons of Search and Sort Search: fnd a gven tem n a lst, return the ndex to the tem, or -1 f not found. Sort: rearrange the

More information

More on Sorting: Quick Sort and Heap Sort

More on Sorting: Quick Sort and Heap Sort More on Sortng: Quck Sort and Heap Sort Antono Carzanga Faculty of Informatcs Unversty of Lugano October 12, 2007 c 2006 Antono Carzanga 1 Another dvde-and-conuer sortng algorthm The heap Heap sort Outlne

More information

Sequential search. Building Java Programs Chapter 13. Sequential search. Sequential search

Sequential search. Building Java Programs Chapter 13. Sequential search. Sequential search Sequental search Buldng Java Programs Chapter 13 Searchng and Sortng sequental search: Locates a target value n an array/lst by examnng each element from start to fnsh. How many elements wll t need to

More information

Sorting and Algorithm Analysis

Sorting and Algorithm Analysis Unt 7 Sortng and Algorthm Analyss Computer Scence S-111 Harvard Unversty Davd G. Sullvan, Ph.D. Sortng an Array of Integers 0 1 2 n-2 n-1 arr 15 7 36 40 12 Ground rules: sort the values n ncreasng order

More information

CS1100 Introduction to Programming

CS1100 Introduction to Programming Factoral (n) Recursve Program fact(n) = n*fact(n-) CS00 Introducton to Programmng Recurson and Sortng Madhu Mutyam Department of Computer Scence and Engneerng Indan Insttute of Technology Madras nt fact

More information

Problem Set 3 Solutions

Problem Set 3 Solutions Introducton to Algorthms October 4, 2002 Massachusetts Insttute of Technology 6046J/18410J Professors Erk Demane and Shaf Goldwasser Handout 14 Problem Set 3 Solutons (Exercses were not to be turned n,

More information

Course Introduction. Algorithm 8/31/2017. COSC 320 Advanced Data Structures and Algorithms. COSC 320 Advanced Data Structures and Algorithms

Course Introduction. Algorithm 8/31/2017. COSC 320 Advanced Data Structures and Algorithms. COSC 320 Advanced Data Structures and Algorithms Course Introducton Course Topcs Exams, abs, Proects A quc loo at a few algorthms 1 Advanced Data Structures and Algorthms Descrpton: We are gong to dscuss algorthm complexty analyss, algorthm desgn technques

More information

Quicksort. Part 1: Understanding Quicksort

Quicksort. Part 1: Understanding Quicksort Qucksort Part 1: Understandng Qucksort https://www.youtube.com/watch?v=ywwby6j5gz8 Qucksort A practcal algorthm The hdden constants are small (hdden by Bg-O) Succnct algorthm The runnng tme = O(n lg n)

More information

CS221: Algorithms and Data Structures. Priority Queues and Heaps. Alan J. Hu (Borrowing slides from Steve Wolfman)

CS221: Algorithms and Data Structures. Priority Queues and Heaps. Alan J. Hu (Borrowing slides from Steve Wolfman) CS: Algorthms and Data Structures Prorty Queues and Heaps Alan J. Hu (Borrowng sldes from Steve Wolfman) Learnng Goals After ths unt, you should be able to: Provde examples of approprate applcatons for

More information

Design and Analysis of Algorithms

Design and Analysis of Algorithms Desgn and Analyss of Algorthms Heaps and Heapsort Reference: CLRS Chapter 6 Topcs: Heaps Heapsort Prorty queue Huo Hongwe Recap and overvew The story so far... Inserton sort runnng tme of Θ(n 2 ); sorts

More information

CS240: Programming in C. Lecture 12: Polymorphic Sorting

CS240: Programming in C. Lecture 12: Polymorphic Sorting CS240: Programmng n C ecture 12: Polymorphc Sortng Sortng Gven a collecton of tems and a total order over them, sort the collecton under ths order. Total order: every tem s ordered wth respect to every

More information

Programming in Fortran 90 : 2017/2018

Programming in Fortran 90 : 2017/2018 Programmng n Fortran 90 : 2017/2018 Programmng n Fortran 90 : 2017/2018 Exercse 1 : Evaluaton of functon dependng on nput Wrte a program who evaluate the functon f (x,y) for any two user specfed values

More information

CE 221 Data Structures and Algorithms

CE 221 Data Structures and Algorithms CE 1 ata Structures and Algorthms Chapter 4: Trees BST Text: Read Wess, 4.3 Izmr Unversty of Economcs 1 The Search Tree AT Bnary Search Trees An mportant applcaton of bnary trees s n searchng. Let us assume

More information

CMPS 10 Introduction to Computer Science Lecture Notes

CMPS 10 Introduction to Computer Science Lecture Notes CPS 0 Introducton to Computer Scence Lecture Notes Chapter : Algorthm Desgn How should we present algorthms? Natural languages lke Englsh, Spansh, or French whch are rch n nterpretaton and meanng are not

More information

CHAPTER 10: ALGORITHM DESIGN TECHNIQUES

CHAPTER 10: ALGORITHM DESIGN TECHNIQUES CHAPTER 10: ALGORITHM DESIGN TECHNIQUES So far, we have been concerned wth the effcent mplementaton of algorthms. We have seen that when an algorthm s gven, the actual data structures need not be specfed.

More information

Assignment # 2. Farrukh Jabeen Algorithms 510 Assignment #2 Due Date: June 15, 2009.

Assignment # 2. Farrukh Jabeen Algorithms 510 Assignment #2 Due Date: June 15, 2009. Farrukh Jabeen Algorthms 51 Assgnment #2 Due Date: June 15, 29. Assgnment # 2 Chapter 3 Dscrete Fourer Transforms Implement the FFT for the DFT. Descrbed n sectons 3.1 and 3.2. Delverables: 1. Concse descrpton

More information

Hierarchical clustering for gene expression data analysis

Hierarchical clustering for gene expression data analysis Herarchcal clusterng for gene expresson data analyss Gorgo Valentn e-mal: valentn@ds.unm.t Clusterng of Mcroarray Data. Clusterng of gene expresson profles (rows) => dscovery of co-regulated and functonally

More information

CS 534: Computer Vision Model Fitting

CS 534: Computer Vision Model Fitting CS 534: Computer Vson Model Fttng Sprng 004 Ahmed Elgammal Dept of Computer Scence CS 534 Model Fttng - 1 Outlnes Model fttng s mportant Least-squares fttng Maxmum lkelhood estmaton MAP estmaton Robust

More information

Kent State University CS 4/ Design and Analysis of Algorithms. Dept. of Math & Computer Science LECT-16. Dynamic Programming

Kent State University CS 4/ Design and Analysis of Algorithms. Dept. of Math & Computer Science LECT-16. Dynamic Programming CS 4/560 Desgn and Analyss of Algorthms Kent State Unversty Dept. of Math & Computer Scence LECT-6 Dynamc Programmng 2 Dynamc Programmng Dynamc Programmng, lke the dvde-and-conquer method, solves problems

More information

News. Recap: While Loop Example. Reading. Recap: Do Loop Example. Recap: For Loop Example

News. Recap: While Loop Example. Reading. Recap: Do Loop Example. Recap: For Loop Example Unversty of Brtsh Columba CPSC, Intro to Computaton Jan-Apr Tamara Munzner News Assgnment correctons to ASCIIArtste.java posted defntely read WebCT bboards Arrays Lecture, Tue Feb based on sldes by Kurt

More information

An Optimal Algorithm for Prufer Codes *

An Optimal Algorithm for Prufer Codes * J. Software Engneerng & Applcatons, 2009, 2: 111-115 do:10.4236/jsea.2009.22016 Publshed Onlne July 2009 (www.scrp.org/journal/jsea) An Optmal Algorthm for Prufer Codes * Xaodong Wang 1, 2, Le Wang 3,

More information

Machine Learning: Algorithms and Applications

Machine Learning: Algorithms and Applications 14/05/1 Machne Learnng: Algorthms and Applcatons Florano Zn Free Unversty of Bozen-Bolzano Faculty of Computer Scence Academc Year 011-01 Lecture 10: 14 May 01 Unsupervsed Learnng cont Sldes courtesy of

More information

Module Management Tool in Software Development Organizations

Module Management Tool in Software Development Organizations Journal of Computer Scence (5): 8-, 7 ISSN 59-66 7 Scence Publcatons Management Tool n Software Development Organzatons Ahmad A. Al-Rababah and Mohammad A. Al-Rababah Faculty of IT, Al-Ahlyyah Amman Unversty,

More information

Priority queues and heaps Professors Clark F. Olson and Carol Zander

Priority queues and heaps Professors Clark F. Olson and Carol Zander Prorty queues and eaps Professors Clark F. Olson and Carol Zander Prorty queues A common abstract data type (ADT) n computer scence s te prorty queue. As you mgt expect from te name, eac tem n te prorty

More information

Parallelism for Nested Loops with Non-uniform and Flow Dependences

Parallelism for Nested Loops with Non-uniform and Flow Dependences Parallelsm for Nested Loops wth Non-unform and Flow Dependences Sam-Jn Jeong Dept. of Informaton & Communcaton Engneerng, Cheonan Unversty, 5, Anseo-dong, Cheonan, Chungnam, 330-80, Korea. seong@cheonan.ac.kr

More information

Exercises (Part 4) Introduction to R UCLA/CCPR. John Fox, February 2005

Exercises (Part 4) Introduction to R UCLA/CCPR. John Fox, February 2005 Exercses (Part 4) Introducton to R UCLA/CCPR John Fox, February 2005 1. A challengng problem: Iterated weghted least squares (IWLS) s a standard method of fttng generalzed lnear models to data. As descrbed

More information

Smoothing Spline ANOVA for variable screening

Smoothing Spline ANOVA for variable screening Smoothng Splne ANOVA for varable screenng a useful tool for metamodels tranng and mult-objectve optmzaton L. Rcco, E. Rgon, A. Turco Outlne RSM Introducton Possble couplng Test case MOO MOO wth Game Theory

More information

Machine Learning. Topic 6: Clustering

Machine Learning. Topic 6: Clustering Machne Learnng Topc 6: lusterng lusterng Groupng data nto (hopefully useful) sets. Thngs on the left Thngs on the rght Applcatons of lusterng Hypothess Generaton lusters mght suggest natural groups. Hypothess

More information

Loop Permutation. Loop Transformations for Parallelism & Locality. Legality of Loop Interchange. Loop Interchange (cont)

Loop Permutation. Loop Transformations for Parallelism & Locality. Legality of Loop Interchange. Loop Interchange (cont) Loop Transformatons for Parallelsm & Localty Prevously Data dependences and loops Loop transformatons Parallelzaton Loop nterchange Today Loop nterchange Loop transformatons and transformaton frameworks

More information

High level vs Low Level. What is a Computer Program? What does gcc do for you? Program = Instructions + Data. Basic Computer Organization

High level vs Low Level. What is a Computer Program? What does gcc do for you? Program = Instructions + Data. Basic Computer Organization What s a Computer Program? Descrpton of algorthms and data structures to acheve a specfc ojectve Could e done n any language, even a natural language lke Englsh Programmng language: A Standard notaton

More information

The Greedy Method. Outline and Reading. Change Money Problem. Greedy Algorithms. Applications of the Greedy Strategy. The Greedy Method Technique

The Greedy Method. Outline and Reading. Change Money Problem. Greedy Algorithms. Applications of the Greedy Strategy. The Greedy Method Technique //00 :0 AM Outlne and Readng The Greedy Method The Greedy Method Technque (secton.) Fractonal Knapsack Problem (secton..) Task Schedulng (secton..) Mnmum Spannng Trees (secton.) Change Money Problem Greedy

More information

Dynamic Programming. Example - multi-stage graph. sink. source. Data Structures &Algorithms II

Dynamic Programming. Example - multi-stage graph. sink. source. Data Structures &Algorithms II Dynamc Programmng Example - mult-stage graph 1 source 9 7 3 2 2 3 4 5 7 11 4 11 8 2 2 1 6 7 8 4 6 3 5 6 5 9 10 11 2 4 5 12 snk Data Structures &Algorthms II A labeled, drected graph Vertces can be parttoned

More information

Intro. Iterators. 1. Access

Intro. Iterators. 1. Access Intro Ths mornng I d lke to talk a lttle bt about s and s. We wll start out wth smlartes and dfferences, then we wll see how to draw them n envronment dagrams, and we wll fnsh wth some examples. Happy

More information

The AVL Balance Condition. CSE 326: Data Structures. AVL Trees. The AVL Tree Data Structure. Is this an AVL Tree? Height of an AVL Tree

The AVL Balance Condition. CSE 326: Data Structures. AVL Trees. The AVL Tree Data Structure. Is this an AVL Tree? Height of an AVL Tree CSE : Data Structures AL Trees Neva Cernavsy Summer Te AL Balance Condton AL balance property: Left and rgt subtrees of every node ave egts dfferng by at most Ensures small dept ll prove ts by sowng tat

More information

Life Tables (Times) Summary. Sample StatFolio: lifetable times.sgp

Life Tables (Times) Summary. Sample StatFolio: lifetable times.sgp Lfe Tables (Tmes) Summary... 1 Data Input... 2 Analyss Summary... 3 Survval Functon... 5 Log Survval Functon... 6 Cumulatve Hazard Functon... 7 Percentles... 7 Group Comparsons... 8 Summary The Lfe Tables

More information

Loop Transformations for Parallelism & Locality. Review. Scalar Expansion. Scalar Expansion: Motivation

Loop Transformations for Parallelism & Locality. Review. Scalar Expansion. Scalar Expansion: Motivation Loop Transformatons for Parallelsm & Localty Last week Data dependences and loops Loop transformatons Parallelzaton Loop nterchange Today Scalar expanson for removng false dependences Loop nterchange Loop

More information

Brave New World Pseudocode Reference

Brave New World Pseudocode Reference Brave New World Pseudocode Reference Pseudocode s a way to descrbe how to accomplsh tasks usng basc steps lke those a computer mght perform. In ths week s lab, you'll see how a form of pseudocode can be

More information

Parallel Numerics. 1 Preconditioning & Iterative Solvers (From 2016)

Parallel Numerics. 1 Preconditioning & Iterative Solvers (From 2016) Technsche Unverstät München WSe 6/7 Insttut für Informatk Prof. Dr. Thomas Huckle Dpl.-Math. Benjamn Uekermann Parallel Numercs Exercse : Prevous Exam Questons Precondtonng & Iteratve Solvers (From 6)

More information

Distributed Splay Suffix Arrays:A New Structure for Distributed String Search

Distributed Splay Suffix Arrays:A New Structure for Distributed String Search World Academy of Scence, Engneerng and Technology Internatonal Journal of Computer and Informaton Engneerng Vol:, No:0, 2007 Dstrbuted Splay Suffx Arrays:A New Structure for Dstrbuted Strng Search Tu Kun,

More information

Complex Numbers. Now we also saw that if a and b were both positive then ab = a b. For a second let s forget that restriction and do the following.

Complex Numbers. Now we also saw that if a and b were both positive then ab = a b. For a second let s forget that restriction and do the following. Complex Numbers The last topc n ths secton s not really related to most of what we ve done n ths chapter, although t s somewhat related to the radcals secton as we wll see. We also won t need the materal

More information

A Deflected Grid-based Algorithm for Clustering Analysis

A Deflected Grid-based Algorithm for Clustering Analysis A Deflected Grd-based Algorthm for Clusterng Analyss NANCY P. LIN, CHUNG-I CHANG, HAO-EN CHUEH, HUNG-JEN CHEN, WEI-HUA HAO Department of Computer Scence and Informaton Engneerng Tamkang Unversty 5 Yng-chuan

More information

Support Vector Machines. CS534 - Machine Learning

Support Vector Machines. CS534 - Machine Learning Support Vector Machnes CS534 - Machne Learnng Perceptron Revsted: Lnear Separators Bnar classfcaton can be veed as the task of separatng classes n feature space: b > 0 b 0 b < 0 f() sgn( b) Lnear Separators

More information

R s s f. m y s. SPH3UW Unit 7.3 Spherical Concave Mirrors Page 1 of 12. Notes

R s s f. m y s. SPH3UW Unit 7.3 Spherical Concave Mirrors Page 1 of 12. Notes SPH3UW Unt 7.3 Sphercal Concave Mrrors Page 1 of 1 Notes Physcs Tool box Concave Mrror If the reflectng surface takes place on the nner surface of the sphercal shape so that the centre of the mrror bulges

More information

A New Exact Algorithm for Traveling Salesman Problem with Time Complexity Interval (O(n^4), O(n^3 2^n))

A New Exact Algorithm for Traveling Salesman Problem with Time Complexity Interval (O(n^4), O(n^3 2^n)) A New Exact Algorthm for Travelng Salesman roblem wth Tme Complexty Interval (O(n^4), O(n^3 2^n)) 39 YUNENG LI, Southeast Unversty Travelng salesman problem s a N-hard problem. Untl now, researchers have

More information

ELEC 377 Operating Systems. Week 6 Class 3

ELEC 377 Operating Systems. Week 6 Class 3 ELEC 377 Operatng Systems Week 6 Class 3 Last Class Memory Management Memory Pagng Pagng Structure ELEC 377 Operatng Systems Today Pagng Szes Vrtual Memory Concept Demand Pagng ELEC 377 Operatng Systems

More information

Mathematics 256 a course in differential equations for engineering students

Mathematics 256 a course in differential equations for engineering students Mathematcs 56 a course n dfferental equatons for engneerng students Chapter 5. More effcent methods of numercal soluton Euler s method s qute neffcent. Because the error s essentally proportonal to the

More information

AMath 483/583 Lecture 21 May 13, Notes: Notes: Jacobi iteration. Notes: Jacobi with OpenMP coarse grain

AMath 483/583 Lecture 21 May 13, Notes: Notes: Jacobi iteration. Notes: Jacobi with OpenMP coarse grain AMath 483/583 Lecture 21 May 13, 2011 Today: OpenMP and MPI versons of Jacob teraton Gauss-Sedel and SOR teratve methods Next week: More MPI Debuggng and totalvew GPU computng Read: Class notes and references

More information

A mathematical programming approach to the analysis, design and scheduling of offshore oilfields

A mathematical programming approach to the analysis, design and scheduling of offshore oilfields 17 th European Symposum on Computer Aded Process Engneerng ESCAPE17 V. Plesu and P.S. Agach (Edtors) 2007 Elsever B.V. All rghts reserved. 1 A mathematcal programmng approach to the analyss, desgn and

More information

1 Dynamic Connectivity

1 Dynamic Connectivity 15-850: Advanced Algorthms CMU, Sprng 2017 Lecture #3: Dynamc Graph Connectvty algorthms 01/30/17 Lecturer: Anupam Gupta Scrbe: Hu Han Chn, Jacob Imola Dynamc graph algorthms s the study of standard graph

More information

Introduction to Programming. Lecture 13: Container data structures. Container data structures. Topics for this lecture. A basic issue with containers

Introduction to Programming. Lecture 13: Container data structures. Container data structures. Topics for this lecture. A basic issue with containers 1 2 Introducton to Programmng Bertrand Meyer Lecture 13: Contaner data structures Last revsed 1 December 2003 Topcs for ths lecture 3 Contaner data structures 4 Contaners and genercty Contan other objects

More information

Efficient Multidimensional Searching Routines for Music Information Retrieval

Efficient Multidimensional Searching Routines for Music Information Retrieval Effcent Multdmensonal Searchng Routnes for Musc Informaton Retreval Josh Ress Jean-Julen ucouturer Mark Sandler Department of Electrcal Engneerng Kng s College London Strand. London WC2 2LR UK Phone: +44

More information

Greedy Technique - Definition

Greedy Technique - Definition Greedy Technque Greedy Technque - Defnton The greedy method s a general algorthm desgn paradgm, bult on the follong elements: confguratons: dfferent choces, collectons, or values to fnd objectve functon:

More information

Unsupervised Learning and Clustering

Unsupervised Learning and Clustering Unsupervsed Learnng and Clusterng Why consder unlabeled samples?. Collectng and labelng large set of samples s costly Gettng recorded speech s free, labelng s tme consumng 2. Classfer could be desgned

More information

Esc101 Lecture 1 st April, 2008 Generating Permutation

Esc101 Lecture 1 st April, 2008 Generating Permutation Esc101 Lecture 1 Aprl, 2008 Generatng Permutaton In ths class we wll look at a problem to wrte a program that takes as nput 1,2,...,N and prnts out all possble permutatons of the numbers 1,2,...,N. For

More information

O n processors in CRCW PRAM

O n processors in CRCW PRAM PARALLEL COMPLEXITY OF SINGLE SOURCE SHORTEST PATH ALGORITHMS Mshra, P. K. Department o Appled Mathematcs Brla Insttute o Technology, Mesra Ranch-8355 (Inda) & Dept. o Electroncs & Electrcal Communcaton

More information

Lecture 5: Multilayer Perceptrons

Lecture 5: Multilayer Perceptrons Lecture 5: Multlayer Perceptrons Roger Grosse 1 Introducton So far, we ve only talked about lnear models: lnear regresson and lnear bnary classfers. We noted that there are functons that can t be represented

More information

Virtual Memory. Background. No. 10. Virtual Memory: concept. Logical Memory Space (review) Demand Paging(1) Virtual Memory

Virtual Memory. Background. No. 10. Virtual Memory: concept. Logical Memory Space (review) Demand Paging(1) Virtual Memory Background EECS. Operatng System Fundamentals No. Vrtual Memory Prof. Hu Jang Department of Electrcal Engneerng and Computer Scence, York Unversty Memory-management methods normally requres the entre process

More information

Compiler Design. Spring Register Allocation. Sample Exercises and Solutions. Prof. Pedro C. Diniz

Compiler Design. Spring Register Allocation. Sample Exercises and Solutions. Prof. Pedro C. Diniz Compler Desgn Sprng 2014 Regster Allocaton Sample Exercses and Solutons Prof. Pedro C. Dnz USC / Informaton Scences Insttute 4676 Admralty Way, Sute 1001 Marna del Rey, Calforna 90292 pedro@s.edu Regster

More information

Clustering Algorithm of Similarity Segmentation based on Point Sorting

Clustering Algorithm of Similarity Segmentation based on Point Sorting Internatonal onference on Logstcs Engneerng, Management and omputer Scence (LEMS 2015) lusterng Algorthm of Smlarty Segmentaton based on Pont Sortng Hanbng L, Yan Wang*, Lan Huang, Mngda L, Yng Sun, Hanyuan

More information

Biostatistics 615/815

Biostatistics 615/815 The E-M Algorthm Bostatstcs 615/815 Lecture 17 Last Lecture: The Smplex Method General method for optmzaton Makes few assumptons about functon Crawls towards mnmum Some recommendatons Multple startng ponts

More information

11. APPROXIMATION ALGORITHMS

11. APPROXIMATION ALGORITHMS Copng wth NP-completeness 11. APPROXIMATION ALGORITHMS load balancng center selecton prcng method: vertex cover LP roundng: vertex cover generalzed load balancng knapsack problem Q. Suppose I need to solve

More information

CHAPTER 2 DECOMPOSITION OF GRAPHS

CHAPTER 2 DECOMPOSITION OF GRAPHS CHAPTER DECOMPOSITION OF GRAPHS. INTRODUCTION A graph H s called a Supersubdvson of a graph G f H s obtaned from G by replacng every edge uv of G by a bpartte graph,m (m may vary for each edge by dentfyng

More information

Conditional Speculative Decimal Addition*

Conditional Speculative Decimal Addition* Condtonal Speculatve Decmal Addton Alvaro Vazquez and Elsardo Antelo Dep. of Electronc and Computer Engneerng Unv. of Santago de Compostela, Span Ths work was supported n part by Xunta de Galca under grant

More information

CHARUTAR VIDYA MANDAL S SEMCOM Vallabh Vidyanagar

CHARUTAR VIDYA MANDAL S SEMCOM Vallabh Vidyanagar CHARUTAR VIDYA MANDAL S SEMCOM Vallabh Vdyanagar Faculty Name: Am D. Trved Class: SYBCA Subject: US03CBCA03 (Advanced Data & Fle Structure) *UNIT 1 (ARRAYS AND TREES) **INTRODUCTION TO ARRAYS If we want

More information

The Shortest Path of Touring Lines given in the Plane

The Shortest Path of Touring Lines given in the Plane Send Orders for Reprnts to reprnts@benthamscence.ae 262 The Open Cybernetcs & Systemcs Journal, 2015, 9, 262-267 The Shortest Path of Tourng Lnes gven n the Plane Open Access Ljuan Wang 1,2, Dandan He

More information

Support Vector Machines

Support Vector Machines /9/207 MIST.6060 Busness Intellgence and Data Mnng What are Support Vector Machnes? Support Vector Machnes Support Vector Machnes (SVMs) are supervsed learnng technques that analyze data and recognze patterns.

More information

Non-Split Restrained Dominating Set of an Interval Graph Using an Algorithm

Non-Split Restrained Dominating Set of an Interval Graph Using an Algorithm Internatonal Journal of Advancements n Research & Technology, Volume, Issue, July- ISS - on-splt Restraned Domnatng Set of an Interval Graph Usng an Algorthm ABSTRACT Dr.A.Sudhakaraah *, E. Gnana Deepka,

More information

NGPM -- A NSGA-II Program in Matlab

NGPM -- A NSGA-II Program in Matlab Verson 1.4 LIN Song Aerospace Structural Dynamcs Research Laboratory College of Astronautcs, Northwestern Polytechncal Unversty, Chna Emal: lsssswc@163.com 2011-07-26 Contents Contents... 1. Introducton...

More information

ON SOME ENTERTAINING APPLICATIONS OF THE CONCEPT OF SET IN COMPUTER SCIENCE COURSE

ON SOME ENTERTAINING APPLICATIONS OF THE CONCEPT OF SET IN COMPUTER SCIENCE COURSE Yordzhev K., Kostadnova H. Інформаційні технології в освіті ON SOME ENTERTAINING APPLICATIONS OF THE CONCEPT OF SET IN COMPUTER SCIENCE COURSE Yordzhev K., Kostadnova H. Some aspects of programmng educaton

More information

GSLM Operations Research II Fall 13/14

GSLM Operations Research II Fall 13/14 GSLM 58 Operatons Research II Fall /4 6. Separable Programmng Consder a general NLP mn f(x) s.t. g j (x) b j j =. m. Defnton 6.. The NLP s a separable program f ts objectve functon and all constrants are

More information

Efficient Distributed File System (EDFS)

Efficient Distributed File System (EDFS) Effcent Dstrbuted Fle System (EDFS) (Sem-Centralzed) Debessay(Debsh) Fesehaye, Rahul Malk & Klara Naherstedt Unversty of Illnos-Urbana Champagn Contents Problem Statement, Related Work, EDFS Desgn Rate

More information

A Binarization Algorithm specialized on Document Images and Photos

A Binarization Algorithm specialized on Document Images and Photos A Bnarzaton Algorthm specalzed on Document mages and Photos Ergna Kavalleratou Dept. of nformaton and Communcaton Systems Engneerng Unversty of the Aegean kavalleratou@aegean.gr Abstract n ths paper, a

More information

K-means and Hierarchical Clustering

K-means and Hierarchical Clustering Note to other teachers and users of these sldes. Andrew would be delghted f you found ths source materal useful n gvng your own lectures. Feel free to use these sldes verbatm, or to modfy them to ft your

More information

Cluster Analysis of Electrical Behavior

Cluster Analysis of Electrical Behavior Journal of Computer and Communcatons, 205, 3, 88-93 Publshed Onlne May 205 n ScRes. http://www.scrp.org/ournal/cc http://dx.do.org/0.4236/cc.205.350 Cluster Analyss of Electrcal Behavor Ln Lu Ln Lu, School

More information

Private Information Retrieval (PIR)

Private Information Retrieval (PIR) 2 Levente Buttyán Problem formulaton Alce wants to obtan nformaton from a database, but she does not want the database to learn whch nformaton she wanted e.g., Alce s an nvestor queryng a stock-market

More information

A MOVING MESH APPROACH FOR SIMULATION BUDGET ALLOCATION ON CONTINUOUS DOMAINS

A MOVING MESH APPROACH FOR SIMULATION BUDGET ALLOCATION ON CONTINUOUS DOMAINS Proceedngs of the Wnter Smulaton Conference M E Kuhl, N M Steger, F B Armstrong, and J A Jones, eds A MOVING MESH APPROACH FOR SIMULATION BUDGET ALLOCATION ON CONTINUOUS DOMAINS Mark W Brantley Chun-Hung

More information

Load Balancing for Hex-Cell Interconnection Network

Load Balancing for Hex-Cell Interconnection Network Int. J. Communcatons, Network and System Scences,,, - Publshed Onlne Aprl n ScRes. http://www.scrp.org/journal/jcns http://dx.do.org/./jcns.. Load Balancng for Hex-Cell Interconnecton Network Saher Manaseer,

More information

AP PHYSICS B 2008 SCORING GUIDELINES

AP PHYSICS B 2008 SCORING GUIDELINES AP PHYSICS B 2008 SCORING GUIDELINES General Notes About 2008 AP Physcs Scorng Gudelnes 1. The solutons contan the most common method of solvng the free-response questons and the allocaton of ponts for

More information

NUMERICAL SOLVING OPTIMAL CONTROL PROBLEMS BY THE METHOD OF VARIATIONS

NUMERICAL SOLVING OPTIMAL CONTROL PROBLEMS BY THE METHOD OF VARIATIONS ARPN Journal of Engneerng and Appled Scences 006-017 Asan Research Publshng Network (ARPN). All rghts reserved. NUMERICAL SOLVING OPTIMAL CONTROL PROBLEMS BY THE METHOD OF VARIATIONS Igor Grgoryev, Svetlana

More information

Music Information Retrieval Schemes in Peer-to-Peer Environments

Music Information Retrieval Schemes in Peer-to-Peer Environments Journal of Computer Scence 1 (3): 369-375, 2005 ISSN 1549-3636 Scence Publcatons, 2005 Musc Informaton Retreval Schemes n Peer-to-Peer Envronments Chaokun Wang, Janzhong L and Shengfe Sh School of Computer

More information

Simulation: Solving Dynamic Models ABE 5646 Week 11 Chapter 2, Spring 2010

Simulation: Solving Dynamic Models ABE 5646 Week 11 Chapter 2, Spring 2010 Smulaton: Solvng Dynamc Models ABE 5646 Week Chapter 2, Sprng 200 Week Descrpton Readng Materal Mar 5- Mar 9 Evaluatng [Crop] Models Comparng a model wth data - Graphcal, errors - Measures of agreement

More information

S1 Note. Basis functions.

S1 Note. Basis functions. S1 Note. Bass functons. Contents Types of bass functons...1 The Fourer bass...2 B-splne bass...3 Power and type I error rates wth dfferent numbers of bass functons...4 Table S1. Smulaton results of type

More information

Parallel matrix-vector multiplication

Parallel matrix-vector multiplication Appendx A Parallel matrx-vector multplcaton The reduced transton matrx of the three-dmensonal cage model for gel electrophoress, descrbed n secton 3.2, becomes excessvely large for polymer lengths more

More information

An Iterative Solution Approach to Process Plant Layout using Mixed Integer Optimisation

An Iterative Solution Approach to Process Plant Layout using Mixed Integer Optimisation 17 th European Symposum on Computer Aded Process Engneerng ESCAPE17 V. Plesu and P.S. Agach (Edtors) 2007 Elsever B.V. All rghts reserved. 1 An Iteratve Soluton Approach to Process Plant Layout usng Mxed

More information

c 2009 Society for Industrial and Applied Mathematics

c 2009 Society for Industrial and Applied Mathematics SIAM J. MATRIX ANAL. APPL. Vol. 31, No. 3, pp. 1382 1411 c 2009 Socety for Industral and Appled Mathematcs SUPERFAST MULTIFRONTAL METHOD FOR LARGE STRUCTURED LINEAR SYSTEMS OF EQUATIONS JIANLIN XIA, SHIVKUMAR

More information

On Some Entertaining Applications of the Concept of Set in Computer Science Course

On Some Entertaining Applications of the Concept of Set in Computer Science Course On Some Entertanng Applcatons of the Concept of Set n Computer Scence Course Krasmr Yordzhev *, Hrstna Kostadnova ** * Assocate Professor Krasmr Yordzhev, Ph.D., Faculty of Mathematcs and Natural Scences,

More information

High resolution 3D Tau-p transform by matching pursuit Weiping Cao* and Warren S. Ross, Shearwater GeoServices

High resolution 3D Tau-p transform by matching pursuit Weiping Cao* and Warren S. Ross, Shearwater GeoServices Hgh resoluton 3D Tau-p transform by matchng pursut Wepng Cao* and Warren S. Ross, Shearwater GeoServces Summary The 3D Tau-p transform s of vtal sgnfcance for processng sesmc data acqured wth modern wde

More information

The stream cipher MICKEY-128 (version 1) Algorithm specification issue 1.0

The stream cipher MICKEY-128 (version 1) Algorithm specification issue 1.0 The stream cpher MICKEY-128 (verson 1 Algorthm specfcaton ssue 1. Steve Babbage Vodafone Group R&D, Newbury, UK steve.babbage@vodafone.com Matthew Dodd Independent consultant matthew@mdodd.net www.mdodd.net

More information

Notes on Organizing Java Code: Packages, Visibility, and Scope

Notes on Organizing Java Code: Packages, Visibility, and Scope Notes on Organzng Java Code: Packages, Vsblty, and Scope CS 112 Wayne Snyder Java programmng n large measure s a process of defnng enttes (.e., packages, classes, methods, or felds) by name and then usng

More information

For instance, ; the five basic number-sets are increasingly more n A B & B A A = B (1)

For instance, ; the five basic number-sets are increasingly more n A B & B A A = B (1) Secton 1.2 Subsets and the Boolean operatons on sets If every element of the set A s an element of the set B, we say that A s a subset of B, or that A s contaned n B, or that B contans A, and we wrte A

More information

Summarizing Data using Bottom-k Sketches

Summarizing Data using Bottom-k Sketches Summarzng Data usng Bottom-k Sketches Edth Cohen AT&T Labs Research 8 Park Avenue Florham Park, NJ 7932, USA edth@research.att.com Ham Kaplan School of Computer Scence Tel Avv Unversty Tel Avv, Israel

More information

2D Raster Graphics. Integer grid Sequential (left-right, top-down) scan. Computer Graphics

2D Raster Graphics. Integer grid Sequential (left-right, top-down) scan. Computer Graphics 2D Graphcs 2D Raster Graphcs Integer grd Sequental (left-rght, top-down scan j Lne drawng A ver mportant operaton used frequentl, block dagrams, bar charts, engneerng drawng, archtecture plans, etc. curves

More information