2+2

2^2

Sqrt[16]

?Log

Log[10,100]

Mod[10,3]

3/9

N[1/3]

N[E]

N[Pi]

%

%%

x = 5

x:=4

Clear[x]

Solve[x^2-2x+1==0,x]

x+x

Expand[(1+x)^2]

Factor[%]

funkcja[x_] := x^2 +1

funkcja[2]

funkcja2[x_,y_]:= x^2 + y^2 +1

funkcja2[1,2]

f := #^2 +1 &

f[1]

g := #1^2 + #^2 +1 &

g[2,2]

lista = {1,2,3,4};

?Table

Table[i^2, {i,1,10,1}]

Table[Prime[i], {i,50}]

w := Table[i/j, {i,4}, {j,3}]

w //MatrixForm

w

Plot[Sin[x], {x,0, 3 Pi}]

Manipulate[Plot[Sin[x(1+a x)], {x,0, 3 Pi}], {{a,1},0,2}]

obrot[x_, θ_]:=Mod[x+θ, 2 Pi]

obrot[0, Pi/2]

obrot[x_, θ_]:=Mod[N[x+θ], 2 Pi]

obrot[0,Pi/2]

Plot[obrot[Pi/6, x], {x,0,6 Pi}]

Manipulate[Plot[obrot[θ, x],{x, 0, 6 Pi}], {θ, 0, 2 Pi}]

?Nest

Nest[h, x, 4]

NestList[h,x,4]

orbita[x0_, θ_, n_] := NestList[obrot[#, θ]&, x0, n-1]

y=2

fun[y_] := (x=y+5; x^2)

fun[3]

Manipulate[zp=orbita[x0, θ, n]; ListPlot[zp], {θ, 0, 2 Pi}, {{x0,2}, 0, 2Pi},
{{n,40},{40,80,160,320}}]

?Graphics

Manipulate[zp=orbita[x0,θ, Max[k,n]]; Graphics[{Red, Circle[], Black, 
Table[Disk[{Sin[zp[[i]]], Cos[zp[[i]]]}, 0.02] , {i,1,k}]}] ,
{θ, 0, 2 Pi}, {x0, 0, 2Pi}, {{n,40}, {40,80,160}},  {{k,1}, 1,n,1}]

Histogram[orbita[Exp[1], Pi/12, 15000], {1/20}, "PDF"]