Gauss Elimination Method

Multiple Sets of Equations

As mentioned before, it is frequently necessary to solve the equations Ax = b for several constant vectors. Let there be m such constant vectors, denoted by

b 1 , b 2 ,..., b m and let the corresponding solution vectors be x 1 , x 2 ,..., x m . We denote multiple sets of equations by AX = B, where

X= x 1 x 2 ···x m

B= b 1 b 2 ···b m

are n × m matrices whose columns consist of solution vectors and constant vectors, respectively.

An economical way to handle such equations during the elimination phase is to include all m constant vectors in the augmented coefficient matrix, so that they are transformed simultaneously with the coefficient matrix. The solutions are then obtained by back substitution in the usual manner, one vector at a time. It would quite easy to make the corresponding changes in gauss . However, the LU decomposition method, described in the next article, is more versatile in handling multiple constant vectors.

EXAMPLE 2.3 Use Gauss elimination to solve the equations AX = B, where

A= ⎥

B= ⎣ 36 −18 ⎦

Solution The augmented coefficient matrix is

The elimination phase consists of the following two passes: row 2 ← row 2 + (2/3) × row 1

row 3 ← row 3 − (1/6) × row 1 ⎡

35 0 In the solution phase, we first compute x 1 by back substitution:

X 31 = 5/2 = 14

X 80/3 + (10/3)X 31 21 80/3 + (10/3)14 =

X −14 + 4X 21 −X 31 11 −14 + 4(22) − 14 =

6 = 10 Thus the first solution vector is

x 1 = X 11 X 21 X 31 = 10 22 14 The second solution vector is computed next, also using back substitution:

X 32 =0

X −10/3 + (10/3)X 32 22 −10/3 + 0 = = = −1

X 22 + 4X 22 −X 32 12 22 + 4(−1) − 0 =

6 =3 Therefore,

x 2 = X 12 X 22 X 32 = 3 −1 0

EXAMPLE 2.4 An n × n Vandermode matrix A is defined by

i = 1, 2, . . . , n, j = 1, 2, . . . , n where v is a vector. In MATLAB a Vandermode matrix can be generated by the com-

A ij =v n− j i ,

mand vander(v) . Use the function gauss to compute the solution of Ax = b, where

A is the 6 × 6 Vandermode matrix generated from the vector

Also evaluate the accuracy of the solution (Vandermode matrices tend to be ill- conditioned).

Solution We used the program shown below. After constructing A and b, the output format was changed to long so that the solution would be printed to 14 decimal places. Here are the results:

% Example 2.4 (Gauss elimination) A = vander(1:0.2:2); b = [0 1 0 1 0 1]’; format long [x,det] = gauss(A,b) x=

1.0e+004 * 0.04166666666701 -0.31250000000246 0.92500000000697 -1.35000000000972 0.97093333334002 -0.27510000000181

det = -1.132462079991823e-006

As the determinant is quite small relative to the elements of A (you may want to print A to verify this), we expect detectable roundoff error. Inspection of x leads us to suspect that the exact solution is

x= 1250/3 −3125 9250 −13500 29128/3 −2751 in which case the numerical solution would be accurate to 9 decimal places.

Another way to gauge the accuracy of the solution is to compute Ax and compare the result to b:

>> A*x ans =

-0.00000000000091 0.99999999999909 -0.00000000000819 0.99999999998272 -0.00000000005366 0.99999999994998

The result seems to confirm our previous conclusion.

Dokumen yang terkait

WARTA ARDHIA Jurnal Perhubungan Udara Harapan dan Kepentingan Pengguna Jasa Angkutan Udara Terhadap Pelayanan di Bandar Udara H.AS Hanandjoeddin–Tanjung Pandan Belitung Air Transport Passenger Expectations and Interest of Airport Services in H.A.S Hanandj

0 0 12

The Evaluation of Air Transportation Infrastructure Performance in Indonesian Capital Province

0 0 10

Demand Forecasting of Modal Share of Bandara Internasional Jawa Barat (BJIB) in Kertajati Majalengka

0 1 12

WARTA ARDHIA Jurnal Perhubungan Udara Analisis Flutter Pada Uji Model Separuh Sayap Pesawat N219 di Terowongan Angin Kecepatan Rendah The Analysis of Half Wing Flutter Test N219 Aircraft Model in The Low Speed Wind Tunnel

0 0 8

WARTA ARDHIA Jurnal Perhubungan Udara Penerapan Skema Badan Layanan Umum Dalam Pengelolaan Keuangan Bandar Udara Internasional Jawa Barat The Application of Badan Layanan Umum Scheme in The Financial Management of Jawa Barat International Airport

0 0 16

Speech Recognition Conceptual Design in Aircraft Communications to Reduce Flight Communication Mistake

0 0 10

WARTA ARDHIA Jurnal Perhubungan Udara Perencanaan Integrasi Transportasi Antarmoda Dalam Pembangunan Bandar Udara (Studi Kasus: Pembangunan Bandar Udara di Kertajati) Intermodal Transportation Integration Planning in Airport Development (Case Study: Airpo

0 0 8

WARTA ARDHIA Jurnal Perhubungan Udara Gaya Hambat Saat Hidro Planing dan Gaya Angkat Aerodinamika Saat Cruise di Efek Permukaan pada Pesawat Wing in Surface Effect The Hump Drags During Hydro Planing and Aerodynamic Lift During Cruise in Surface Effect Al

0 0 8

WARTA ARDHIA Jurnal Perhubungan Udara Peran Jasa Ground Handling Terhadap Pelayanan Perusahaan Air Freight di Bali dalam Menghadapi Kompetisi Global The Role of Ground Handling Services to The Air Freight Services in Bali in The Face of Global Competition

0 1 14

Advance Engineering Mathematic chaper 1

0 0 63