.


:




:

































 

 

 

 





 

3

1. 4

2. 11

3. 17

4. MS Excel 21

5. 25

6. 29

7. 34


 

- , , . : , , .

MS Excel , . .

. :

;

;

() ;

.

, . MS Excel . .

 

1.

 

: , , .

 

f(x)=0, (1.1)

f .

(1.1) :

A 0 + A 1 x + A 2 x 2 +... + A n x n = 0,

( A i - ), n - . (1.1)

(1.1): , , , .

.

n+1=xn-f(xn)/f 1(xn).

 

( ). [a,b] , f(x) .

.

n+1=xn- (xn xn-1)* f (xn)./ (f(xn)- f(xn-1)).

 

.

xn= w(xn-1);

. , |w1()| <1 .

(1) .

 

.

3-17+12=0 (1.2)

. .

1.1

1 3-17+12=0 , , ,
2 , 3+12 =w()=----------

 

:

1. ( );

2. .

3. .

4. ++ ( ).

 

, .

f(x)= 3-17+12. (1.3)

-5 <=x <=5, f(x). - f(x).

 

1.1

 

, =0,8, =3,7 =-4,5.

, . . , , .

 

( ) . 2 -

(1.4)

. . . .

 

(1.5)

4 (0,8). 4 (1.5) 4.

, , . , 5 (=4).

, 4 5.

5 . - .

 

1.2

 

1.2 , ( ) =0,7286 .

w1(x)= 3*2 /17 <1 =0,8, .

.

: .

 

1.3

MS Excel . .

: . , : - .

1. 3 - (0,8), 4 =3^3-17*3+12 ( 1.3).

 

1.3

.

4, .

, ( ).

:, 0.

: , , - 3.

.

, 0,73.

, .

: .

 

1.4 ( )

, e. .

[a,b], , =(+b)/2, : [a,b] [a,c] [c,b] f (): f(a)f(c)<0, [,], f(a)f(c)>0, [c,b]. f(x), . , e.

, (++).

, . a b a<b f(a)f(b)[0. fa f (a), [a,b], fc , f(c).

. b ( ), . , b, .

f(x)=x3-17*x+12; [0,2]; =0,b=2. .

#include<iostream.h>

#include<conio.h>

#include<math.h>

float f(float x) //,

{float ff;

ff=x*x*x-17*x+12;

return ff;}

void main() //

{float a,b,c,fa,fc,eps; int n=0;

clrscr();

cin>>a>>b>>eps;

fa=f(a);

do

{ c=(b+a)/2;

fc=f(c);

if (fa*fc<0) b=c;

else

{

a=c;fa=fc;

} cout<<c<<endl;n=n+1;

} while (b-a>eps);

cout<<a<<endl;

cout<<n<<endl;

}

 

: , ++. ++ .

: f(x) , f(x)<= 0, f(x) f(x) .

 





:


: 2017-01-28; !; : 940 |


:

:

,
==> ...

1548 - | 1429 -


© 2015-2024 lektsii.org - -

: 0.033 .