(*pomocnicza definicja*)arrows[function_,x0_,n_]:=Module[{l=NestList[function,x0,n]},l=Prepend[Flatten[Transpose[{Transpose[{Most[l],Rest[l]}],Transpose[{Rest[l],Rest[l]}],Transpose[{Rest[l],0Rest[l]}]}],1],{l[[1]],0}];Arrow/@Transpose[{Most[l],Rest[l]}]]
In[]:=
(*zadanie1*)​​Limit[Sqrt[n^2+n]-Sqrt[n^2-n],nInfinity]​​Limit[(Sqrt[n+1]-Sqrt[n])/(Sqrt[n]-Sqrt[n-1]),nInfinity]​​Limit[n(((n+1)/n)^(1/3)-(n/(n+1))^(1/3)),nInfinity]
Out[]=
1
Out[]=
1
Out[]=
2
3
In[]:=
(*zadanie2*)​​DiscreteLimit[(3^n-(-2)^n)^(1/n),nInfinity]​​DiscreteLimit[(3^(-n)+2^(-n))^(1/n),nInfinity]​​DiscreteLimit[(2^n+Cos[n]^2)^(1/n),nInfinity]
Out[]=
3
Out[]=
1
2
Out[]=
2
In[]:=
(*zadanie8*)​​a[1]=1;​​a[n_]:=a[n]=a[n-1]+1/a[n-1];​​ListStepPlot[Table[a[n],{n,1,20}]]​​ListStepPlot[{Table[a[n],{n,1,20}],Sqrt[2Range[20]]}]​​f=Function[x,x+1/x];​​Show[​​Plot[{f[x],x},{x,0,10},AspectRatioAutomatic,PlotRange{0,10.5},ImageSize800],​​Graphics[{Arrowheads[Small],Thickness[Large],Red,arrows[f,1.,50]}]​​]​​
Out[]=
5
10
15
20
1
2
3
4
5
6
Out[]=
5
10
15
20
1
2
3
4
5
6
Out[]=
In[]:=
(*zadanie9*)​​f=Function[x,1+x/2-2/x];​​Show[​​Plot[{f[x],x},{x,-5,5},AspectRatioAutomatic,PlotRange{-5,5},ImageSize800],​​Graphics[{Arrowheads[Small],Thickness[Large],Red,arrows[f,1.,50]}]​​]​​Show[​​Plot[{f[x],x},{x,-5,5},AspectRatioAutomatic,PlotRange{-5,5},ImageSize800],​​Graphics[{Arrowheads[Small],Thickness[Large],Red,arrows[f,2.,50]}]​​]
Out[]=