Árpád apánk

Blog. ennyi. semmi több. megtalalsz itt jó pár infót rólam, az életemről, meg néhány érdekes dolgot is, csak épp fejlesszem ki. addig is türelem kispajtás :)

2008/05/20

masodik

> f:=x->x^3-x-3;

>

f := proc (x) options operator, arrow; x^3-x-3 end proc

f(x) := 0

> plot(f(x),x=-2..2);

[Plot]

> solve(f(x),x);

(324+12*717^(1/2))^(1/3)/6+2/(324+12*717^(1/2))^(1/3), -(324+12*717^(1/2))^(1/3)/12-1/((324+12*717^(1/2))^(1/3))+1/2*I*3^(1/2)*((324+12*717^(1/2))^(1/3)/6-2/(324+12*717^(1/2))^(1/3)), -(324+12*717^(1/...(324+12*717^(1/2))^(1/3)/6+2/(324+12*717^(1/2))^(1/3), -(324+12*717^(1/2))^(1/3)/12-1/((324+12*717^(1/2))^(1/3))+1/2*I*3^(1/2)*((324+12*717^(1/2))^(1/3)/6-2/(324+12*717^(1/2))^(1/3)), -(324+12*717^(1/...

> fsolve(f(x),x,complex);

-.8358499408-1.046869319*I, -.8358499408+1.046869319*I, 1.671699882

> h:=x->x-f(x)/D(f)(x);

h := proc (x) options operator, arrow; x-f(x)/D(f)(x) end proc

> f(5);

117

> fsolve(h(x));

-1.144714243

> solve(h(x));

-12^(1/3)/2, 12^(1/3)/4-1/4*I*3^(1/2)*12^(1/3), 12^(1/3)/4+1/4*I*3^(1/2)*12^(1/3)

> plot(h(x),x=-5..5);

[Plot]

> felezo:=proc(f,bal,jobb,eps)
local a,b,kozep;

a:=bal;

b:=jobb;

while b-a>2*eps do

kozep:=(a+b)/2;

if evalf(f(a)*f(kozep))<0>
b:=kozep

else

a:=kozep

end if;

end do;

RETURN (kozep)

end:

>

> felezo(f,1.,2,0.001);

>

>

1.669921875

> with(plots);

[animate, animate3d, animatecurve, arrow, changecoords, complexplot, complexplot3d, conformal, conformal3d, contourplot, contourplot3d, coordplot, coordplot3d, cylinderplot, densityplot, display, disp...[animate, animate3d, animatecurve, arrow, changecoords, complexplot, complexplot3d, conformal, conformal3d, contourplot, contourplot3d, coordplot, coordplot3d, cylinderplot, densityplot, display, disp...[animate, animate3d, animatecurve, arrow, changecoords, complexplot, complexplot3d, conformal, conformal3d, contourplot, contourplot3d, coordplot, coordplot3d, cylinderplot, densityplot, display, disp...

> c:=x->exp(x)-2; x0:=3; m:=D(c)(x0);

c := proc (x) options operator, arrow; exp(x)-2 end proc

x0 := 3

m := exp(3)

> J:=plot([x,c(x),x=0..3.5],color=black):

> K:=plot([[x0,0],[x0,c(x0)]],color=red):

> L:=plot([x,m*(x-x0)+c(x0),x=1.5..3.5],color=green):

> display({J,K,L});

[Plot]

>

>

>

> j:=x->10*x^4+4*x^3-0.4*x^2-0.01*x+0.007;

j := proc (x) options operator, arrow; 10*x^4+4*x^3-.4*x^2-0.1e-1*x+0.7e-2 end proc

> solve(j(x));

-.4734312965, -.1063942057, 0.8991275107e-1-0.7624147521e-1*I, 0.8991275107e-1+0.7624147521e-1*I

> plot(j,-1..1,y=-1..1);

[Plot]

>