9. BASIC programming: Control and Repetition
|
|
- Shanon Gilmore
- 5 years ago
- Views:
Transcription
1 Am: In ths lesson, you wll learn: H. 9. BASIC programmng: Control and Repetton Scenaro: Moz s showng how some nterestng patterns can be generated usng math. Jyot [after seeng the nterestng graphcs]: Usng a repettve mathematcal sequence, we can easly draw very nterestng patterns. Moz: Yes. Generate nterestng numbers usng mathematcal calculatons and use these to generate nterestng graphcs. Execute the program step by step and understand how a sequence starts, s repeated and ends, wth for statement. clg for = 1 to 20 square=* Prnt square color blue rect square,square,, next Text output Graphcs output square square square square 16 square 25 square 36 square 49 square 64 square 81 square 100 so on untl >10 Tejas: Frst the graphcs output screen and the text output screen are cleared. Jyot: s assgned the value 1 at the start of the repetton. [ = 1] Tejas: The sequence to be repeated starts. Square of s calculated and assgned to square. Then square s prnted n text output area. [ square = 1] Jyot: square s used for x and y coordnates n the rectangle statement. The length and breadth of the rectangle s set to. A rectangle s output n the graphcs output area. Rect 1,1,1,1 Tejas: Next s ncremented by 1. The sequence s repeated tll = 20. When >20 the repetton stops. [ = 2... =20] Moz: Very good. You have explaned the repetton sequence very well. Jyot: Instead of ncrementng the value of by 1 s t possble to ncrement by more than one? 90
2 Moz: Yes. You can. For example you can wrte the repetton statement as follows: # more.kbs clg for t = 1 to 300 step 3 color red lne 0,0,300,t color blue lne 0,0,t,300 next t Graphcs output Tejas: Wow. What a pattern. Moz: Change the step to 100 and see what wll be the effect. Jyot: When the step s ncremented by 100, the sequence s repeated 3 tmes. 3 lnes of blue and 3 lnes of red are drawn. Moz: Yes. Instead of ncrementng by 1, the repetton count s ncremented by the step. Info Repetton of a block of statements - For statement Syntax for varable = expr1 to expr2 statement(s) next varable for varable = expr1 to expr2 step expr3 statement(s) next varable For statement, executes a specfed block of code a specfed number of tmes, and keeps track of the value of the varable. At the start of executon of for loop, varable s assgned the value of expr1 and the specfed block s executed. f step s not specfed, varable wll be ncremented by 1 for the second and subsequent repetton of the specfed block. If step s specfed, varable wll be ncremented by expr3 for the second and subsequent repetton of the specfed block. for = 20 to 25 step 5 Prnt + square = + * next for = 20 to 25 Prnt + square = + * next for = 20 step -1 Prnt + square = + * next For loop termnates when the value of varable exceeds expr2. Tejas: Usng the lne statement nterestng graphcs have been generated. Moz: Rght. Look at the lnes closely n the output of the program more.kbs. Jyot: They look crooked. The computer s not able to draw straght lnes. The pattern looks lke the prnt on our table cloth at home. 91 Insde the for loop: t 1... next t t 4 (Step command ncrements the value of t by... 3)... next t... so on untl t becomes greater than square = square = square = square = square = square = square = square = square = square = square = square = square = square = 400 Moz: You are rght. These patterns are used n textles. The nterestng graphc s generated because of the computer beng unable to draw perfectly straght lnes. It approxmates a straght lne by drawng the pxels n a star step fashon. Such patterns generated wth lnes are called a more pattern.
3 clg lne 0,0,1,255 lne 255,255,1,0 lne 1,255,255,255 Grapc output Graphcs Drawng a lne: lne statement Info Syntax lne start_x, start_y, fnsh_x, fnsh_y Draw a lne one pxel wde from the startng pont to the endng pont, usng the current color. (start x, start y) (fnsh x, fnsh y) Jyot: In Scratch we could execute a block usng a condton. I want to wrte a program usng the Proft and Loss flowchart. What s the syntax of If statement n Basc? Decsons Executon branchng If statement Info Syntax f condton then statement(s) end f f condton then statement(s) else statement(s) end f The f statement allows you to control f a program executes a secton of code or not, based on whether a gven condton s true or false. The condton whch s also referred to as boolean condton can contan comparson operators or logcal operators. (A table of the operators s gven separately). The evaluaton of the condton s ether true or false. At the start of the executon of f statement the condton s evaluated. ooif the condton s true the block of statements followng then are executed. ooif the condton s false, the executon contnues ether n the else block (whch s usually optonal), or f there s no else branch, then the executon contnues after the end f. It s often customary to ndent the statements wthn the f or else block. cls nput What s your age, myage nput What s your frend s age?, frendage f myage = frendage then Prnt You and your frend of same age endf What s your age 13 What s your frend s age? 14 Frst Number 35 Second number 90 Computerj: Yes Tejas: The flowchart does not show what should be done f both CP and SP are equal. Let us use the else n f statement to take care of ths condton. Moz: Good. You must take care of all the condtons that are possble. 92
4 Jyot: We can use comparson operators to compare CP and SP and fnd f t s proft, loss or the values are equal. Comparson Operators In a program we often need to compare two values n a program to decde what to do. A comparson operator (ex: <, >, <=) works wth two values and returns true or false based on the result of the comparson. Comparatve operators Descrpton Example expr1 < expr2 Evaluates to True f value of expr1 s less than value of expr2, 2<4 s True else to False. expr1 > expr2 Evaluates to True f value of expr1 s greater than value of expr2, (2+5)>(3+4) s else to False. False expr1 = expr2 expr1 >= expr2 expr1 <= expr2 expr1 <> expr2 Evaluates to True f value of expr1 s equal to value of expr2 else to False. Evaluates to True f value of expr1 s greater than or equal to value of expr2, else to False. Evaluates to True f value of expr1 s less than or equal to value of expr2, else to False. Evaluates to True f value of expr1 s not equal to value of expr2 else to False. 298=298 s True 2>=4 s False 2<=4 s True 2<>4 s True Jyot: Let us see f we can dsplay an mage n the graphcs output area. I have drawn mages for proft and loss. Tejas: We can use mgload. Ths s very easy we have to just provde x,y coordnates where we want the mage dsplayed and the mage fle name. Let us also check how to dsplay a capton for the mage n graphcs area. Jyot: Dsplayng text also has smlar syntax to mgload. In place of fle name we have to provde the text n quotes. Graphcs Loadng an mage mgload statement Info Syntax mgload x, y, flename mgload x, y, scale, flename mgload x, y, scale, rotaton, flename Imgload reads the mage n the Grapc output fle specfed n the flename and dsplays t on the graphcs output area. The x, y coordnates specfy the locaton of the center of the mage, where the mage should be dsplayed n the graphcs output area. Grapc output Many of the mage fle formats are recognzed by the program. Some of these formats are bmp, png, gf, jpg and jpeg. Scalng and rotaton s optonal. o oscalng s used to resze the mage. Note that scale Grapc output s specfed by the decmal scale where 1 s full sze. oothe mage can be rotated around t s center by specfyng how far to rotate by specfyng the angle (0 to 360). 93
5 The program wrtten by Tejas and Jyot. Note we have to modfy the flowchart to nclude = condton also. Wll also modfy program later. Flowchart: How to fnd proft or loss Start Read Cost prce (CP) Read Sellng prce (SP) Is SP=CP Yes Prnt no proft or loss No Is SP>CP Yes Proft= SP-CP No Loss= CP-SP Prnt Proft Prnt Loss Stop Text output Graphcs output PROFIT CP SP Proft Text output CP 567 SP 500 Loss 67 Graphcs output LOSS 94
6 Jyot: I have a lst of words. I want to use these to wrte a quz program. Let us fnd how to save these words and later on use them to prepare a quz. Tejas: We can defne a lst whch s called an array as follows. Dm array_name(ndex) Dm array_name$(ndex) Snce our lst wll contan strng values we have to add $ at the end of the array name smlar to a strng varable. We have to also specfy the number of values the lst wll contan n the brackets. Jyot: The computer then has to reserve 5 memory locatons for the array. What s the name gven to each locaton? Moz: The computer names the 5 memory locatons as adjectv$(0), adjectv$(1), adjectv$(2), adjectv$(3), adjectv$(4). The number n the brackets s called an ndex. Ths s also called the numerc address of the tem n a lst or an array. Tejas: Ths s smlar to one column n a spreadsheet. Moz: Yes. Note that ndex starts wth 0, nstead of 1. Each tem of an array s called the element of the array. The dm statement assgns an empty strng to each element n the array. Ths s also called ntalzng the array wth a value. Jyot: If t s a numerc array then what s the ntalzaton value? Moz: Each element of a numerc array s ntalzed wth the value 0. dm adjectv$(5) adjectv$(0) adjectv$(1) adjectv$(2) adjectv$(3) adjectv$(4) Jyot: Let us now assgn values to the lst. adjectv$ = { Amazng, Slppery, large, Monthly, Jucy } Tejas: Now let us retreve the values and prnt them. adjectv$(0) Amazng adjectv$(1) Slppery adjectv$(2) large adjectv$(3) Monthly adjectv$(4) Jucy Dm adjectv$ (5) adjectv$ = { Amazng, Slppery, large, Monthly, Jucy } prnt Adjectves prnt for = 0 to 4 Prnt adjectv$[] next Adjectves Amazng Slppery large Monthly Jucy 95
7 Creatng a one dmensonal array Dm (Index) Info Syntax to create a one dmensonal array Dm array_name(ndex) Dm array_name$(ndex) Dm statement creates an array n the computer s memory wth the varable name provded n the array_ name. Arrays can be ether numerc or strng. Syntax of namng of the array follows the same syntax as numerc and strng varable name. The number of tems n an array s specfed by the ndex, whch s always an nteger value greater than 1, n the parenthess. The dm statement ntalzes each element n the new array wth ether zero (0) f the array s a numerc array or empty strng ( ), f the array s a strng array. Syntax to assgn and to retreve values of an array array_name = {value1,value2,value3,...} array_name$={ strng1, strng2,...} array_name[ndex] = value array_name$ [ ndex] = value Each element of an array can also be assgned a value. Array elements are assgned by smply usng the element ndex n square brackets along wth the array name. dm marks (2) dm name$ (3) Dm marks (3) marks = {90,86,65} Dm marks (3) marks = {90,86,65} Total = marks[0]+marks[1]+marks[2] prnt Total marks= + Total Dm a(3) a[0]= 89 a[1] = 23 prnt a[0] + a[1] Total marks= marks 0 marks1 0 names$ marks0 90 marks1 86 marks2 65 Tejas: Wow. Ths s good. We want to convert the game Guess my number nto a program. In ths game the computer chooses a number. The user has to keep guessng the number, tll the guess s correct. Jyot: Is there some way to make the computer choose a random number? Moz: Yes. Check out the Functons secton n the Basc-256 manual. Jyot: Yes, there s a functon rand. It s exactly what we want. number = rand *50 prnt number Number
8 Tejas: The functon rand gves a decmal number. We want a whole number. Moz: Snce you want the user to guess a number from 1 to 50 multply the number generated by rand wth the last number n your range whch s 50. Then convert the number you get to nteger usng the nt functon. Jyot: Oh! Got t. For example: x = rand =.902 x = rand * 50 =.902 * 50 = x = nt(rand * 50) = nt(.902 * 50) = nt(45.100) = 45 Moz: Rght. When you use max of the range you get numbers wthn the range. You can experment and fnd out how ths works wth varous numbers. Now go ahead and wrte your program. number = nt (rand *50) prnt number 22 Functons Generatng a random number Info Syntax rand The functon rand returns a random number. Rand can be used n an expresson or assgned to a varable. The random number generated vares from zero to 1. rand can be used n an expresson. number = rand rand_nt = nt (rand) nt_1to50 = nt (rand*50) prnt rand = + number prnt rand_nt = + rand_nt prnt rand_1to50 = + nt_1to50 rand = rand_nt = 0 rand_1to50 = 44 Jyot: Oh! So we have to use nt to convert the decmal number to nteger. Tejas: I just can t wat to wrte the game. Let us start. Moz: Frst wrte the man steps of the program. Then convert t nto a BASIC program. Remember to put comments n the program. 1. Declare and ntalze array to dsplay chance count. 2. Generate a random number between 1 and 50 store t n mynumber. 3. Ask the player to gve the range for hs/her guess. 4. Take the player s nput. 5. Compare and reply f mynumber s wthn the range. 6. Ask player to now guess the number. 7. Player guesses number. 8. Compare and dsplay smley and a msg f the guess s equal to mynumber. 9. Compare and dsplay approprate msg f the guess s greater than or less to mynumber. 10. After 5 chances dsplay mynumber wth approprate messages. 97
9 5. Fnal program Guess the number that computer thnks of: Verson 3 #Guess my number cls clg #Declare and ntalze array to dsplay chance count dm chance$(6) #Intalze Y-coordnate, chance strngs n array, specfy font for graphc dsplay Y= 5 font Tahoma, 12, 50 chance$ = { NIL, Frst, Second, Thrd, Fourth, Ffth } #Generate a random number between 1 and 50 mynumber = nt(rand *50 + 1) prnt I thnk of a number between 1 and 50. Guess my number! prnt prnt Here are 3 chances where you get some hnt about my number! For =1 to 3 #Dsplay chance count n graphcs output color blue Y = Y + 25 text 0, Y, chance$[] + Chance Prnt #Player gves the range n whch he/she thnks the number s Prnt Player asks: Is Your number between nput Frst number, frstnumber nput Second number, secondnumber #Compare and reply f mynumber s wthn the range f (mynumber >= frstnumber) and (mynumber <= secondnumber) then Prnt Computer reples: Yes else Prnt Computer reples: No endf Y= Y + 25 Next #Player guesses number for = 1 to 3 nput Computer: Guess my number, yourguess #Compare and dsplay msg f the guess s not equal to mynumber f mynumber > yourguess then prnt My number s greater than your guess. endf f mynumber < yourguess then prnt My number s less than your guess. endf f mynumber = yourguess then prnt You guessed my number wth + + chances. Well done. end endf next #After 5 chances dsplay mynumber Prnt My number s + mynumber font Tahoma,20,75 text 5,125, Better luck next tme I thnk of a number between 1 and 50. Guess my number! Here are 3 chances where you get some hnt about my number! Player asks: Is Your number between Frst number 1 Second number 25 Computer reples: Yes Player asks: Is Your number between Frst number 2 Second number 12 Computer reples: No Player asks: Is Your number between Frst number 13 Second number 20 Computer reples: Yes Computer: Guess my number 16 My number s less than your guess. Computer: Guess my number 15 My number s less than your guess. Computer: Guess my number 14 My number s less than your guess. Computer: Guess my number 13 You guessed my number wth 3 chances. Well done. Y Chance$ [1] Chance$ [2] Chance$ [3] Chance$ [4] Chance$ [5] Chance$ [6] mynumber Frst number Second number Y Frst number Second number Y Frst number Second number Y Your guess Your guess Your guess Your guess 5 NIL Frst Second Thrd Fourth Ffth
10 #Reuse the graphc code from CM VI to dsplay smley clg color yellow rect 0,0,300,300 # draw the face color whte crcle 150,150,100 # draw the mouth color black crcle 150,160,70 # A whte crcle s supermposed on the black crcle to draw the mouth color whte crcle 150,150,70 # put on the eyes color black crcle 105,110,15 crcle 185,110,15 #End of reuse code Graphc output Wake up! Bos Boot up! I am ready! Lesson Outcome At the end of the lesson, you wll be able to: Categorze a computer component nto hardware and software. Identfy varous parts nsde the computer and state ther functons. Os 99
11 Level VII Lesson 9 WORKSHEETS 1. a. b. What s the output of the program? for t = 1 to 10 step 2 p=3 prnt p*t ; next t Multplcaton table of 3. 3, 9, 15, 21, 27 v. Multplcaton table of 2 Sum=245 If Sum>245 then Prnt You reached level 3 else Prnt Stll to go End f. You reached level Stll to go v. none of the above c. for t = 1 to 10 for p=1 to 10 prnt p*t next p next t. Squares of numbers from 1 to 10. Multplcaton tables of all numbers from 1 to 10. Squareroots of numbers from 1 to 10 v. None of the above d. Dm Workngdays$(4) Workngdays$={ Monday, Tuesday, Wednesday, Thursday, Frday } Prnt Workngdays$[2]. Monday. Tuesday. Wednesday v. Thursday e. Dm a(3) a[0]= 89 a[1] = 23 a[2] = a[0] + a[1] For = 1 to 2 Prnt a[]; next v
12 Level VII Lesson 9 WORKSHEETS f. Number = rand*100 Prnt Number... v. Any number between 0 and 100 Any number from 0(ncludng 0) to 100( excludng 100) Any number from 0(ncludng 0) to 100( ncludng 100) Any number from 0(excludng 0) to 100( ncludng 100) 2. Here s a program wrtten n Basc-256. Insert the necessary comments clearly statng the functon of each code segment. # Dm Answer$(5) Dm Dsplay(5) Answer$ = { Frst, Second, Thrd, Fourth, Ffth } # For =0 to 4 Input Answer$[] + Number:, answer Dsplay[] = answer Next # For t=0 to 4 Prnt Dsplay[t] Next t 3. Insert the rect statement n the followng program that would gve the output shown n red n the graphcs output area. clg for = 1 to 20 square=* Prnt * color blue rect square,square,, color red Graphcs output next 101
13 Level VII Lesson 9 WORKSHEETS 4. a. Here s a program to fnd the number of people who own a car n a buldng. The number of resdents n the buldng s 6. Go through the program and see whether the sequence s correct. If there s a mstake correct t and verfy by runnng t n Basc-256. For =0 to 5 counter=0 Prnt Do you own a car? (answer wth yes or no) Input answer$ If answer$= yes then counter=counter+1 end f Next prnt Number of resdents wth a car: + counter b. Now nsert the code fragment to record the answers of each resdents n the buldng. Hnt: Use an array to store the answers of the resdents. 102
14 Level VII Lesson 9 WORKSHEETS 5. a. Use the followng graph sheet to draw the followng shapes. rght trangle pentagon star b. Wrte a program n Basc-256 to draw any one of the above shapes usng the lne statement. 103
15 ACTIVITY Level VII Lesson 9 1. Here s a program whch uses For loop. Check what s the output you wll get when you ntroduce Step whle ncrementng the value of. cls clg For = 1 to 20 square=* prnt + and + square rect square,square,, next Check the out output when the steps are 2.5 and Suppose your class has 45 students. Wrte a program to fnd the number of students present today what s the number of students absent? Hnt: Use For loop, If then else and counters to complete the program. Expl re 1. How to add comments n a document. 2. How to record changes made n a document. 3. Calculate word count for selected text. 104
16 Teacher s Corner Book Level VII Lesson 6 105
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 informationCMPS 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 informationAgenda & Reading. Simple If. Decision-Making Statements. COMPSCI 280 S1C Applications Programming. Programming Fundamentals
Agenda & Readng COMPSCI 8 SC Applcatons Programmng Programmng Fundamentals Control Flow Agenda: Decsonmakng statements: Smple If, Ifelse, nested felse, Select Case s Whle, DoWhle/Untl, For, For Each, Nested
More informationComputer models of motion: Iterative calculations
Computer models o moton: Iteratve calculatons OBJECTIVES In ths actvty you wll learn how to: Create 3D box objects Update the poston o an object teratvely (repeatedly) to anmate ts moton Update the momentum
More informationAssignment # 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 informationBrave 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 informationHarvard University CS 101 Fall 2005, Shimon Schocken. Assembler. Elements of Computing Systems 1 Assembler (Ch. 6)
Harvard Unversty CS 101 Fall 2005, Shmon Schocken Assembler Elements of Computng Systems 1 Assembler (Ch. 6) Why care about assemblers? Because Assemblers employ some nfty trcks Assemblers are the frst
More informationProgramming 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 informationUSING GRAPHING SKILLS
Name: BOLOGY: Date: _ Class: USNG GRAPHNG SKLLS NTRODUCTON: Recorded data can be plotted on a graph. A graph s a pctoral representaton of nformaton recorded n a data table. t s used to show a relatonshp
More informationR 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 informationSequential 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 informationMidterms Save the Dates!
Unversty of Brtsh Columba CPSC, Intro to Computaton Alan J. Hu Readngs Ths Week: Ch 6 (Ch 7 n old 2 nd ed). (Remnder: Readngs are absolutely vtal for learnng ths stuff!) Thnkng About Loops Lecture 9 Some
More informationCS1100 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 information3D vector computer graphics
3D vector computer graphcs Paolo Varagnolo: freelance engneer Padova Aprl 2016 Prvate Practce ----------------------------------- 1. Introducton Vector 3D model representaton n computer graphcs requres
More informationAssembler. Building a Modern Computer From First Principles.
Assembler Buldng a Modern Computer From Frst Prncples www.nand2tetrs.org Elements of Computng Systems, Nsan & Schocken, MIT Press, www.nand2tetrs.org, Chapter 6: Assembler slde Where we are at: Human Thought
More informationIntro. 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 informationCHARUTAR 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 informationAssembler. Shimon Schocken. Spring Elements of Computing Systems 1 Assembler (Ch. 6) Compiler. abstract interface.
IDC Herzlya Shmon Schocken Assembler Shmon Schocken Sprng 2005 Elements of Computng Systems 1 Assembler (Ch. 6) Where we are at: Human Thought Abstract desgn Chapters 9, 12 abstract nterface H.L. Language
More informationA 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 informationHello Tejas + - / + - * / + - * /+ - * / Name$ = Tejas Print Hello +Name$ * / - * / + - * / * / + - */+ + - * */ Print Input Rect Circ
+ - / ct Circle e Print Input Rect Circle / cle * / + - * / + - * /+ - * / Name$ = Tejas Print Hello +Name$ Print Input Rect Circle + - * / + - * /+ - * / ircle e Print Input Rect Circle Hello Tejas -
More informationFor 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 informationComplex 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 informationAlgorithm To Convert A Decimal To A Fraction
Algorthm To Convert A ecmal To A Fracton by John Kennedy Mathematcs epartment Santa Monca College 1900 Pco Blvd. Santa Monca, CA 90405 jrkennedy6@gmal.com Except for ths comment explanng that t s blank
More informationNotes 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 informationOutline. Midterm Review. Declaring Variables. Main Variable Data Types. Symbolic Constants. Arithmetic Operators. Midterm Review March 24, 2014
Mdterm Revew March 4, 4 Mdterm Revew Larry Caretto Mechancal Engneerng 9 Numercal Analyss of Engneerng Systems March 4, 4 Outlne VBA and MATLAB codng Varable types Control structures (Loopng and Choce)
More informationLife 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 informationAP 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 informationVirtual 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 informationLecture 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 informationExercises (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 information2x x l. Module 3: Element Properties Lecture 4: Lagrange and Serendipity Elements
Module 3: Element Propertes Lecture : Lagrange and Serendpty Elements 5 In last lecture note, the nterpolaton functons are derved on the bass of assumed polynomal from Pascal s trangle for the fled varable.
More informationThe Codesign Challenge
ECE 4530 Codesgn Challenge Fall 2007 Hardware/Software Codesgn The Codesgn Challenge Objectves In the codesgn challenge, your task s to accelerate a gven software reference mplementaton as fast as possble.
More informationIntroduction to Geometrical Optics - a 2D ray tracing Excel model for spherical mirrors - Part 2
Introducton to Geometrcal Optcs - a D ra tracng Ecel model for sphercal mrrors - Part b George ungu - Ths s a tutoral eplanng the creaton of an eact D ra tracng model for both sphercal concave and sphercal
More informationMATHEMATICS FORM ONE SCHEME OF WORK 2004
MATHEMATICS FORM ONE SCHEME OF WORK 2004 WEEK TOPICS/SUBTOPICS LEARNING OBJECTIVES LEARNING OUTCOMES VALUES CREATIVE & CRITICAL THINKING 1 WHOLE NUMBER Students wll be able to: GENERICS 1 1.1 Concept of
More informationOutline. CIS 110: Intro to Computer Programming. What Do Our Programs Look Like? The Scanner Object. CIS 110 (11fa) - University of Pennsylvania 1
Outlne CIS 110: Intro to Computer Programmng The Scanner Object Introducng Condtonal Statements Cumulatve Algorthms Lecture 10 Interacton and Condtonals ( 3.3, 4.1-4.2) 10/15/2011 CIS 110 (11fa) - Unversty
More information2D 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 informationELEC 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 informationCSCI 104 Sorting Algorithms. Mark Redekopp David Kempe
CSCI 104 Sortng Algorthms Mark Redekopp Davd Kempe Algorthm Effcency SORTING 2 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
More informationWelcome to the Three Ring %CIRCOS: An Example of Creating a Circular Graph without a Polar Axis
PharmaSUG 2018 - Paper DV14 Welcome to the Three Rng %CIRCOS: An Example of Creatng a Crcular Graph wthout a Polar Axs Jeffrey Meyers, Mayo Clnc ABSTRACT An nternal graphcs challenge between SAS and R
More informationCourse 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 informationPass by Reference vs. Pass by Value
Pass by Reference vs. Pass by Value Most methods are passed arguments when they are called. An argument may be a constant or a varable. For example, n the expresson Math.sqrt(33) the constant 33 s passed
More informationSupport 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 informationKent 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 informationSetup and Use. Version 3.7 2/1/2014
Verson 3.7 2/1/2014 Setup and Use MaestroSoft, Inc. 1750 112th Avenue NE, Sute A200, Bellevue, WA 98004 425.688.0809 / 800.438.6498 Fax: 425.688.0999 www.maestrosoft.com Contents Text2Bd checklst 3 Preparng
More informationTN348: Openlab Module - Colocalization
TN348: Openlab Module - Colocalzaton Topc The Colocalzaton module provdes the faclty to vsualze and quantfy colocalzaton between pars of mages. The Colocalzaton wndow contans a prevew of the two mages
More informationProgramming Assignment Six. Semester Calendar. 1D Excel Worksheet Arrays. Review VBA Arrays from Excel. Programming Assignment Six May 2, 2017
Programmng Assgnment Sx, 07 Programmng Assgnment Sx Larry Caretto Mechancal Engneerng 09 Computer Programmng for Mechancal Engneers Outlne Practce quz for actual quz on Thursday Revew approach dscussed
More informationSetup and Use. For events not using AuctionMaestro Pro. Version /7/2013
Verson 3.1.2 2/7/2013 Setup and Use For events not usng AuctonMaestro Pro MaestroSoft, Inc. 1750 112th Avenue NE, Sute A200, Bellevue, WA 98004 425.688.0809 / 800.438.6498 Fax: 425.688.0999 www.maestrosoft.com
More informationCompiler 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 informationMathematics 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 informationProblem 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 informationEsc101 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 informationOracle Database: SQL and PL/SQL Fundamentals Certification Course
Oracle Database: SQL and PL/SQL Fundamentals Certfcaton Course 1 Duraton: 5 Days (30 hours) What you wll learn: Ths Oracle Database: SQL and PL/SQL Fundamentals tranng delvers the fundamentals of SQL and
More informationAMath 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 informationSolutions to Programming Assignment Five Interpolation and Numerical Differentiation
College of Engneerng and Coputer Scence Mechancal Engneerng Departent Mechancal Engneerng 309 Nuercal Analyss of Engneerng Systes Sprng 04 Nuber: 537 Instructor: Larry Caretto Solutons to Prograng Assgnent
More information5.1 The ISR: Overvieui. chapter
chapter 5 The LC-3 n Chapter 4, we dscussed the basc components of a computer ts memory, ts processng unt, ncludng the assocated temporary storage (usually a set of regsters), nput and output devces, and
More informationCSE 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 informationToday 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 informationSteps for Computing the Dissimilarity, Entropy, Herfindahl-Hirschman and. Accessibility (Gravity with Competition) Indices
Steps for Computng the Dssmlarty, Entropy, Herfndahl-Hrschman and Accessblty (Gravty wth Competton) Indces I. Dssmlarty Index Measurement: The followng formula can be used to measure the evenness between
More informationThe 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 informationEdge Detection in Noisy Images Using the Support Vector Machines
Edge Detecton n Nosy Images Usng the Support Vector Machnes Hlaro Gómez-Moreno, Saturnno Maldonado-Bascón, Francsco López-Ferreras Sgnal Theory and Communcatons Department. Unversty of Alcalá Crta. Madrd-Barcelona
More informationNon-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 informationParallelism 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 informationHello Tejas. Print - BASIC-256 program and text output + - / + - * / + - * /+ - * / Name$ = Tejas Print Hello +Name$ * / - * / + - * /+ + -
+ - / ct Circle e Print Input Rect Circle / cle * / + - * / + - * /+ - * / Name$ = Tejas Print Hello +Name$ Print Input Rect Circle + - * / + - * /+ - * / ircle e Print Input Rect Circle Hello Tejas -
More informationNGPM -- 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 informationCS240: 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 informationLECTURE NOTES Duality Theory, Sensitivity Analysis, and Parametric Programming
CEE 60 Davd Rosenberg p. LECTURE NOTES Dualty Theory, Senstvty Analyss, and Parametrc Programmng Learnng Objectves. Revew the prmal LP model formulaton 2. Formulate the Dual Problem of an LP problem (TUES)
More informationCE 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 informationNUMERICAL 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 informationMidterms Save the Dates!
Unversty of Brtsh Columba CPSC, Intro to Computaton Alan J. Hu Thnkng About Loops Intro to Arrays (Obect References?) Readngs Ths Week: Ch 6 (Ch 7 n old 2 nd ed). Next Week: Ch 7 (Ch 8 n old 2 nd ed).
More informationK-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 information6.854 Advanced Algorithms Petar Maymounkov Problem Set 11 (November 23, 2005) With: Benjamin Rossman, Oren Weimann, and Pouya Kheradpour
6.854 Advanced Algorthms Petar Maymounkov Problem Set 11 (November 23, 2005) Wth: Benjamn Rossman, Oren Wemann, and Pouya Kheradpour Problem 1. We reduce vertex cover to MAX-SAT wth weghts, such that the
More informationHigh 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 informationNachos Project 3. Speaker: Sheng-Wei Cheng 2010/12/16
Nachos Project Speaker: Sheng-We Cheng //6 Agenda Motvaton User Programs n Nachos Related Nachos Code for User Programs Project Assgnment Bonus Submsson Agenda Motvaton User Programs n Nachos Related Nachos
More informationScan Conversion & Shading
Scan Converson & Shadng Thomas Funkhouser Prnceton Unversty C0S 426, Fall 1999 3D Renderng Ppelne (for drect llumnaton) 3D Prmtves 3D Modelng Coordnates Modelng Transformaton 3D World Coordnates Lghtng
More informationAnalysis of Continuous Beams in General
Analyss of Contnuous Beams n General Contnuous beams consdered here are prsmatc, rgdly connected to each beam segment and supported at varous ponts along the beam. onts are selected at ponts of support,
More informationScan Conversion & Shading
1 3D Renderng Ppelne (for drect llumnaton) 2 Scan Converson & Shadng Adam Fnkelsten Prnceton Unversty C0S 426, Fall 2001 3DPrmtves 3D Modelng Coordnates Modelng Transformaton 3D World Coordnates Lghtng
More informationImproving Low Density Parity Check Codes Over the Erasure Channel. The Nelder Mead Downhill Simplex Method. Scott Stransky
Improvng Low Densty Party Check Codes Over the Erasure Channel The Nelder Mead Downhll Smplex Method Scott Stransky Programmng n conjuncton wth: Bors Cukalovc 18.413 Fnal Project Sprng 2004 Page 1 Abstract
More informationPriority 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 informationThis chapter discusses aspects of heat conduction. The equilibrium heat conduction on a rod. In this chapter, Arrays will be discussed.
1 Heat Flow n a Rod Ths chapter dscusses aspects of heat conducton. The equlbrum heat conducton on a rod. In ths chapter, Arrays wll be dscussed. Arrays provde a mechansm for declarng and accessng several
More informationCS221: 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 informationStorage Binding in RTL synthesis
Storage Bndng n RTL synthess Pe Zhang Danel D. Gajsk Techncal Report ICS-0-37 August 0th, 200 Center for Embedded Computer Systems Department of Informaton and Computer Scence Unersty of Calforna, Irne
More informationOverview. CSC 2400: Computer Systems. Pointers in C. Pointers - Variables that hold memory addresses - Using pointers to do call-by-reference in C
CSC 2400: Comuter Systems Ponters n C Overvew Ponters - Varables that hold memory addresses - Usng onters to do call-by-reference n C Ponters vs. Arrays - Array names are constant onters Ponters and Strngs
More informationREFRACTION. a. To study the refraction of light from plane surfaces. b. To determine the index of refraction for Acrylic and Water.
Purpose Theory REFRACTION a. To study the refracton of lght from plane surfaces. b. To determne the ndex of refracton for Acrylc and Water. When a ray of lght passes from one medum nto another one of dfferent
More informationANSYS FLUENT 12.1 in Workbench User s Guide
ANSYS FLUENT 12.1 n Workbench User s Gude October 2009 Copyrght c 2009 by ANSYS, Inc. All Rghts Reserved. No part of ths document may be reproduced or otherwse used n any form wthout express wrtten permsson
More informationSorting 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 informationCSE 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 informationA New Approach For the Ranking of Fuzzy Sets With Different Heights
New pproach For the ankng of Fuzzy Sets Wth Dfferent Heghts Pushpnder Sngh School of Mathematcs Computer pplcatons Thapar Unversty, Patala-7 00 Inda pushpndersnl@gmalcom STCT ankng of fuzzy sets plays
More informationThe example below contains two doors and no floor level obstacles. Your panel calculator should now look something like this: 2,400
Step 1: A r c h t e c t u r a l H e a t n g o begn wth you must prepare a smple drawng for each room n whch you wsh to nstall our Heat Profle Skrtng Heatng System. You certanly don't need to be Pcasso,
More informationETAtouch RESTful Webservices
ETAtouch RESTful Webservces Verson 1.1 November 8, 2012 Contents 1 Introducton 3 2 The resource /user/ap 6 2.1 HTTP GET................................... 6 2.2 HTTP POST..................................
More informationVRT012 User s guide V0.1. Address: Žirmūnų g. 27, Vilnius LT-09105, Phone: (370-5) , Fax: (370-5) ,
VRT012 User s gude V0.1 Thank you for purchasng our product. We hope ths user-frendly devce wll be helpful n realsng your deas and brngng comfort to your lfe. Please take few mnutes to read ths manual
More informationFrom zero to Matlab in six weeks
From zero to Matlab n sx weeks Frederk J Smons Adam C. Maloof Prnceton Unversty Explan the bascs I 1. help 2. lookfor 3. type 4. who, whos, whch 7. dary Explan the bascs II 7. plot 8. xlabel, ylabel, ttle
More informationLecture #15 Lecture Notes
Lecture #15 Lecture Notes The ocean water column s very much a 3-D spatal entt and we need to represent that structure n an economcal way to deal wth t n calculatons. We wll dscuss one way to do so, emprcal
More informationBITPLANE AG IMARISCOLOC. Operating Instructions. Manual Version 1.0 January the image revolution starts here.
BITPLANE AG IMARISCOLOC Operatng Instructons Manual Verson 1.0 January 2003 the mage revoluton starts here. Operatng Instructons BITPLANE AG Copyrght Ths document contans propretary nformaton protected
More informationA DATA ANALYSIS CODE FOR MCNP MESH AND STANDARD TALLIES
Supercomputng n uclear Applcatons (M&C + SA 007) Monterey, Calforna, Aprl 15-19, 007, on CD-ROM, Amercan uclear Socety, LaGrange Par, IL (007) A DATA AALYSIS CODE FOR MCP MESH AD STADARD TALLIES Kenneth
More informationSLAM Summer School 2006 Practical 2: SLAM using Monocular Vision
SLAM Summer School 2006 Practcal 2: SLAM usng Monocular Vson Javer Cvera, Unversty of Zaragoza Andrew J. Davson, Imperal College London J.M.M Montel, Unversty of Zaragoza. josemar@unzar.es, jcvera@unzar.es,
More informationPBRT core. Announcements. pbrt. pbrt plug-ins
Announcements PBRT core Dgtal Image Synthess Yung-Yu Chuang 9/27/2007 Please subscrbe the malng lst. Wndows complaton Debuggng n Wndows Doxygen (onlne, download or doxygen by yourself) HW#1 wll be assgned
More informationSorting: 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 informationsuch that is accepted of states in , where Finite Automata Lecture 2-1: Regular Languages be an FA. A string is the transition function,
* Lecture - Regular Languages S Lecture - Fnte Automata where A fnte automaton s a -tuple s a fnte set called the states s a fnte set called the alphabet s the transton functon s the ntal state s the set
More informationSorting 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 informationFuzzy C-Means Initialized by Fixed Threshold Clustering for Improving Image Retrieval
Fuzzy -Means Intalzed by Fxed Threshold lusterng for Improvng Image Retreval NAWARA HANSIRI, SIRIPORN SUPRATID,HOM KIMPAN 3 Faculty of Informaton Technology Rangst Unversty Muang-Ake, Paholyotn Road, Patumtan,
More information