Advanced Algorithmic Problem Solving Le 3 Arithmetic. Fredrik Heintz Dept of Computer and Information Science Linköping University

Size: px
Start display at page:

Download "Advanced Algorithmic Problem Solving Le 3 Arithmetic. Fredrik Heintz Dept of Computer and Information Science Linköping University"

Transcription

1 Advced Algorthmc Prolem Solvg Le Arthmetc Fredrk Hetz Dept of Computer d Iformto Scece Lköpg Uversty

2 Overvew Arthmetc Iteger multplcto Krtsu s lgorthm Multplcto of polyomls Fst Fourer Trsform Systems of ler equtos Nïve Guss Elmto

3 Arthmetc Rge of defult teger dt types (C++) usged t = usged log: (9 dgts) usged log log: (9 dgts) How to represet 777! Opertos o Bg Iteger Bsc: dd, sutrct, multply, dvde, etc Use hgh school method

4 Arthmetc Gretest Commo Dvsor (Euclde Algorthm) GCD(, ) = GCD(, ) = GCD(, mod ) t gcd(t, t ) { retur ( ==? : gcd(, % )); } Lest Commo Multpler LCM(, ) = * / GCD(, ) t lcm(t, t ) { retur ( / gcd(, ) * ); } // Q: why we wrte the lcm code ths wy? GCD/LCM of more th umers: GCD(,, c) = GCD(, GCD(, c)) Fd d,, y such tht d = + y d d = GCD(,) (Eteded Euclde Algorthm) EGCD(,) = (,,) EGCD(,) (d,,y ) = EGCD(, mod ) (d,,y) = (d,y, /*y )

5 Arthmetc 5 Represetg rtol umers. Prs of tegers, where GCD(,)=. Represetg rtol umers modulo m. The oly dffcult operto s verse, = (mod m), where verse ests f d oly f d m re co-prme (gcd(,m)=). C e foud usg the Eteded Euclde Algorthm = (mod m) => = qm => qm = (d,, y) = EGCD(,m) => s the soluto ff d =.

6 Krtsu s lgorthm Usg the clsscl pe d pper lgorthm two dgt tegers c e multpled O( ) opertos. Krtsu cme up wth fster lgorthm. Let A d B e two tegers wth A = A k + A, A < k B = B k + B, B < k C = A*B = (A k + A )(B k + B ) = A B k + (A B + A B ) k + A B Isted ths c e computed wth multplctos T = A B T = (A + A )(B + B ) T = A B C = T k + (T - T - T ) k + T

7 Complety of Krtsu s Algorthm 7 Let T() e the tme to compute the product of two -dgt umers usg Krtsu s lgorthm. Assume = k. T() = ( lg() ), lg().58 T() T(/) + c (T(/) + c(/)) + c = T(/ ) + c(/ + ) (T(/ ) + c(/)) + c(/ + ) = T(/ ) + c( / + / + ) T(/ ) + c( - / / + )... c k + c[((/) k - )/(/ -)] --- Assumg T() c c k + c( k - k ) c lg() = c lg()

8 Fst Fourer Trsform 8 See seprte presetto

9 9 Systems of Ler Equtos Mtr form Stdrd form dfferet forms c epreseted ler equtos A system of

10 Solutos of Ler Equtos s 5 soluto to the followg equtos :

11 Solutos of Ler Equtos A set of equtos s cosstet f there ests o soluto to the system of equtos: 5 These equtos re cosstet

12 Solutos of Ler Equtos Some systems of equtos my hve fte umer of solutos hve fte.5( umer of ) s solutos soluto for ll

13 Grphcl Soluto of Systems of Ler Equtos 5 Soluto =, =

14 Crmer s Rule s Not Prctcl Crmer' s Rule c e used to solve 5, 5 the system Crmer' s Rule s ot prctcl for lrge systems. To solve N y N system requres (N )(N -)N! multplctos. To solve y system,.8 multplctos re eeded. It c eused f the determts re computed effcet wy 5

15 5 Nve Guss Elmto The method cossts of two steps: Forwrd Elmto: the system s reduced to upper trgulr form. A sequece of elemetry opertos s used. Bckwrd Susttuto: Solve the system strtg from the lst vrle. ' ' ' ' '

16 Elemetry Row Opertos Addg multple of oe row to other Multply y row y o-zero costt

17 7 Emple: Forwrd Elmto 8 7 8,, from equtos Elmte Step: Forwrd Elmto : Prt

18 8 Emple: Forwrd Elmto 9 5 from equto Elmte Step : 9 5, from equtos Elmte Step :

19 9 Emple: Forwrd Elmto Elmto : the Forwrd Summry of

20 Emple: Bckwrd Susttuto () ) ( (), () ) ( 5 9, for,...solve for the solve, for Solve 9 5

21 Forwrd Elmto j j j j j j j j ) ( To elmte ) ( To elmte

22 Forwrd Elmto s elmted. Cotue utl ) ( To elmte k kk k kj kk k j j k k j k

23 Bckwrd Susttuto j j j,,,,,,,,

24 Determt The elemetry opertos do ot ffect the determt Emple : Elemetry opertos A A' det (A) det (A')

25 How My Solutos Does System of Equtos AX=B Hve? 5 Uque det(a) reduced mtr hs o zero rows No soluto det(a) reduced mtr hs oe or more zero rows correspodg B elemets Ifte det(a) reduced mtr hs oe or more zero rows correspodg B elemets

26 Emples.5!.5 # : solutos # of fte No soluto Uque X mpossle X solutos Ifte No soluto soluto X X X X X X

27 Pseudo-Code: Forwrd Elmto 7 do k = to - do = k+ to fctor =,k / k,k do j = k+ to ed do,j =,j fctor * k,j = fctor * k ed do ed do

28 Pseudo-Code: Bck Susttuto 8 = /, do = - dowto sum = do j = + to sum = sum,j * j ed do = sum /, ed do

29 9 Prolems wth Nve Guss Elmto o The Nve Guss Elmto my fl for very smple cses. (The pvotg elemet s zero). o Very smll pvotg elemet my result serous computto errors

30 How Do We Kow If Soluto s Good or Not Gve AX=B X s soluto f AX-B= Compute the resdul vector R= AX-B Due to roudg error, R my ot e zero The soluto s cceptle f m r

31 How Good s the Soluto?....5 Resdues : R soluto

32 Summry Arthmetc Iteger multplcto Krtsu s lgorthm Multplcto of polyomls Fst Fourer Trsform Systems of ler equtos Nïve Guss Elmto

Lecture 3-4 Solutions of System of Linear Equations

Lecture 3-4 Solutions of System of Linear Equations Lecture - Solutos of System of Ler Equtos Numerc Ler Alger Revew of vectorsd mtrces System of Ler Equtos Guss Elmto (drect solver) LU Decomposto Guss-Sedel method (tertve solver) VECTORS,,, colum vector

More information

Advanced Algorithmic Problem Solving Le 6 Math and Search

Advanced Algorithmic Problem Solving Le 6 Math and Search Advced Algorithmic Prolem Solvig Le Mth d Serch Fredrik Heitz Dept of Computer d Iformtio Sciece Liköpig Uiversity Outlie Arithmetic (l. d.) Solvig lier equtio systems (l. d.) Chiese remider theorem (l.5

More information

SOLVING SYSTEMS OF EQUATIONS, DIRECT METHODS

SOLVING SYSTEMS OF EQUATIONS, DIRECT METHODS ELM Numecl Alyss D Muhem Mecmek SOLVING SYSTEMS OF EQUATIONS DIRECT METHODS ELM Numecl Alyss Some of the cotets e dopted fom Luee V. Fusett Appled Numecl Alyss usg MATLAB. Petce Hll Ic. 999 ELM Numecl

More information

Chapter Gauss-Seidel Method

Chapter Gauss-Seidel Method Chpter 04.08 Guss-Sedel Method After redg ths hpter, you should be ble to:. solve set of equtos usg the Guss-Sedel method,. reogze the dvtges d ptflls of the Guss-Sedel method, d. determe uder wht odtos

More information

ITERATIVE METHODS FOR SOLVING SYSTEMS OF LINEAR ALGEBRAIC EQUATIONS

ITERATIVE METHODS FOR SOLVING SYSTEMS OF LINEAR ALGEBRAIC EQUATIONS Numercl Alyss for Egeers Germ Jord Uversty ITERATIVE METHODS FOR SOLVING SYSTEMS OF LINEAR ALGEBRAIC EQUATIONS Numercl soluto of lrge systems of ler lgerc equtos usg drect methods such s Mtr Iverse, Guss

More information

Computer Programming

Computer Programming Computer Progrmmg I progrmmg, t s ot eough to be vetve d geous. Oe lso eeds to be dscpled d cotrolled order ot be become etgled oe's ow completes. Hrl D. Mlls, Forwrd to Progrmmg Proverbs b Her F. Ledgrd

More information

CS537. Numerical Analysis

CS537. Numerical Analysis CS57 Numercl Alyss Lecture 4 System of Ler Equtos Professor Ju Zhg Deprtmet of Computer Scece Uversty of Ketucky Legto, KY 456 6 Ferury, 6 System of Ler Equtos where j re coeffcets, re ukows, d re rght

More information

The z-transform. LTI System description. Prof. Siripong Potisuk

The z-transform. LTI System description. Prof. Siripong Potisuk The -Trsform Prof. Srpog Potsuk LTI System descrpto Prevous bss fucto: ut smple or DT mpulse The put sequece s represeted s ler combto of shfted DT mpulses. The respose s gve by covoluto sum of the put

More information

ME 501A Seminar in Engineering Analysis Page 1

ME 501A Seminar in Engineering Analysis Page 1 Mtr Trsformtos usg Egevectors September 8, Mtr Trsformtos Usg Egevectors Lrry Cretto Mechcl Egeerg A Semr Egeerg Alyss September 8, Outle Revew lst lecture Trsformtos wth mtr of egevectors: = - A ermt

More information

Sequences and summations

Sequences and summations Lecture 0 Sequeces d summtos Istructor: Kgl Km CSE) E-ml: kkm0@kokuk.c.kr Tel. : 0-0-9 Room : New Mleum Bldg. 0 Lb : New Egeerg Bldg. 0 All sldes re bsed o CS Dscrete Mthemtcs for Computer Scece course

More information

CS473-Algorithms I. Lecture 3. Solving Recurrences. Cevdet Aykanat - Bilkent University Computer Engineering Department

CS473-Algorithms I. Lecture 3. Solving Recurrences. Cevdet Aykanat - Bilkent University Computer Engineering Department CS473-Algorthms I Lecture 3 Solvg Recurreces Cevdet Aykt - Blket Uversty Computer Egeerg Deprtmet Solvg Recurreces The lyss of merge sort Lecture requred us to solve recurrece. Recurreces re lke solvg

More information

ICS141: Discrete Mathematics for Computer Science I

ICS141: Discrete Mathematics for Computer Science I Uversty o Hw ICS: Dscrete Mthemtcs or Computer Scece I Dept. Iormto & Computer Sc., Uversty o Hw J Stelovsy bsed o sldes by Dr. Be d Dr. Stll Orgls by Dr. M. P. Fr d Dr. J.L. Gross Provded by McGrw-Hll

More information

Chapter Unary Matrix Operations

Chapter Unary Matrix Operations Chpter 04.04 Ury trx Opertos After redg ths chpter, you should be ble to:. kow wht ury opertos mes,. fd the trspose of squre mtrx d t s reltoshp to symmetrc mtrces,. fd the trce of mtrx, d 4. fd the ermt

More information

Level-2 BLAS. Matrix-Vector operations with O(n 2 ) operations (sequentially) BLAS-Notation: S --- single precision G E general matrix M V --- vector

Level-2 BLAS. Matrix-Vector operations with O(n 2 ) operations (sequentially) BLAS-Notation: S --- single precision G E general matrix M V --- vector evel-2 BS trx-vector opertos wth 2 opertos sequetlly BS-Notto: S --- sgle precso G E geerl mtrx V --- vector defes SGEV, mtrx-vector product: r y r α x β r y ther evel-2 BS: Solvg trgulr system x wth trgulr

More information

CS321. Introduction to Numerical Methods

CS321. Introduction to Numerical Methods CS Itroducto to Numercl Metods Lecture Revew Proessor Ju Zg Deprtmet o Computer Scece Uversty o Ketucky Legto, KY 6 6 Mrc 7, Number Coverso A geerl umber sould be coverted teger prt d rctol prt seprtely

More information

Numerical Analysis Topic 4: Least Squares Curve Fitting

Numerical Analysis Topic 4: Least Squares Curve Fitting Numerl Alss Top 4: Lest Squres Curve Fttg Red Chpter 7 of the tetook Alss_Numerk Motvto Gve set of epermetl dt: 3 5. 5.9 6.3 The reltoshp etwee d m ot e ler. Fd futo f tht est ft the dt 3 Alss_Numerk Motvto

More information

DATA FITTING. Intensive Computation 2013/2014. Annalisa Massini

DATA FITTING. Intensive Computation 2013/2014. Annalisa Massini DATA FITTING Itesve Computto 3/4 Als Mss Dt fttg Dt fttg cocers the problem of fttg dscrete dt to obt termedte estmtes. There re two geerl pproches two curve fttg: Iterpolto Dt s ver precse. The strteg

More information

MATH 371 Homework assignment 1 August 29, 2013

MATH 371 Homework assignment 1 August 29, 2013 MATH 371 Homework assgmet 1 August 29, 2013 1. Prove that f a subset S Z has a smallest elemet the t s uque ( other words, f x s a smallest elemet of S ad y s also a smallest elemet of S the x y). We kow

More information

POWERS OF COMPLEX PERSYMMETRIC ANTI-TRIDIAGONAL MATRICES WITH CONSTANT ANTI-DIAGONALS

POWERS OF COMPLEX PERSYMMETRIC ANTI-TRIDIAGONAL MATRICES WITH CONSTANT ANTI-DIAGONALS IRRS 9 y 04 wwwrppresscom/volumes/vol9issue/irrs_9 05pdf OWERS OF COLE ERSERIC I-RIIGOL RICES WIH COS I-IGOLS Wg usu * Q e Wg Hbo & ue College of Scece versty of Shgh for Scece d echology Shgh Ch 00093

More information

PubH 7405: REGRESSION ANALYSIS REGRESSION IN MATRIX TERMS

PubH 7405: REGRESSION ANALYSIS REGRESSION IN MATRIX TERMS PubH 745: REGRESSION ANALSIS REGRESSION IN MATRIX TERMS A mtr s dspl of umbers or umercl quttes ld out rectgulr rr of rows d colums. The rr, or two-w tble of umbers, could be rectgulr or squre could be

More information

Patterns of Continued Fractions with a Positive Integer as a Gap

Patterns of Continued Fractions with a Positive Integer as a Gap IOSR Jourl of Mthemtcs (IOSR-JM) e-issn: 78-578, -ISSN: 39-765X Volume, Issue 3 Ver III (My - Ju 6), PP -5 wwwosrjourlsorg Ptters of Cotued Frctos wth Postve Iteger s G A Gm, S Krth (Mthemtcs, Govermet

More information

means the first term, a2 means the term, etc. Infinite Sequences: follow the same pattern forever.

means the first term, a2 means the term, etc. Infinite Sequences: follow the same pattern forever. 9.4 Sequeces ad Seres Pre Calculus 9.4 SEQUENCES AND SERIES Learg Targets:. Wrte the terms of a explctly defed sequece.. Wrte the terms of a recursvely defed sequece. 3. Determe whether a sequece s arthmetc,

More information

Preliminary Examinations: Upper V Mathematics Paper 1

Preliminary Examinations: Upper V Mathematics Paper 1 relmr Emtos: Upper V Mthemtcs per Jul 03 Emer: G Evs Tme: 3 hrs Modertor: D Grgortos Mrks: 50 INSTRUCTIONS ND INFORMTION Ths questo pper sts of 0 pges, cludg swer Sheet pge 8 d Iformto Sheet pges 9 d 0

More information

CHAPTER 4 RADICAL EXPRESSIONS

CHAPTER 4 RADICAL EXPRESSIONS 6 CHAPTER RADICAL EXPRESSIONS. The th Root of a Real Number A real umber a s called the th root of a real umber b f Thus, for example: s a square root of sce. s also a square root of sce ( ). s a cube

More information

Answer: First, I ll show how to find the terms analytically then I ll show how to use the TI to find them.

Answer: First, I ll show how to find the terms analytically then I ll show how to use the TI to find them. . CHAPTER 0 SEQUENCE, SERIES, d INDUCTION Secto 0. Seqece A lst of mers specfc order. E / Fd the frst terms : of the gve seqece: Aswer: Frst, I ll show how to fd the terms ltcll the I ll show how to se

More information

Chapter 2 Intro to Math Techniques for Quantum Mechanics

Chapter 2 Intro to Math Techniques for Quantum Mechanics Wter 3 Chem 356: Itroductory Qutum Mechcs Chpter Itro to Mth Techques for Qutum Mechcs... Itro to dfferetl equtos... Boudry Codtos... 5 Prtl dfferetl equtos d seprto of vrbles... 5 Itroducto to Sttstcs...

More information

Stats & Summary

Stats & Summary Stts 443.3 & 85.3 Summr The Woodbur Theorem BCD B C D B D where the verses C C D B, d est. Block Mtrces Let the m mtr m q q m be rttoed to sub-mtrces,,,, Smlrl rtto the m k mtr B B B mk m B B l kl Product

More information

Mu Sequences/Series Solutions National Convention 2014

Mu Sequences/Series Solutions National Convention 2014 Mu Sequeces/Seres Solutos Natoal Coveto 04 C 6 E A 6C A 6 B B 7 A D 7 D C 7 A B 8 A B 8 A C 8 E 4 B 9 B 4 E 9 B 4 C 9 E C 0 A A 0 D B 0 C C Usg basc propertes of arthmetc sequeces, we fd a ad bm m We eed

More information

Polynomial Encryption Using The Subset Problem Based On Elgamal. Raipur, Chhattisgarh , India. Raipur, Chhattisgarh , India.

Polynomial Encryption Using The Subset Problem Based On Elgamal. Raipur, Chhattisgarh , India. Raipur, Chhattisgarh , India. Polyomal Ecrypto Usg The Subset Problem Based O Elgamal Khushboo Thakur 1, B. P. Trpath 2 1 School of Studes Mathematcs Pt. Ravshakar Shukla Uversty Rapur, Chhattsgarh 92001, Ida. 2 Departmet of Mathematcs,

More information

Matrix. Definition 1... a1 ... (i) where a. are real numbers. for i 1, 2,, m and j = 1, 2,, n (iii) A is called a square matrix if m n.

Matrix. Definition 1... a1 ... (i) where a. are real numbers. for i 1, 2,, m and j = 1, 2,, n (iii) A is called a square matrix if m n. Mtrx Defto () s lled order of m mtrx, umer of rows ( 橫行 ) umer of olums ( 直列 ) m m m where j re rel umers () B j j for,,, m d j =,,, () s lled squre mtrx f m (v) s lled zero mtrx f (v) s lled detty mtrx

More information

Analytical Approach for the Solution of Thermodynamic Identities with Relativistic General Equation of State in a Mixture of Gases

Analytical Approach for the Solution of Thermodynamic Identities with Relativistic General Equation of State in a Mixture of Gases Itertol Jourl of Advced Reserch Physcl Scece (IJARPS) Volume, Issue 5, September 204, PP 6-0 ISSN 2349-7874 (Prt) & ISSN 2349-7882 (Ole) www.rcourls.org Alytcl Approch for the Soluto of Thermodymc Idettes

More information

12 Iterative Methods. Linear Systems: Gauss-Seidel Nonlinear Systems Case Study: Chemical Reactions

12 Iterative Methods. Linear Systems: Gauss-Seidel Nonlinear Systems Case Study: Chemical Reactions HK Km Slghtly moded //9 /8/6 Frstly wrtte t Mrch 5 Itertve Methods er Systems: Guss-Sedel Noler Systems Cse Study: Chemcl Rectos Itertve or ppromte methods or systems o equtos cosst o guessg vlue d the

More information

Mathematically, integration is just finding the area under a curve from one point to another. It is b

Mathematically, integration is just finding the area under a curve from one point to another. It is b Numerl Metods or Eg [ENGR 9] [Lyes KADEM 7] CHAPTER VI Numerl Itegrto Tops - Rem sums - Trpezodl rule - Smpso s rule - Rrdso s etrpolto - Guss qudrture rule Mtemtlly, tegrto s just dg te re uder urve rom

More information

Algorithms Design & Analysis. Hash Tables

Algorithms Design & Analysis. Hash Tables Algorthms Desg & Aalyss Hash Tables Recap Lower boud Order statstcs 2 Today s topcs Drect-accessble table Hash tables Hash fuctos Uversal hashg Perfect Hashg Ope addressg 3 Symbol-table problem Symbol

More information

Rendering Equation. Linear equation Spatial homogeneous Both ray tracing and radiosity can be considered special case of this general eq.

Rendering Equation. Linear equation Spatial homogeneous Both ray tracing and radiosity can be considered special case of this general eq. Rederg quto Ler equto Sptl homogeeous oth ry trcg d rdosty c be cosdered specl cse of ths geerl eq. Relty ctul photogrph Rdosty Mus Rdosty Rederg quls the dfferece or error mge http://www.grphcs.corell.edu/ole/box/compre.html

More information

SUM PROPERTIES FOR THE K-LUCAS NUMBERS WITH ARITHMETIC INDEXES

SUM PROPERTIES FOR THE K-LUCAS NUMBERS WITH ARITHMETIC INDEXES Avlble ole t http://sc.org J. Mth. Comput. Sc. 4 (04) No. 05-7 ISSN: 97-507 SUM PROPERTIES OR THE K-UCAS NUMBERS WITH ARITHMETIC INDEXES BIJENDRA SINGH POOJA BHADOURIA AND OMPRAKASH SIKHWA * School of

More information

ICS141: Discrete Mathematics for Computer Science I

ICS141: Discrete Mathematics for Computer Science I ICS4: Discrete Mthemtics for Computer Sciece I Dept. Iformtio & Computer Sci., J Stelovsky sed o slides y Dr. Bek d Dr. Still Origils y Dr. M. P. Frk d Dr. J.L. Gross Provided y McGrw-Hill 3- Quiz. gcd(84,96).

More information

this is the indefinite integral Since integration is the reverse of differentiation we can check the previous by [ ]

this is the indefinite integral Since integration is the reverse of differentiation we can check the previous by [ ] Atervtves The Itegrl Atervtves Ojectve: Use efte tegrl otto for tervtves. Use sc tegrto rules to f tervtves. Aother mportt questo clculus s gve ervtve f the fucto tht t cme from. Ths s the process kow

More information

3/20/2013. Splines There are cases where polynomial interpolation is bad overshoot oscillations. Examplef x. Interpolation at -4,-3,-2,-1,0,1,2,3,4

3/20/2013. Splines There are cases where polynomial interpolation is bad overshoot oscillations. Examplef x. Interpolation at -4,-3,-2,-1,0,1,2,3,4 // Sples There re ses where polyoml terpolto s d overshoot oslltos Emple l s Iterpolto t -,-,-,-,,,,,.... - - - Ide ehd sples use lower order polyomls to oet susets o dt pots mke oetos etwee djet sples

More information

Optimality of Strategies for Collapsing Expanded Random Variables In a Simple Random Sample Ed Stanek

Optimality of Strategies for Collapsing Expanded Random Variables In a Simple Random Sample Ed Stanek Optmlt of Strteges for Collpsg Expe Rom Vrles Smple Rom Smple E Stek troucto We revew the propertes of prectors of ler comtos of rom vrles se o rom vrles su-spce of the orgl rom vrles prtculr, we ttempt

More information

Algorithms Theory, Solution for Assignment 2

Algorithms Theory, Solution for Assignment 2 Juor-Prof. Dr. Robert Elsässer, Marco Muñz, Phllp Hedegger WS 2009/200 Algorthms Theory, Soluto for Assgmet 2 http://lak.formatk.u-freburg.de/lak_teachg/ws09_0/algo090.php Exercse 2. - Fast Fourer Trasform

More information

Area and the Definite Integral. Area under Curve. The Partition. y f (x) We want to find the area under f (x) on [ a, b ]

Area and the Definite Integral. Area under Curve. The Partition. y f (x) We want to find the area under f (x) on [ a, b ] Are d the Defte Itegrl 1 Are uder Curve We wt to fd the re uder f (x) o [, ] y f (x) x The Prtto We eg y prttog the tervl [, ] to smller su-tervls x 0 x 1 x x - x -1 x 1 The Bsc Ide We the crete rectgles

More information

MA/CSSE 473 Day 27. Dynamic programming

MA/CSSE 473 Day 27. Dynamic programming MA/CSSE 473 Day 7 Dyamc Programmg Bomal Coeffcets Warshall's algorthm (Optmal BSTs) Studet questos? Dyamc programmg Used for problems wth recursve solutos ad overlappg subproblems Typcally, we save (memoze)

More information

The internal structure of natural numbers, one method for the definition of large prime numbers, and a factorization test

The internal structure of natural numbers, one method for the definition of large prime numbers, and a factorization test Fal verso The teral structure of atural umbers oe method for the defto of large prme umbers ad a factorzato test Emmaul Maousos APM Isttute for the Advacemet of Physcs ad Mathematcs 3 Poulou str. 53 Athes

More information

Evaluating Polynomials

Evaluating Polynomials Uverst of Nebraska - Lcol DgtalCommos@Uverst of Nebraska - Lcol MAT Exam Expostor Papers Math the Mddle Isttute Partershp 7-7 Evaluatg Polomals Thomas J. Harrgto Uverst of Nebraska-Lcol Follow ths ad addtoal

More information

Methods to Invert a Matrix

Methods to Invert a Matrix Lecture 3: Determts & trx Iverso ethods to Ivert trx The pproches vlble to fd the verse of mtrx re extesve d dverse. ll methods seek to solve ler system of equtos tht c be expressed mtrx formt s for the

More information

Chapter 2 Solving Linear Equation

Chapter 2 Solving Linear Equation EE7 Computer odelg Techques Egeerg Chpter Solvg er Equto A ler equto represets the ler depedece of qutty φ o set of vrbles through d set of costt coeffcets α through α ; ts form s α α... α φ If we replce

More information

MTH 146 Class 7 Notes

MTH 146 Class 7 Notes 7.7- Approxmte Itegrto Motvto: MTH 46 Clss 7 Notes I secto 7.5 we lered tht some defte tegrls, lke x e dx, cot e wrtte terms of elemetry fuctos. So, good questo to sk would e: How c oe clculte somethg

More information

i+1 by A and imposes Ax

i+1 by A and imposes Ax MASSACHUSETTS INSTITUTE OF TECHNOLOGY DEPARTMENT OF MECHANICAL ENGINEERING CAMBRIDGE, MASSACHUSETTS 09.9 NUMERICAL FLUID MECHANICS FALL 009 Mody, October 9, 009 QUIZ : SOLUTIONS Notes: ) Multple solutos

More information

14.2 Line Integrals. determines a partition P of the curve by points Pi ( xi, y

14.2 Line Integrals. determines a partition P of the curve by points Pi ( xi, y 4. Le Itegrls I ths secto we defe tegrl tht s smlr to sgle tegrl except tht sted of tegrtg over tervl [ ] we tegrte over curve. Such tegrls re clled le tegrls lthough curve tegrls would e etter termology.

More information

Math 1313 Final Exam Review

Math 1313 Final Exam Review Mth 33 Fl m Revew. The e Compy stlled ew mhe oe of ts ftores t ost of $0,000. The mhe s depreted lerly over 0 yers wth srp vlue of $,000. Fd the vlue of the mhe fter 5 yers.. mufturer hs mothly fed ost

More information

1. A real number x is represented approximately by , and we are told that the relative error is 0.1 %. What is x? Note: There are two answers.

1. A real number x is represented approximately by , and we are told that the relative error is 0.1 %. What is x? Note: There are two answers. PROBLEMS A real umber s represeted appromately by 63, ad we are told that the relatve error s % What s? Note: There are two aswers Ht : Recall that % relatve error s What s the relatve error volved roudg

More information

Computations with large numbers

Computations with large numbers Comutatos wth large umbers Wehu Hog, Det. of Math, Clayto State Uversty, 2 Clayto State lvd, Morrow, G 326, Mgshe Wu, Det. of Mathematcs, Statstcs, ad Comuter Scece, Uversty of Wscos-Stout, Meomoe, WI

More information

INTRODUCTION ( ) 1. Errors

INTRODUCTION ( ) 1. Errors INTRODUCTION Numercl lyss volves the study, developmet d lyss of lgorthms for obtg umercl solutos to vrous mthemtcl problems. Frequetly umercl lyss s clled the mthemtcs of scetfc computg. Numercl lyss

More information

St John s College. UPPER V Mathematics: Paper 1 Learning Outcome 1 and 2. Examiner: GE Marks: 150 Moderator: BT / SLS INSTRUCTIONS AND INFORMATION

St John s College. UPPER V Mathematics: Paper 1 Learning Outcome 1 and 2. Examiner: GE Marks: 150 Moderator: BT / SLS INSTRUCTIONS AND INFORMATION St Joh s College UPPER V Mthemtcs: Pper Lerg Outcome d ugust 00 Tme: 3 hours Emer: GE Mrks: 50 Modertor: BT / SLS INSTRUCTIONS ND INFORMTION Red the followg structos crefull. Ths questo pper cossts of

More information

Density estimation II

Density estimation II CS 750 Mche Lerg Lecture 6 esty estmto II Mlos Husrecht mlos@tt.edu 539 Seott Squre t: esty estmto {.. } vector of ttrute vlues Ojectve: estmte the model of the uderlyg rolty dstruto over vrles X X usg

More information

COMPLEX NUMBERS AND DE MOIVRE S THEOREM

COMPLEX NUMBERS AND DE MOIVRE S THEOREM COMPLEX NUMBERS AND DE MOIVRE S THEOREM OBJECTIVE PROBLEMS. s equl to b d. 9 9 b 9 9 d. The mgr prt of s 5 5 b 5. If m, the the lest tegrl vlue of m s b 8 5. The vlue of 5... s f s eve, f s odd b f s eve,

More information

Review of Linear Algebra

Review of Linear Algebra PGE 30: Forulto d Soluto Geosstes Egeerg Dr. Blhoff Sprg 0 Revew of Ler Alger Chpter 7 of Nuercl Methods wth MATLAB, Gerld Recktewld Vector s ordered set of rel (or cople) uers rrged s row or colu sclr

More information

Lecture 3: Review of Linear Algebra and MATLAB

Lecture 3: Review of Linear Algebra and MATLAB eture 3: Revew of er Aler AAB Vetor mtr otto Vetors tres Vetor spes er trsformtos Eevlues eevetors AAB prmer Itrouto to Ptter Reoto Rro Guterrez-su Wrht Stte Uverst Vetor mtr otto A -mesol (olum) vetor

More information

GRAPHING LINEAR EQUATIONS. Linear Equations. x l ( 3,1 ) _x-axis. Origin ( 0, 0 ) Slope = change in y change in x. Equation for l 1.

GRAPHING LINEAR EQUATIONS. Linear Equations. x l ( 3,1 ) _x-axis. Origin ( 0, 0 ) Slope = change in y change in x. Equation for l 1. GRAPHING LINEAR EQUATIONS Qudrt II Qudrt I ORDERED PAIR: The first umer i the ordered pir is the -coordite d the secod umer i the ordered pir is the y-coordite. (, ) Origi ( 0, 0 ) _-is Lier Equtios Qudrt

More information

CURVE FITTING LEAST SQUARES METHOD

CURVE FITTING LEAST SQUARES METHOD Nuercl Alss for Egeers Ger Jord Uverst CURVE FITTING Although, the for of fucto represetg phscl sste s kow, the fucto tself ot be kow. Therefore, t s frequetl desred to ft curve to set of dt pots the ssued

More information

1 4 6 is symmetric 3 SPECIAL MATRICES 3.1 SYMMETRIC MATRICES. Defn: A matrix A is symmetric if and only if A = A, i.e., a ij =a ji i, j. Example 3.1.

1 4 6 is symmetric 3 SPECIAL MATRICES 3.1 SYMMETRIC MATRICES. Defn: A matrix A is symmetric if and only if A = A, i.e., a ij =a ji i, j. Example 3.1. SPECIAL MATRICES SYMMETRIC MATRICES Def: A mtr A s symmetr f d oly f A A, e,, Emple A s symmetr Def: A mtr A s skew symmetr f d oly f A A, e,, Emple A s skew symmetr Remrks: If A s symmetr or skew symmetr,

More information

PGE 310: Formulation and Solution in Geosystems Engineering. Dr. Balhoff. Interpolation

PGE 310: Formulation and Solution in Geosystems Engineering. Dr. Balhoff. Interpolation PGE 30: Formulato ad Soluto Geosystems Egeerg Dr. Balhoff Iterpolato Numercal Methods wth MATLAB, Recktewald, Chapter 0 ad Numercal Methods for Egeers, Chapra ad Caale, 5 th Ed., Part Fve, Chapter 8 ad

More information

PTAS for Bin-Packing

PTAS for Bin-Packing CS 663: Patter Matchg Algorthms Scrbe: Che Jag /9/00. Itroducto PTAS for B-Packg The B-Packg problem s NP-hard. If we use approxmato algorthms, the B-Packg problem could be solved polyomal tme. For example,

More information

Autar Kaw Benjamin Rigsby. Transforming Numerical Methods Education for STEM Undergraduates

Autar Kaw Benjamin Rigsby.   Transforming Numerical Methods Education for STEM Undergraduates Autr Kw Bejmi Rigsby http://m.mthforcollege.com Trsformig Numericl Methods Eductio for STEM Udergrdutes http://m.mthforcollege.com . solve set of simulteous lier equtios usig Nïve Guss elimitio,. ler the

More information

1 0, x? x x. 1 Root finding. 1.1 Introduction. Solve[x^2-1 0,x] {{x -1},{x 1}} Plot[x^2-1,{x,-2,2}] 3

1 0, x? x x. 1 Root finding. 1.1 Introduction. Solve[x^2-1 0,x] {{x -1},{x 1}} Plot[x^2-1,{x,-2,2}] 3 Adrew Powuk - http://www.powuk.com- Math 49 (Numercal Aalyss) Root fdg. Itroducto f ( ),?,? Solve[^-,] {{-},{}} Plot[^-,{,-,}] Cubc equato https://e.wkpeda.org/wk/cubc_fucto Quartc equato https://e.wkpeda.org/wk/quartc_fucto

More information

4 Linear Homogeneous Recurrence Relation 4-1 Fibonacci Rabbits. 组合数学 Combinatorics

4 Linear Homogeneous Recurrence Relation 4-1 Fibonacci Rabbits. 组合数学 Combinatorics 4 Ler Homogeeous Recurrece Relto 4- bocc Rbbts 组合数学 ombtorcs The delt of the th moth d - th moth s gve brth by the rbbts - moth. o = - + - Moth Moth Moth Moth 4 I the frst moth there s pr of ewly-bor rbbts;

More information

An Alternative Method to Find the Solution of Zero One Integer Linear Fractional Programming Problem with the Help of -Matrix

An Alternative Method to Find the Solution of Zero One Integer Linear Fractional Programming Problem with the Help of -Matrix Itertol Jourl of Scetfc d Reserch Pulctos, Volue 3, Issue 6, Jue 3 ISSN 5-353 A Altertve Method to Fd the Soluto of Zero Oe Iteger Ler Frctol Progrg Prole wth the Help of -Mtr VSeeregsy *, DrKJeyr ** *

More information

MATRIX AND VECTOR NORMS

MATRIX AND VECTOR NORMS Numercl lyss for Egeers Germ Jord Uversty MTRIX ND VECTOR NORMS vector orm s mesure of the mgtude of vector. Smlrly, mtr orm s mesure of the mgtude of mtr. For sgle comoet etty such s ordry umers, the

More information

A Technique for Constructing Odd-order Magic Squares Using Basic Latin Squares

A Technique for Constructing Odd-order Magic Squares Using Basic Latin Squares Itertol Jourl of Scetfc d Reserch Publctos, Volume, Issue, My 0 ISSN 0- A Techque for Costructg Odd-order Mgc Squres Usg Bsc Lt Squres Tomb I. Deprtmet of Mthemtcs, Mpur Uversty, Imphl, Mpur (INDIA) tombrom@gml.com

More information

EECE 301 Signals & Systems

EECE 301 Signals & Systems EECE 01 Sgals & Systems Prof. Mark Fowler Note Set #9 Computg D-T Covoluto Readg Assgmet: Secto. of Kame ad Heck 1/ Course Flow Dagram The arrows here show coceptual flow betwee deas. Note the parallel

More information

F. Inequalities. HKAL Pure Mathematics. 進佳數學團隊 Dr. Herbert Lam 林康榮博士. [Solution] Example Basic properties

F. Inequalities. HKAL Pure Mathematics. 進佳數學團隊 Dr. Herbert Lam 林康榮博士. [Solution] Example Basic properties 進佳數學團隊 Dr. Herbert Lam 林康榮博士 HKAL Pure Mathematcs F. Ieualtes. Basc propertes Theorem Let a, b, c be real umbers. () If a b ad b c, the a c. () If a b ad c 0, the ac bc, but f a b ad c 0, the ac bc. Theorem

More information

Section 6.3: Geometric Sequences

Section 6.3: Geometric Sequences 40 Chpter 6 Sectio 6.: Geometric Sequeces My jobs offer ul cost-of-livig icrese to keep slries cosistet with ifltio. Suppose, for exmple, recet college grdute fids positio s sles mger erig ul slry of $6,000.

More information

Chapter 9 Jordan Block Matrices

Chapter 9 Jordan Block Matrices Chapter 9 Jorda Block atrces I ths chapter we wll solve the followg problem. Gve a lear operator T fd a bass R of F such that the matrx R (T) s as smple as possble. f course smple s a matter of taste.

More information

Chapter Linear Regression

Chapter Linear Regression Chpte 6.3 Le Regesso Afte edg ths chpte, ou should be ble to. defe egesso,. use sevel mmzg of esdul cte to choose the ght cteo, 3. deve the costts of le egesso model bsed o lest sques method cteo,. use

More information

Log1 Contest Round 2 Theta Complex Numbers. 4 points each. 5 points each

Log1 Contest Round 2 Theta Complex Numbers. 4 points each. 5 points each 01 Log1 Cotest Roud Theta Complex Numbers 1 Wrte a b Wrte a b form: 1 5 form: 1 5 4 pots each Wrte a b form: 65 4 4 Evaluate: 65 5 Determe f the followg statemet s always, sometmes, or ever true (you may

More information

A conic cutting surface method for linear-quadraticsemidefinite

A conic cutting surface method for linear-quadraticsemidefinite A coc cuttg surface method for lear-quadratcsemdefte programmg Mohammad R. Osoorouch Calfora State Uversty Sa Marcos Sa Marcos, CA Jot wor wth Joh E. Mtchell RPI July 3, 2008 Outle: Secod-order coe: defto

More information

The Selection Problem - Variable Size Decrease/Conquer (Practice with algorithm analysis)

The Selection Problem - Variable Size Decrease/Conquer (Practice with algorithm analysis) We have covered: Selecto, Iserto, Mergesort, Bubblesort, Heapsort Next: Selecto the Qucksort The Selecto Problem - Varable Sze Decrease/Coquer (Practce wth algorthm aalyss) Cosder the problem of fdg the

More information

Similar idea to multiplication in N, C. Divide and conquer approach provides unexpected improvements. Naïve matrix multiplication

Similar idea to multiplication in N, C. Divide and conquer approach provides unexpected improvements. Naïve matrix multiplication Next. Covered bsics of simple desig techique (Divided-coquer) Ch. of the text.. Next, Strsse s lgorithm. Lter: more desig d coquer lgorithms: MergeSort. Solvig recurreces d the Mster Theorem. Similr ide

More information

Chapter Simpson s 1/3 Rule of Integration. ( x)

Chapter Simpson s 1/3 Rule of Integration. ( x) Cpter 7. Smpso s / Rule o Itegrto Ater redg ts pter, you sould e le to. derve te ormul or Smpso s / rule o tegrto,. use Smpso s / rule t to solve tegrls,. develop te ormul or multple-segmet Smpso s / rule

More information

ESS Line Fitting

ESS Line Fitting ESS 5 014 17. Le Fttg A very commo problem data aalyss s lookg for relatoshpetwee dfferet parameters ad fttg les or surfaces to data. The smplest example s fttg a straght le ad we wll dscuss that here

More information

Union, Intersection, Product and Direct Product of Prime Ideals

Union, Intersection, Product and Direct Product of Prime Ideals Globl Jourl of Pure d Appled Mthemtcs. ISSN 0973-1768 Volume 11, Number 3 (2015), pp. 1663-1667 Reserch Id Publctos http://www.rpublcto.com Uo, Itersecto, Product d Drect Product of Prme Idels Bdu.P (1),

More information

SM2H. Unit 2 Polynomials, Exponents, Radicals & Complex Numbers Notes. 3.1 Number Theory

SM2H. Unit 2 Polynomials, Exponents, Radicals & Complex Numbers Notes. 3.1 Number Theory SMH Uit Polyomils, Epoets, Rdicls & Comple Numbers Notes.1 Number Theory .1 Addig, Subtrctig, d Multiplyig Polyomils Notes Moomil: A epressio tht is umber, vrible, or umbers d vribles multiplied together.

More information

Presentation for use with the textbook, Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, Divide-and-Conquer

Presentation for use with the textbook, Algorithm Design and Applications, by M. T. Goodrich and R. Tamassia, Wiley, Divide-and-Conquer Presettio for use with the textook, Algorithm Desig d Applictios, y M. T. Goodrich d R. Tmssi, Wiley, 25 Divide-d-Coquer Divide-d-Coquer Divide-d coquer is geerl lgorithm desig prdigm: Divide: divide the

More information

International Journal of Scientific and Research Publications, Volume 3, Issue 5, May ISSN

International Journal of Scientific and Research Publications, Volume 3, Issue 5, May ISSN Itertol Jourl of Scetfc d Reserch Pulctos, Volue 3, Issue 5, My 13 1 A Effcet Method for Esy Coputto y Usg - Mtr y Cosderg the Iteger Vlues for Solvg Iteger Ler Frctol Progrg Proles VSeeregsy *, DrKJeyr

More information

Math 10 Discrete Mathematics

Math 10 Discrete Mathematics Math 0 Dsrete Mathemats T. Heso REVIEW EXERCISES FOR EXM II Whle these problems are represetatve of the types of problems that I mght put o a exam, they are ot lusve. You should be prepared to work ay

More information

Exercise # 2.1 3, 7, , 3, , -9, 1, Solution: natural numbers are 3, , -9, 1, 2.5, 3, , , -9, 1, 2 2.5, 3, , -9, 1, , -9, 1, 2.

Exercise # 2.1 3, 7, , 3, , -9, 1, Solution: natural numbers are 3, , -9, 1, 2.5, 3, , , -9, 1, 2 2.5, 3, , -9, 1, , -9, 1, 2. Chter Chter Syste of Rel uers Tertg Del frto: The del frto whh Gve fte uers of dgts ts del rt s lled tertg del frto. Reurrg ( o-tertg )Del frto: The del frto (No tertg) whh soe dgts re reeted g d g the

More information

Lecture Notes 2. The ability to manipulate matrices is critical in economics.

Lecture Notes 2. The ability to manipulate matrices is critical in economics. Lecture Notes. Revew of Matrces he ablt to mapulate matrces s crtcal ecoomcs.. Matr a rectagular arra of umbers, parameters, or varables placed rows ad colums. Matrces are assocated wth lear equatos. lemets

More information

v 1 -periodic 2-exponents of SU(2 e ) and SU(2 e + 1)

v 1 -periodic 2-exponents of SU(2 e ) and SU(2 e + 1) Joural of Pure ad Appled Algebra 216 (2012) 1268 1272 Cotets lsts avalable at ScVerse SceceDrect Joural of Pure ad Appled Algebra joural homepage: www.elsever.com/locate/jpaa v 1 -perodc 2-expoets of SU(2

More information

The Z-Transform in DSP Lecture Andreas Spanias

The Z-Transform in DSP Lecture Andreas Spanias The Z-Trsform DSP eture - Adres Ss ss@su.edu 6 Coyrght 6 Adres Ss -- Poles d Zeros of I geerl the trsfer futo s rtol; t hs umertor d deomtor olyoml. The roots of the umertor d deomtor olyomls re lled the

More information

Numbers (Part I) -- Solutions

Numbers (Part I) -- Solutions Ley College -- For AMATYC SML Mth Competitio Cochig Sessios v.., [/7/00] sme s /6/009 versio, with presettio improvemets Numbers Prt I) -- Solutios. The equtio b c 008 hs solutio i which, b, c re distict

More information

A study of the sum of three or more consecutive natural numbers

A study of the sum of three or more consecutive natural numbers A study of the sum of three or more cosecutve atural umbers Emmaul Maousos APM Isttute for the Advacemet of Physcs ad Mathematcs 3 Poulou str. 53 Athes Greece Abstract It holds that every product of atural

More information

Numerical Differentiation and Integration

Numerical Differentiation and Integration Numerl Deretto d Itegrto Overvew Numerl Deretto Newto-Cotes Itegrto Formuls Trpezodl rule Smpso s Rules Guss Qudrture Cheyshev s ormul Numerl Deretto Forwrd te dvded deree Bkwrd te dvded deree Ceter te

More information

A study of the sum three or more consecutive natural numbers

A study of the sum three or more consecutive natural numbers Fal verso of the artcle A study of the sum three or more cosecutve atural umbers Emmaul Maousos APM Isttute for the Advacemet of Physcs ad Mathematcs 3 Poulou str. 53 Athes Greece Abstract It holds that

More information

In Calculus I you learned an approximation method using a Riemann sum. Recall that the Riemann sum is

In Calculus I you learned an approximation method using a Riemann sum. Recall that the Riemann sum is Mth Sprg 08 L Approxmtg Dete Itegrls I Itroducto We hve studed severl methods tht llow us to d the exct vlues o dete tegrls However, there re some cses whch t s ot possle to evlute dete tegrl exctly I

More information

MATH 118 HW 7 KELLY DOUGAN, ANDREW KOMAR, MARIA SIMBIRSKY, BRANDEN LASKE

MATH 118 HW 7 KELLY DOUGAN, ANDREW KOMAR, MARIA SIMBIRSKY, BRANDEN LASKE MATH 118 HW 7 KELLY DOUGAN, ANDREW KOMAR, MARIA SIMBIRSKY, BRANDEN LASKE Prt 1. Let be odd rime d let Z such tht gcd(, 1. Show tht if is qudrtic residue mod, the is qudrtic residue mod for y ositive iteger.

More information

MATH2999 Directed Studies in Mathematics Matrix Theory and Its Applications

MATH2999 Directed Studies in Mathematics Matrix Theory and Its Applications MATH999 Drected Studes Mthemtcs Mtr Theory d Its Applctos Reserch Topc Sttory Probblty Vector of Hgher-order Mrkov Ch By Zhg Sho Supervsors: Prof. L Ch-Kwog d Dr. Ch Jor-Tg Cotets Abstrct. Itroducto: Bckgroud.

More information

(b) By independence, the probability that the string 1011 is received correctly is

(b) By independence, the probability that the string 1011 is received correctly is Soluto to Problem 1.31. (a) Let A be the evet that a 0 s trasmtted. Usg the total probablty theorem, the desred probablty s P(A)(1 ɛ ( 0)+ 1 P(A) ) (1 ɛ 1)=p(1 ɛ 0)+(1 p)(1 ɛ 1). (b) By depedece, the probablty

More information

Numerical differentiation (Finite difference)

Numerical differentiation (Finite difference) MA umercl Alyss Week 4 To tk d wrte portle progrms we eed strct model of ter computtol evromet. Ftful models do est ut tey revel tt evromet to e too dverse forcg portle progrmmers to lot eve te smplest

More information

The Elementary Arithmetic Operators of Continued Fraction

The Elementary Arithmetic Operators of Continued Fraction Americ-Eursi Jourl of Scietific Reserch 0 (5: 5-63, 05 ISSN 88-6785 IDOSI Pulictios, 05 DOI: 0.589/idosi.ejsr.05.0.5.697 The Elemetry Arithmetic Opertors of Cotiued Frctio S. Mugssi d F. Mistiri Deprtmet

More information