Sorting Networks A Lecture in CE Freshman Seminar Series: Ten Puzzling Problems in Computer Engineering. May 2007 Sorting Networks Slide 1

Size: px
Start display at page:

Download "Sorting Networks A Lecture in CE Freshman Seminar Series: Ten Puzzling Problems in Computer Engineering. May 2007 Sorting Networks Slide 1"

Transcription

1 Sorting Networks Lecture in E Freshman Seminar Series: Ten Puzzling Problems in omputer Engineering Ma 7 Sorting Networks Slide

2 bout This Presentation This presentation belongs to the lecture series entitled Ten Puzzling Problems in omputer Engineering, devised for a ten-week, one-unit, freshman seminar course b ehrooz Parhami, Professor of omputer Engineering at Universit of alifornia, Santa arbara The material can be used freel in teaching and other educational settings Unauthorized uses, including an use for financial gain, are prohibited ehrooz Parhami Edition Released Revised Revised First Ma 7 Ma 7 Sorting Networks Slide

3 Railroad Tracks and Switches Ma 7 Sorting Networks Slide

4 Railroad Yards Have Man Tracks and Switches Ma 7 Sorting Networks Slide

5 Rearranging Trains Train cars Engine Track D Sorted order D Stub or lead D Stub or lead D Stack or LIFO data structure in E Stub or lead D Question: Is there an ordering that cannot be sorted using a stub? nswer: Yes, if engine muse do the moving Sorting algorithm D Queue or FIFO Siding Ma 7 Sorting Networks Slide

6 Rearrangement with hange of Direction D Turnaround loop D D What tpes of sorting are possible with a turnaround loop? we? We onfiguration after the first few steps in sorting the train D omplete the sorting process, assuming that it is oka for the engine to end up behind the train Ma 7 Sorting Networks Slide 6

7 Delivering Train ars in a Specific Order ars in the train below have been sorted according to their deliver points However, it is still nontrivial to deposit car in stub, car in stub, and car in siding ars can be pulled or pushed b the engine D D Is there a better initial ordering of the cars for the deliveries in this puzzle? D Ma 7 Sorting Networks Slide 7

8 Train Passing Puzzle The trains below must pass each other using a siding that can hold onl one car or one engine Show how this can be done Ma 7 Sorting Networks Slide 8

9 Fast ombining or Reordering of Train ars D Forming multiple trains from incoming cars D Train reordering via a set of stubs ars are pushed or pulled b an engine lternativel, movement in one direction ma be achieved via sloped rails Switches used to be adjusted manuall, but nowadas, electronic control is used Ma 7 Sorting Networks Slide 9

10 Target track Sorting Train ars in Parallel Unconditional echange ompare-echange Track Track Track Track Track Track Track Track The net in stick diagram schematic Is adding this compare-echange element sufficient for producing a valid sorting network? Ma 7 Sorting Networks Slide

11 a b c d Validating a Sorting Network min(a, b) min(a, b, c, d) ma(a, b)???? min(c, d)???? ma(c, d) ma(a, b, c, d) Track Track Track Track In the eample above, it was fairl eas to show the validit of the sorting network Generall, it is much more difficult Stick diagram schematic How would one establish the validit of this 6-input sorting net? More importantl, how does one come up with this design in the first place? Ma 7 Sorting Networks Slide

12 Ma 7 Sorting Networks Slide The Zero-One Principle So, we can validate a sorting network using n rather than n! input patterns sorting net built of comparators is valid if it correctl sorts all - sequences n = : n = 96, n! = 79,,6 (thousands vs half a billion)

13 Input Sorting Network Use -input sorters, follow b (, )-mergers, and end with an (8, 8)-merger Using the - principle, we can validate this network via tests sorter tests (, )-merger tests (8, 8)-merger tests Ma 7 Sorting Networks Slide

14 Ma 7 Sorting Networks Slide Insertion Sort and Selection Sort Fig 78 Sorting network based on insertion sort or selection sort (n )-sorter n n n n (n )-sorter n n n n Insertion sort Selection sort Parallel insertion sort = Parallel selection sort = Parallel bubble sort! (n) = n(n )/ D(n ) = n ost Dela = Θ(n ) Insertion sort Selection sort

15 The est Sorting Networks n = 6, modules, levels Which -input sorting network is better? n = 9, modules, 8 levels n =, 9 modules, 9 levels n =, modules, 7 levels ost = 9 Dela = 9 ost = Dela = 7 ost Dela = 9 9 = 6 ost Dela = 7 = 7 riterion : The number of sticks or compare-echange blocks (cost) riterion : The number of compare-echanges in sequence (dela) riterion : The product of cost and dela (cost-effectiveness) n =, modules, 8 levels The most cost-effective n-input sorting network ma be n = 6, 6 modules, 9 levels neither the fastest design, nor the lowest-cost design n = 6, 6 modules, levels Ma 7 Sorting Networks Slide

16 Electronic Sorting Networks Electronic sorting networks are built of -sorters, building blocks that can sort two inputs a min(a, b) b ma(a, b) pplications of sorting networks: Directing information packets to their destinations in a network router onnecting n processors to n memor modules in a parallel computer Ma 7 Sorting Networks Slide 6

CSE Introduction to Parallel Processing. Chapter 7. Sorting and Selection Networks

CSE Introduction to Parallel Processing. Chapter 7. Sorting and Selection Networks Dr Izadi CSE-4 Introduction to Parallel Processing Chapter 7 Sorting and Selection Networks Become familiar with the circuit-level models of parallel processing Introduce useful design tools and trade-off

More information

Placement and Routing A Lecture in CE Freshman Seminar Series: Puzzling Problems in Computer Engineering. Apr Placement and Routing Slide 1

Placement and Routing A Lecture in CE Freshman Seminar Series: Puzzling Problems in Computer Engineering. Apr Placement and Routing Slide 1 Placement and Routing A Lecture in CE Freshman Seminar Series: Puzzling Problems in Computer Engineering Apr. 2016 Placement and Routing Slide 1 About This Presentation This presentation belongs to the

More information

Lesson 10 Using and Sorting Lists

Lesson 10 Using and Sorting Lists Lesson What you will learn: how to create variables how to create lists how to add values to lists how to create ordered lists how to use IF ELSE how to create a list in a random order with no duplicates

More information

4.5.2 The Distance-Vector (DV) Routing Algorithm

4.5.2 The Distance-Vector (DV) Routing Algorithm 4.5 ROUTING ALGORITHMS 371 highl congested (for eample, high-dela) links. Another solution is to ensure that not all routers run the LS algorithm at the same time. This seems a more reasonable solution,

More information

Bridges. Bridge Functions. Example of No-frills Bridge. No-frills Bridges. Example of Learning Bridge. Learning Bridges

Bridges. Bridge Functions. Example of No-frills Bridge. No-frills Bridges. Example of Learning Bridge. Learning Bridges ridge Functions To extend size of LNs either geographically or in terms number of users. Protocols that include collisions can be performed in a collision domain of limited size. In ring networks the number

More information

Routing Algorithm Classification. A Link-State Routing Algorithm

Routing Algorithm Classification. A Link-State Routing Algorithm Routing Algorithm lassification Global or decentralied information? Global: All routers have complete topolog, link cost info Link state algorithms Decentralied: Router knows phsicallconnected neighbors,

More information

Discussion 8: Link State Routing. CSE 123: Computer Networks Marti Motoyama & Chris Kanich

Discussion 8: Link State Routing. CSE 123: Computer Networks Marti Motoyama & Chris Kanich iscussion 8: Link State Routing S : omputer Networks Marti Motoyama & hris Kanich Schedule Project Questions: mail hris, post to moodle, or attend his OH Homework Questions? Link State iscussion S iscussion

More information

Chapter 3 Part 1 Combinational Logic Design

Chapter 3 Part 1 Combinational Logic Design Universit of Wisconsin - Madison EE/omp Sci 352 igital Sstems undamentals Kewal K. Saluja and Yu Hen Hu Spring 22 hapter 3 Part ombinational Logic esign Originals b: harles R. Kime and Tom Kamisnski Modified

More information

12 Abstract Data Types

12 Abstract Data Types 12 Abstract Data Types 12.1 Foundations of Computer Science Cengage Learning Objectives After studying this chapter, the student should be able to: Define the concept of an abstract data type (ADT). Define

More information

CS24 Week 4 Lecture 2

CS24 Week 4 Lecture 2 CS24 Week 4 Lecture 2 Kyle Dewey Overview Linked Lists Stacks Queues Linked Lists Linked Lists Idea: have each chunk (called a node) keep track of both a list element and another chunk Need to keep track

More information

Lecture 7. Network Layer. Network Layer 1-1

Lecture 7. Network Layer. Network Layer 1-1 Lecture 7 Network Layer Network Layer 1-1 Agenda Introduction to the Network Layer Network layer functions Service models Network layer connection and connectionless services Introduction to data routing

More information

4 Using The Derivative

4 Using The Derivative 4 Using The Derivative 4.1 Local Maima and Minima * Local Maima and Minima Suppose p is a point in the domain of f : f has a local minimum at p if f (p) is less than or equal to the values of f for points

More information

checking for optimal egress point in ibgp routing

checking for optimal egress point in ibgp routing heking for optimal egress point in ibgp routing Mar Olivier Buob (CORE/CPN/NEO), Mikaël Meulle (CORE/CPN/RIV), Steve Uhlig (Delft Universit of Tehnolog) 0/0/07 agenda 2 3 introdution internet routing border

More information

Agenda. distance-vector (what you invented last Friday) hierarchical routing routing in the Internet. v DNS assignment Q&A v Routing Algorithms

Agenda. distance-vector (what you invented last Friday) hierarchical routing routing in the Internet. v DNS assignment Q&A v Routing Algorithms Agenda v DNS assignment Q&A v Routing Algorithms distance-vector (what ou invented last Frida) hierarchical routing routing in the Internet Network Laer 4- Chapter 4 Network Laer A note on the use of these

More information

Design and Performance Evaluation of a New Spatial Reuse FireWire Protocol. Master s thesis defense by Vijay Chandramohan

Design and Performance Evaluation of a New Spatial Reuse FireWire Protocol. Master s thesis defense by Vijay Chandramohan Design and Performance Evaluation of a New Spatial Reuse FireWire Protocol Master s thesis defense by Vijay Chandramohan Committee Members: Dr. Christensen (Major Professor) Dr. Labrador Dr. Ranganathan

More information

CSC 4900 Computer Networks: Network Layer

CSC 4900 Computer Networks: Network Layer CSC 4900 Computer Networks: Network Layer Professor Henry Carter Fall 2017 Villanova University Department of Computing Sciences Review What is AIMD? When do we use it? What is the steady state profile

More information

Linked Lists in C and C++

Linked Lists in C and C++ Linked Lists in C and C++ Professor Hugh C. Lauer CS-2303, System Programming Concepts (Slides include materials from The C Programming Language, 2 nd edition, by Kernighan and Ritchie, Absolute C++, by

More information

Data Structures. Outline. Introduction Linked Lists Stacks Queues Trees Deitel & Associates, Inc. All rights reserved.

Data Structures. Outline. Introduction Linked Lists Stacks Queues Trees Deitel & Associates, Inc. All rights reserved. Data Structures Outline Introduction Linked Lists Stacks Queues Trees Introduction dynamic data structures - grow and shrink during execution Linked lists - insertions and removals made anywhere Stacks

More information

Answers Investigation 4

Answers Investigation 4 Answers Investigation Applications. a. At seconds, the flare will have traveled to a maimum height of 00 ft. b. The flare will hit the water when the height is 0 ft, which will occur at 0 seconds. c. In

More information

Informed Search. CMU Snake Robot. Administrative. Uninformed search strategies. Assignment 1 was due before class how d it go?

Informed Search. CMU Snake Robot. Administrative. Uninformed search strategies. Assignment 1 was due before class how d it go? Informed Search S151 David Kauchak Fall 2010 MU Snake Robot http://www-cgi.cs.cmu.edu/afs/cs.cmu.edu/web/people/biorobotics/projects/ modsnake/index.html Some material borrowed from : Sara Owsley Sood

More information

Announcements. CSCI 334: Principles of Programming Languages. Lecture 19: C++

Announcements. CSCI 334: Principles of Programming Languages. Lecture 19: C++ Announcements CSCI 4: Principles of Programming Languages Lecture 19: C++ HW8 pro tip: the HW7 solutions have a complete, correct implementation of the CPS version of bubble sort in SML. All ou need to

More information

1.1. Parent Functions and Transformations Essential Question What are the characteristics of some of the basic parent functions?

1.1. Parent Functions and Transformations Essential Question What are the characteristics of some of the basic parent functions? 1.1 Parent Functions and Transformations Essential Question What are the characteristics of some of the basic parent functions? Identifing Basic Parent Functions JUSTIFYING CONCLUSIONS To be proficient

More information

A closer look at network structure:

A closer look at network structure: T1: Introduction 1.1 What is computer network? Examples of computer network The Internet Network structure: edge and core 1.2 Why computer networks 1.3 The way networks work 1.4 Performance metrics: Delay,

More information

CMSC 332 Computer Networks Network Layer

CMSC 332 Computer Networks Network Layer CMSC 332 Computer Networks Network Layer Professor Szajda CMSC 332: Computer Networks Where in the Stack... CMSC 332: Computer Network 2 Where in the Stack... Application CMSC 332: Computer Network 2 Where

More information

Algebra I. Linear Equations. Slide 1 / 267 Slide 2 / 267. Slide 3 / 267. Slide 3 (Answer) / 267. Slide 4 / 267. Slide 5 / 267

Algebra I. Linear Equations. Slide 1 / 267 Slide 2 / 267. Slide 3 / 267. Slide 3 (Answer) / 267. Slide 4 / 267. Slide 5 / 267 Slide / 67 Slide / 67 lgebra I Graphing Linear Equations -- www.njctl.org Slide / 67 Table of ontents Slide () / 67 Table of ontents Linear Equations lick on the topic to go to that section Linear Equations

More information

Ceng 111 Fall 2015 Week 12b

Ceng 111 Fall 2015 Week 12b Ceng 111 Fall 2015 Week 12b Complexity and ADT Credit: Some slides are from the Invitation to Computer Science book by G. M. Schneider, J. L. Gersting and some from the Digital Design book by M. M. Mano

More information

Data Struct. & Prob. Solving, M.C.Q. BANK, FOR UNIT 3, SECOND YEAR COMP. ENGG. SEM 1, 2012 PATTERN, U.O.P.

Data Struct. & Prob. Solving, M.C.Q. BANK, FOR UNIT 3, SECOND YEAR COMP. ENGG. SEM 1, 2012 PATTERN, U.O.P. UNIT distribution for +1+1 + 1 + + = 11 (Only 1 will be asked for marks, s will be asked for 1 & s asked for marks ) Syllabus for Graphs Programmers perspective of graphs, Graph operations, storage structure,

More information

CSE328 Fundamentals of Computer Graphics: Theory, Algorithms, and Applications

CSE328 Fundamentals of Computer Graphics: Theory, Algorithms, and Applications CSE328 Fundamentals of Computer Graphics: Theor, Algorithms, and Applications Hong in State Universit of New York at Ston Brook (Ston Brook Universit) Ston Brook, New York 794-44 Tel: (63)632-845; Fa:

More information

CS510 \ Lecture Ariel Stolerman

CS510 \ Lecture Ariel Stolerman CS510 \ Lecture02 2012-10-03 1 Ariel Stolerman Midterm Evan will email about that after the lecture, at least 2 lectures from now. The exam will be given in a regular PDF (not an online form). We will

More information

Pre-Algebra Notes Unit 8: Graphs and Functions

Pre-Algebra Notes Unit 8: Graphs and Functions Pre-Algebra Notes Unit 8: Graphs and Functions The Coordinate Plane A coordinate plane is formed b the intersection of a horizontal number line called the -ais and a vertical number line called the -ais.

More information

Network Superhighway CSCD 330. Network Programming Winter Lecture 13 Network Layer. Reading: Chapter 4

Network Superhighway CSCD 330. Network Programming Winter Lecture 13 Network Layer. Reading: Chapter 4 CSCD 330 Network Superhighway Network Programming Winter 2015 Lecture 13 Network Layer Reading: Chapter 4 Some slides provided courtesy of J.F Kurose and K.W. Ross, All Rights Reserved, copyright 1996-2007

More information

CS 43: Computer Networks. 20: The Network Layer November 5, 2018

CS 43: Computer Networks. 20: The Network Layer November 5, 2018 CS 43: Computer Networks 20: The Network Layer November 5, 2018 Last Class: TCP Rate and Flow Control TCP has mechanisms to control sending rate: Flow control: don t overload receiver Congestion control:

More information

Graphs and Functions

Graphs and Functions CHAPTER Graphs and Functions. Graphing Equations. Introduction to Functions. Graphing Linear Functions. The Slope of a Line. Equations of Lines Integrated Review Linear Equations in Two Variables.6 Graphing

More information

Planning and search. Lecture 1: Introduction and Revision of Search. Lecture 1: Introduction and Revision of Search 1

Planning and search. Lecture 1: Introduction and Revision of Search. Lecture 1: Introduction and Revision of Search 1 Planning and search Lecture 1: Introduction and Revision of Search Lecture 1: Introduction and Revision of Search 1 Lecturer: Natasha lechina email: nza@cs.nott.ac.uk ontact and web page web page: http://www.cs.nott.ac.uk/

More information

Non-linear models. Basis expansion. Overfitting. Regularization.

Non-linear models. Basis expansion. Overfitting. Regularization. Non-linear models. Basis epansion. Overfitting. Regularization. Petr Pošík Czech Technical Universit in Prague Facult of Electrical Engineering Dept. of Cbernetics Non-linear models Basis epansion.....................................................................................................

More information

CSE 3214: Computer Network Protocols and Applications Network Layer

CSE 3214: Computer Network Protocols and Applications Network Layer CSE 314: Computer Network Protocols and Applications Network Layer Dr. Peter Lian, Professor Department of Computer Science and Engineering York University Email: peterlian@cse.yorku.ca Office: 101C Lassonde

More information

Copyright 2011 Sakun Sharma

Copyright 2011 Sakun Sharma Communication at Network Layer (Layer 3) Network layer is layer 3 of OSI Model. Network layer adds support of connecting multiple networks with each other. Network layer uses its own unique addressing

More information

3.6 Graphing Piecewise-Defined Functions and Shifting and Reflecting Graphs of Functions

3.6 Graphing Piecewise-Defined Functions and Shifting and Reflecting Graphs of Functions 76 CHAPTER Graphs and Functions Find the equation of each line. Write the equation in the form = a, = b, or = m + b. For Eercises through 7, write the equation in the form f = m + b.. Through (, 6) and

More information

WAN Technology and Routing

WAN Technology and Routing PS 60 - Network Programming WN Technology and Routing Michele Weigle epartment of omputer Science lemson University mweigle@cs.clemson.edu March, 00 http://www.cs.clemson.edu/~mweigle/courses/cpsc60 WN

More information

12 WEEK EXAM NAME: ALPHA: SECTION:

12 WEEK EXAM NAME: ALPHA: SECTION: 12 WEEK EXAM NAME: ALPHA: SECTION: 1. This is individual work. 2. SHOW ALL WORK! 3. Write legibly to receive credit. 4. Turn in your equation sheet. SCORE: /100 SCALE >89.5%: 31337 79.5 89.5%: H@XX0R 69.5

More information

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 11

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 11 CMPE 150/L : Introduction to Computer Networks Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 11 1 Midterm exam Midterm this Thursday Close book but one-side 8.5"x11" note is allowed (must

More information

Monday, September 28, 2015

Monday, September 28, 2015 Monda, September 28, 2015 Topics for toda Chapter 6: Mapping High-level to assembl-level The Pep/8 run-time stack (6.1) Stack-relative addressing (,s) SP manipulation Stack as scratch space Global variables

More information

PLEASE READ CAREFULLY BEFORE YOU START

PLEASE READ CAREFULLY BEFORE YOU START Page 1 of 11 MIDTERM EXAMINATION #1 OCT. 16, 2013 COMPUTER NETWORKS : 03-60-367-01 U N I V E R S I T Y O F W I N D S O R S C H O O L O F C O M P U T E R S C I E N C E Fall 2013-75 minutes This examination

More information

Distributed Algorithms in Networks EECS 122: Lecture 17

Distributed Algorithms in Networks EECS 122: Lecture 17 istributed lgorithms in Networks EES : Lecture 7 epartment of Electrical Engineering and omputer Sciences University of alifornia erkeley Network Protocols often have unintended effects TP Eample TP connections

More information

The wolf sheep cabbage problem. Search. Terminology. Solution. Finite state acceptor / state space

The wolf sheep cabbage problem. Search. Terminology. Solution. Finite state acceptor / state space Search The wolf sheep cabbage problem What is search? Terminology: search space, strategy Modelling Uninformed search (not intelligent ) Breadth first Depth first, some variations omplexity space and time

More information

Intelligent Agents. Foundations of Artificial Intelligence. Problem-Solving as Search. A Simple Reflex Agent. Agent with Model and Internal State

Intelligent Agents. Foundations of Artificial Intelligence. Problem-Solving as Search. A Simple Reflex Agent. Agent with Model and Internal State Intelligent s Foundations of Artificial Intelligence Problem-Solving as Search S7 Fall 007 Thorsten Joachims : Anything that can be viewed as perceiving its environment through sensors and acting upon

More information

Announcements. CS 5565 Network Architecture and Protocols. Count-To-Infinity. Poisoned Reverse. Distance Vector: Link Cost Changes.

Announcements. CS 5565 Network Architecture and Protocols. Count-To-Infinity. Poisoned Reverse. Distance Vector: Link Cost Changes. Announcements CS 6 Network Architecture and Protocols Lecture 20 Project 2B Part/ due Wed Apr 27 :9pm Part/2 due Wed Ma :9pm Current reading assignment: Chapter.6.7, Chapter Final Ma 0, 3:2pm, MCB 26 Godmar

More information

Configuring NAT for IP Address Conservation

Configuring NAT for IP Address Conservation This module describes how to configure Network Address Translation (NAT) for IP address conservation and how to configure inside and outside source addresses. This module also provides information about

More information

Sorting Algorithms Day 2 4/5/17

Sorting Algorithms Day 2 4/5/17 Sorting Algorithms Day 2 4/5/17 Agenda HW Sorting Algorithms: Review Selection Sort, Insertion Sort Introduce MergeSort Sorting Algorithms to Know Selection Sort Insertion Sort MergeSort Know their relative

More information

Lecture 2: Divide&Conquer Paradigm, Merge sort and Quicksort

Lecture 2: Divide&Conquer Paradigm, Merge sort and Quicksort Lecture 2: Divide&Conquer Paradigm, Merge sort and Quicksort Instructor: Outline 1 Divide and Conquer 2 Merge sort 3 Quick sort In-Class Quizzes URL: http://m.socrative.com/ Room Name: 4f2bb99e Divide

More information

11/13/2017 Network Layer (SSL) Network-layer functions. Recall the two network-layer functions:

11/13/2017 Network Layer (SSL) Network-layer functions. Recall the two network-layer functions: Chapter 5: outline 5. introduction 5.2 routing protocols link state distance vector 5.3 intra-as routing in the Internet 5.4 inter-as routing: BGP 5.5 The SDN control 5.6 ICMP: The Internet Control Message

More information

3/1/2016. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder

3/1/2016. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder. Calculus: A Reminder 1 Intermediate Microeconomics W3211 Lecture 5: Choice and Demand Introduction Columbia Universit, Spring 2016 Mark Dean: mark.dean@columbia.edu 2 The Stor So Far. 3 Toda s Aims 4 We have now have had a

More information

Lecture 2: Internet Structure

Lecture 2: Internet Structure Lecture 2: Internet Structure COMP 332, Spring 2018 Victoria Manfredi Acknowledgements: materials adapted from Computer Networking: A Top Down Approach 7 th edition: 1996-2016, J.F Kurose and K.W. Ross,

More information

Chapter 18 and 22. IPv4 Address. Data Communications and Networking

Chapter 18 and 22. IPv4 Address. Data Communications and Networking University of Human Development College of Science and Technology Department of Information Technology Chapter 18 and 22 Data Communications and Networking IPv4 Address 1 Lecture Outline IPv4 Addressing

More information

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2: Search. Problem Solving Agents

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2: Search. Problem Solving Agents Class Overview COMP 3501 / COMP 4704-4 Lecture 2: Search Prof. 1 2 Problem Solving Agents Problem Solving Agents: Assumptions Requires a goal Assume world is: Requires actions Observable What actions?

More information

Module 1: Asymptotic Time Complexity and Intro to Abstract Data Types

Module 1: Asymptotic Time Complexity and Intro to Abstract Data Types Module 1: Asymptotic Time Complexity and Intro to Abstract Data Types Dr. Natarajan Meghanathan Professor of Computer Science Jackson State University Jackson, MS 39217 E-mail: natarajan.meghanathan@jsums.edu

More information

CSC Design and Analysis of Algorithms

CSC Design and Analysis of Algorithms CSC 8301- Design and Analysis of Algorithms Lecture 6 Divide and Conquer Algorithm Design Technique Divide-and-Conquer The most-well known algorithm design strategy: 1. Divide a problem instance into two

More information

5.2 Switching Fabric Topologies

5.2 Switching Fabric Topologies 5. Switching abric Topologies enes abrics recursive construction rearrangeably non-blocking (probably the lowest cost such) proof under circuit switching with switches anyan abrics one half of a enes internal

More information

CSC Design and Analysis of Algorithms. Lecture 6. Divide and Conquer Algorithm Design Technique. Divide-and-Conquer

CSC Design and Analysis of Algorithms. Lecture 6. Divide and Conquer Algorithm Design Technique. Divide-and-Conquer CSC 8301- Design and Analysis of Algorithms Lecture 6 Divide and Conquer Algorithm Design Technique Divide-and-Conquer The most-well known algorithm design strategy: 1. Divide a problem instance into two

More information

1. Which of the following circuits can be used to store one bit of data? A) Encoder B) OR gate C) Flip Flop D) Decoder

1. Which of the following circuits can be used to store one bit of data? A) Encoder B) OR gate C) Flip Flop D) Decoder MCA Lateral 1. Which of the following circuits can be used to store one bit of data? A) Encoder B) OR gate C) Flip Flop D) Decoder 2. What would be the output of the following C program? main ( ){ int

More information

Part 8: The Three-Layer DMP Architecture

Part 8: The Three-Layer DMP Architecture Part 8: The Three-Layer DMP Architecture The DMP system and physical architecture Technical web report, v2.1, 2009 (v1.0, 2007), http://www.item.ntnu.no/~leifarne/the DMP system and physical architecture

More information

Internet Architecture. Network Layer Overview. Fundamental Network Layer Function. Protocol Layering and Data. Computer Networks 9/23/2009

Internet Architecture. Network Layer Overview. Fundamental Network Layer Function. Protocol Layering and Data. Computer Networks 9/23/2009 omputer Networks 9//9 Network Layer Overview Kai Shen Internet rchitecture ottom-up: : electromagnetic signals on the wire : data transfer between neighboring elements encoding, framing, error correction,

More information

SAMPLE OF THE STUDY MATERIAL PART OF CHAPTER 6. Sorting Algorithms

SAMPLE OF THE STUDY MATERIAL PART OF CHAPTER 6. Sorting Algorithms SAMPLE OF THE STUDY MATERIAL PART OF CHAPTER 6 6.0 Introduction Sorting algorithms used in computer science are often classified by: Computational complexity (worst, average and best behavior) of element

More information

Big Buffer of Switch

Big Buffer of Switch Big Buffer of Switch Content 1 2 3 Why Do We Need Big Buffer Arch of Switch Buffer How to Test Buffer 1 Why Do We Need Big Buffer When audience watch movies on the Internet, they are faced with the fact

More information

Multicast Communications. Slide Set were original prepared by Dr. Tatsuya Susa

Multicast Communications. Slide Set were original prepared by Dr. Tatsuya Susa Multicast Communications Slide Set were original prepared by Dr. Tatsuya Susa Outline 1. Advantages of multicast 2. Multicast addressing 3. Multicast Routing Protocols 4. Multicast in the Internet 5. IGMP

More information

CS 4700: Foundations of Artificial Intelligence. Bart Selman. Search Techniques R&N: Chapter 3

CS 4700: Foundations of Artificial Intelligence. Bart Selman. Search Techniques R&N: Chapter 3 CS 4700: Foundations of Artificial Intelligence Bart Selman Search Techniques R&N: Chapter 3 Outline Search: tree search and graph search Uninformed search: very briefly (covered before in other prerequisite

More information

3. Priority Queues. ADT Stack : LIFO. ADT Queue : FIFO. ADT Priority Queue : pick the element with the lowest (or highest) priority.

3. Priority Queues. ADT Stack : LIFO. ADT Queue : FIFO. ADT Priority Queue : pick the element with the lowest (or highest) priority. 3. Priority Queues 3. Priority Queues ADT Stack : LIFO. ADT Queue : FIFO. ADT Priority Queue : pick the element with the lowest (or highest) priority. Malek Mouhoub, CS340 Winter 2007 1 3. Priority Queues

More information

Wednesday, February 19, 2014

Wednesday, February 19, 2014 Wednesda, Februar 19, 2014 Topics for toda Solutions to HW #2 Topics for Eam #1 Chapter 6: Mapping High-level to assembl-level The Pep/8 run-time stack Stack-relative addressing (,s) SP manipulation Stack

More information

Dr Markus Hagenbuchner CSCI319 SIM. Distributed Systems Chapter 4 - Communication

Dr Markus Hagenbuchner CSCI319 SIM. Distributed Systems Chapter 4 - Communication Dr Markus Hagenbuchner markus@uow.edu.au CSCI319 SIM Distributed Systems Chapter 4 - Communication CSCI319 Chapter 4 Page: 1 Communication Lecture notes based on the textbook by Tannenbaum Study objectives:

More information

Computer Networks. More on Standards & Protocols Quality of Service. Week 10. College of Information Science and Engineering Ritsumeikan University

Computer Networks. More on Standards & Protocols Quality of Service. Week 10. College of Information Science and Engineering Ritsumeikan University Computer Networks More on Standards & Protocols Quality of Service Week 10 College of Information Science and Engineering Ritsumeikan University Introduction to Protocols l A protocol is a set of rules

More information

Unconstrained and Constrained Optimization

Unconstrained and Constrained Optimization Unconstrained and Constrained Optimization Agenda General Ideas of Optimization Interpreting the First Derivative Interpreting the Second Derivative Unconstrained Optimization Constrained Optimization

More information

Call Stacks + On Writing Good Code

Call Stacks + On Writing Good Code Call Stacks + On Writing Good Code Lecture 8 Today: Function Call Stack Recursion Good Coding Principles Stacks - a Brief Introduction A stack is an ordered collection of items, to which you may insert

More information

Stacks and Their Applications

Stacks and Their Applications Chapter 5 Stacks and Their Applications We have been discussing general list structures. In practice, we often work with some restricted cases, in which insertions and/or deletions occur only at one or

More information

CS 240 Fall Mike Lam, Professor. Priority Queues and Heaps

CS 240 Fall Mike Lam, Professor. Priority Queues and Heaps CS 240 Fall 2015 Mike Lam, Professor Priority Queues and Heaps Priority Queues FIFO abstract data structure w/ priorities Always remove item with highest priority Store key (priority) with value Store

More information

Cross-validation for detecting and preventing overfitting

Cross-validation for detecting and preventing overfitting Cross-validation for detecting and preventing overfitting Note to other teachers and users of these slides. Andrew would be delighted if ou found this source material useful in giving our own lectures.

More information

1 P age DS & OOPS / UNIT II

1 P age DS & OOPS / UNIT II UNIT II Stacks: Definition operations - applications of stack. Queues: Definition - operations Priority queues - De que Applications of queue. Linked List: Singly Linked List, Doubly Linked List, Circular

More information

What is Multicasting? Multicasting Fundamentals. Unicast Transmission. Agenda. L70 - Multicasting Fundamentals. L70 - Multicasting Fundamentals

What is Multicasting? Multicasting Fundamentals. Unicast Transmission. Agenda. L70 - Multicasting Fundamentals. L70 - Multicasting Fundamentals What is Multicasting? Multicasting Fundamentals Unicast transmission transmitting a packet to one receiver point-to-point transmission used by most applications today Multicast transmission transmitting

More information

CS 3516: Advanced Computer Networks

CS 3516: Advanced Computer Networks Welcome to CS 56: Adanced Computer Networks Prof. Yanhua Li Time: 9:00am 9:50am M, T, R, and F Location: Fuller 0 Fall 06 A-term Some slides are originall from the course materials of the tetbook Computer

More information

Computer Networks. Instructor: Niklas Carlsson

Computer Networks. Instructor: Niklas Carlsson Computer Networks Instructor: Niklas Carlsson Email: niklas.carlsson@liu.se Notes derived Computer Networking: A Top Down Approach, b Jim Kurose and Keith Ross, Addison-Wesle. The slides are adapted and

More information

Homework 2: IP Due: 11:59 PM, Oct 19, 2017

Homework 2: IP Due: 11:59 PM, Oct 19, 2017 CS68 Computer Networks Fonseca Homework : IP Due: :59 PM, Oct 9, 07 Contents IP Forwarding Routing More routing 4 Spanning Tree 4 IP Forwarding Answer the following questions based on the diagram below.

More information

CS164 Final Exam Winter 2013

CS164 Final Exam Winter 2013 CS164 Final Exam Winter 2013 Name: Last 4 digits of Student ID: Problem 1. State whether each of the following statements is true or false. (Two points for each correct answer, 1 point for each incorrect

More information

Unit 28 Website Production ASSIGNMENT 1

Unit 28 Website Production ASSIGNMENT 1 Unit 28 Website Production ASSIGNMENT 1 Last week Learning outcomes History HTML skeleton Annotated diagram of a WAN Servers, routers, client PC, browser, Server OS Switch, packet Architecture ISP Web

More information

ECE 573 Midterm 1 September 29, 2009

ECE 573 Midterm 1 September 29, 2009 ECE 573 Midterm 1 September 29, 2009 Name: Purdue email: Please sign the following: I affirm that the answers given on this test are mine and mine alone. I did not receive help from an person or material

More information

! Mon, May 5, 2:00PM to 4:30PM. ! Closed book, closed notes, clean desk. ! Comprehensive (covers entire course) ! 30% of your final grade

! Mon, May 5, 2:00PM to 4:30PM. ! Closed book, closed notes, clean desk. ! Comprehensive (covers entire course) ! 30% of your final grade Final Exam Review Final Exam Mon, May 5, 2:00PM to 4:30PM CS 2308 Spring 2014 Jill Seaman Closed book, closed notes, clean desk Comprehensive (covers entire course) 30% of your final grade I recommend

More information

NAT, IPv6, & UDP CS640, Announcements Assignment #3 released

NAT, IPv6, & UDP CS640, Announcements Assignment #3 released NAT, IPv6, & UDP CS640, 2015-03-03 Announcements Assignment #3 released Overview Network Address Translation (NAT) IPv6 Transport layer User Datagram Protocol (UDP) Network Address Translation (NAT) Hacky

More information

Appendix A.6 Functions

Appendix A.6 Functions A. Functions 539 RELATIONS: DOMAIN AND RANGE Appendi A. Functions A relation is a set of ordered pairs. A relation can be a simple set of just a few ordered pairs, such as {(0, ), (1, 3), (, )}, or it

More information

E3-E4 CM TECHNICAL IT INFRASTRUCTURE

E3-E4 CM TECHNICAL IT INFRASTRUCTURE E3-E4 CM TECHNICAL IT INFRASTRUCTURE WELCOME This is a presentation for the E3-E4 CM Technical Module for the Topic: IT Infrastructure. Eligibility: Those who have got the Up-gradation from E3 to E4. This

More information

Lecture 05 Application Layer - I

Lecture 05 Application Layer - I Computer Networks and Internet Protocol Prof. Soumya Kanti Ghosh Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Lecture 05 Application Layer - I Hi. So, we will

More information

ES623 Networked Embedded Systems

ES623 Networked Embedded Systems ES623 Networked Embedded Systems Introduction to Network models & Data Communication 16 th April 2013 OSI Models An ISO standard that covers all aspects of network communication is the Open Systems Interconnection

More information

Simple example. Analysis of programs with pointers. Program model. Points-to relation

Simple example. Analysis of programs with pointers. Program model. Points-to relation Simple eample Analsis of programs with pointers := 5 ptr := & *ptr := 9 := program S1 S2 S3 S4 What are the defs and uses of in this program? Problem: just looking at variable names will not give ou the

More information

Fault-Tolerant Computing

Fault-Tolerant Computing Fault-Tolerant Computing Hardware Design Methods Nov 2007 Self-Checking Modules Slide 1 About This Presentation This presentation has been prepared for the graduate course ECE 257A (Fault-Tolerant Computing)

More information

Algorithms and Data Structures

Algorithms and Data Structures Algorithms and Data Structures Dr. Malek Mouhoub Department of Computer Science University of Regina Fall 2002 Malek Mouhoub, CS3620 Fall 2002 1 6. Priority Queues 6. Priority Queues ffl ADT Stack : LIFO.

More information

Transport Layer TCP & UDP Week 7. Module : Computer Networks Lecturers : Lucy White Office : 324

Transport Layer TCP & UDP Week 7. Module : Computer Networks Lecturers : Lucy White Office : 324 Transport Layer TCP & UDP Week 7 Module : Computer Networks Lecturers : Lucy White lbwhite@wit.ie Office : 324 1 Purpose of the Transport Layer The Transport layer provides for the segmentation of data

More information

Lecture 2 8/24/18. Computer Memory. Computer Memory. Goals for today. Computer Memory. Computer Memory. Variables Assignment Sequential Steps

Lecture 2 8/24/18. Computer Memory. Computer Memory. Goals for today. Computer Memory. Computer Memory. Variables Assignment Sequential Steps Goals for toda Lecture 2 Variables Assignment Sequential Steps Sequential Steps, Variables, Assignment Computer Memor If we can t remember things, we can t actuall do ver much Computers have memor the

More information

ARTIFICIAL INTELLIGENCE (CSC9YE ) LECTURES 2 AND 3: PROBLEM SOLVING

ARTIFICIAL INTELLIGENCE (CSC9YE ) LECTURES 2 AND 3: PROBLEM SOLVING ARTIFICIAL INTELLIGENCE (CSC9YE ) LECTURES 2 AND 3: PROBLEM SOLVING BY SEARCH Gabriela Ochoa http://www.cs.stir.ac.uk/~goc/ OUTLINE Problem solving by searching Problem formulation Example problems Search

More information

CSE/EE 461 Lecture 13 Connections and Fragmentation. TCP Connection Management

CSE/EE 461 Lecture 13 Connections and Fragmentation. TCP Connection Management CSE/EE 461 Lecture 13 Connections and Fragmentation Tom Anderson tom@cs.washington.edu Peterson, Chapter 5.2 TCP Connection Management Setup assymetric 3-way handshake Transfer sliding window; data and

More information

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2. Problem Solving Agents. Problem Solving Agents: Assumptions

Class Overview. Introduction to Artificial Intelligence COMP 3501 / COMP Lecture 2. Problem Solving Agents. Problem Solving Agents: Assumptions Class Overview COMP 3501 / COMP 4704-4 Lecture 2 Prof. JGH 318 Problem Solving Agents Problem Solving Agents: Assumptions Requires a goal Assume world is: Requires actions Observable What actions? Discrete

More information

Rui Wang, Assistant professor Dept. of Information and Communication Tongji University.

Rui Wang, Assistant professor Dept. of Information and Communication Tongji University. Instructions: ti Language of the Computer Rui Wang, Assistant professor Dept. of Information and Communication Tongji University it Email: ruiwang@tongji.edu.cn Computer Hierarchy Levels Language understood

More information

Lecture 17 Notes Priority Queues

Lecture 17 Notes Priority Queues Lecture 17 Notes Priority Queues 15-122: Principles of Imperative Computation (Summer 1 2015) Frank Pfenning, Rob Simmons 1 Introduction In this lecture we will look at priority queues as an abstract type

More information

Implicit differentiation

Implicit differentiation Roberto s Notes on Differential Calculus Chapter 4: Basic differentiation rules Section 5 Implicit differentiation What ou need to know alread: Basic rules of differentiation, including the chain rule.

More information