ClearAll["Global`*"];
SetDirectory[NotebookDirectory[]];
$HistoryLength=3;

b + 2, tohle je text

(*komentar*)
b+1+c+α

vyr=(x^3)+b*Sin[x+y];
TreeForm[vyr]
FullForm[vyr];

(x^3)+b*Sin[x+y]=2

(*neco o listech*)
listik={ja,ty,{alfa,romeo},{dub,{sekera}}};
(*vyber prvku*)
listik[[3]][[2]];
listik[[3,2]];
listik[[-2]];
First[listik];
Last[listik];
Length[listik];

?_

ClearAll[f];
f[x:_]:=(x^2);
f[5]

?:=

ClearAll[f];
x=1;
f[x_]:=(x^2)
f[5]
?f

?=

ClearAll[f];
f[x_]=(x^2)
f[5]
?f

f[x_]:=Integrate[(a^2)*Sin[a*x+(x^2)],x];
f[1]

ClearAll[f,x];
f[x_]=Integrate[(a^2)*Sin[a*x+(x^2)],x];
f[0.5]

ClearAll[f];
f[x_]:=x;
f[x_Integer]:=(E/x);
f[1]:="to myslis vazne??";
f[1]

ClearAll[a];
a[n_]:=n*a[n-1];
a[0]:=1;
a[5]

a[n_]:=n*a[n-1];
a[0]:=1;

Trace[a[3]]

$RecursionLimit=(10^4);

ClearAll[a];
a[n_]:=n*a[n-1];
a[0]:=1;
Timing[Table[a[i],{i,1000}]][[1]]

ClearAll[a];
a[n_]:=a[n]=n*a[n-1]//N;
a[0]:=1;
Timing[Table[a[i],{i,1000}]][[1]]

ClearAll[f,x];
f[x_]:=-x*(x-2)/;0≤x≤2;
f[x_]:=f[x-2]/;x>2;
f[x_]:=f[x+2]/;x<0;
Plot[f[x],{x,-10,10}];
Trace[f[8.5]];

(*zde zacina druhy prednes*)
ClearAll["Global`*"];

Plot[((#)^2)&[x],{x,-1,1}];
Plot3D[#1*#2&[x,y],{x,0,1},{y,0,1}];

#=2;

Select[{1,2,4,7,6,2},#>2&]

test[x_]:=x>2;
Select[{1,2,4,7,6,2},test]

lide={ja,ty,on,ona,ono};
Map[ostrihejVlasy,lide];
ostrihejVlasy/@lide;

Attributes[Sin]

Sin[{1,2,4,7,6,2}];
Sin/@{1,2,4,7,6,2};

((#)^2)&/@Range[10];

lide

Apply[natocPecko,lide]
natocPecko@@lide

lide//TreeForm

f[ja,ty,on,ona,ono]//TreeForm

?/.

(({{1, 2}, {3, 4}}))/.{1->9}
%//MatrixForm

{{9,2},{3,4}}//TreeForm

{{9,2},{3,4}}/.List->Plus

f[x_]=x;
f[x_]:=x;

a=Pi;
{{9,2},{3,4}}/.a_Integer->(Sqrt[a])

?RuleDelayed

{{9,2},{3,4}}/.a_Integer:>(Sqrt[a])

Solve[(x^2)==1]

x/.x->2

x/.{x->2}

x/.{{x->-1},{x->1}}

x+y/.{x->2,y->1}

Plus@@((Sqrt[x])/.Solve[(x^20)==1.])

x/.Solve[x==1]
x/.Solve[x==1][[1]]

Solve[(x^2)==1]

sol=DSolve[{y'[x]+(x^2)*y[x]==x,y[0]==1},y[x],x];
proTisk=y[x]/.sol[[1]];
Plot[proTisk,{x,0,3}];

taylor=Series[Exp[x],{x,0,5}]
Normal[taylor]

Manipulate[
Plot[a*Sin[a*x],{x,0,Pi},PlotRange->{Automatic,{-11,11}},PlotStyle->Thick],
{a,0.1,10}
];

fce[x_]:=Sin[x];
n=5;
vyr=Normal[Series[fce[x],{x,0,n}]];
Plot[{fce[x],vyr},{x,0,5},PlotStyle->{{Thick,Red,Dashed},{Thick,Blue,Opacity[0.5]}},PlotRange->{Automatic,{-2,2}},AxesLabel->{"x","fce  taylor "}]

Manipulate[
vyr=Normal[Series[fce[x],{x,0,n}]];
Plot[{fce[x],vyr},{x,0,15},PlotStyle->{{Thick,Red,Dashed},{Thick,Blue,Opacity[0.5]}},PlotRange->{Automatic,{-2,2}},AxesLabel->{"x","fce  taylor "}]
,{{n,1},1,50,2}
]

ClearAll["Global`*"];
μF=(10^(-6));
mH=(10^(-3));
uz[t_]:=Tanh[100*Sin[2*Pi*500*t]];
R1=100;
R2=100;
c=4.7μF;
L=10mH;
rce={iR1[t]==iC[t]+iL[t],
0==iUz[t]+iR1[t],
iL[t]==iR2[t],
u1[t]-u2[t]==R1*iR1[t],
iC[t]==c*u2'[t],
u2[t]-u3[t]==L*iL'[t],
u3[t]==R2*iR2[t],
uz[t]==u1[t]
};

nezname=Cases[rce,a_Symbol[t],{0,∞}]//Union;
poc=Cases[rce,a_'[t]:>a[0]==0,{0,∞}]//Union;
dohr=Union[rce,poc];
tmax=0.01;
sol=NDSolve[dohr,nezname,{t,0,tmax},StartingStepSize->(10^(-12)),MaxSteps->(10^6)];
Plot[Evaluate[{uz[t],u3[t]}/.sol],{t,0,tmax},PlotStyle->Thickness[0.006]]

proLimitu=((y*(x^2)-y*x)/((x^2)+(y^2)))/.{x->r*Cos[fi],y->r*Sin[fi]}
Limit[proLimitu,r->0]