(*Tepelny odpor valce*)

Div[Grad[T[r], {r,fi,z}, "Cylindrical"], {r,fi,z}, "Cylindrical"]

resT=T[r]/.DSolve[{0==Div[Grad[T[r], {r,fi,z}, "Cylindrical"], {r,fi,z}, "Cylindrical"],T[r1]==T1,T[r2]==T2},T[r],r][[1]]

Simplify[-λ*Grad[resT, {r,fi,z}, "Cylindrical"][[1]]*l*2Pi*r]

(*Prutokovy ohrivac*)

msteckou=0.25;
ρ=1000;
cp=4186;
Vsteckou=(msteckou/ρ);
T1=15;
T2=45;
m=0.5;
cm=0.01;
d=0.5cm;
prikon=msteckou*cp*(T2-T1);
vx=(Vsteckou/(d*m));
U=230;
Ecko=(U/d);
resab=Solve[{20*a+b==(1/70.),75*a+b==(1/30.)}][[1]];
(*resab=Solve[{10*a+b==(1/35.),50*a+b==(1/10.)}][[1]]*)
rce=ρ*cp*vx*T'[x]==(a*T[x]+b)*(Ecko^2)/.resab;
okr=T[0]==T1;
res=DSolve[{rce,okr},T[x],x][[1]];
teplota=T[x]/.res;
Plot[{teplota,T2},{x,0,0.6},AxesLabel->{"x[m]","T[°C]"},PlotStyle->{Thickness[0.008],Thickness[0.008]}]

Rth1=(1/(5*100))+(0.4/(0.5*100));
Rth2=(1/(10*100));
Tepl=(Rth2/(Rth1+Rth2))*(20-0)+0

Plot[((1/(alfa*2*Pi*r2*l))+(1/(2Pi*λ*l))Log[(r2/r1)])/.{alfa->5.,l->1,λ->0.5,r1->0.001},{r2,0,1}]

ro=2400;
Cp=1011;
Tout=5+273;
ToutS=-5+273;
Tin=20+273;
sigma=5.775*(10^(-8));
epsilon=0.93;
alfa=15;
lambda=0.3;
tloustka=0.3;
tMax=200000;

rce=ro*Cp*D[T[x,t],t]==lambda*D[D[T[x,t],x],x];
pocPodminka=T[x,0]==Tout;
okrVlevo=T[0,t]==Tin*Tanh[t]+Tout*(1-Tanh[t]);
okrVpravo=-lambda*D[T[x,t],x]==(alfa*(T[x,t]-Tout)+sigma*epsilon*((((T[x,t]))^4)-(((ToutS))^4)))*(t/(t+1))/.x->tloustka;

res=NDSolve[{rce,pocPodminka,okrVlevo,okrVpravo},T[x,t],{x,0,tloustka},{t,0,tMax}]

Plot3D[T[x,t]-273/.res,{x,0,tloustka},{t,0,tMax}]

(*Treti cviceni*)

α=10;
S=2;
σ=5.67*(10^(-8));
ϵ=0.5;
T2=Tv=20+273;

Manipulate[{α*S*((T1+273)-T2),σ*ϵ*S*((((T1+273))^4)-(T2^4)),((σ*ϵ*S*((((T1+273))^4)-(T2^4)))/(α*S*((T1+273)-T2)))},{T1,30,1000}]

Remove["Global`*"]

res=Solve[σ*ϵ*S*((T1^4)-(T3^4))==σ*ϵ*S*((T3^4)-(T2^4)),T3][[4]]

σ*ϵ*S*((T1^4)-(T3^4))/.res

FullSimplify[((σ*ϵ*S*((T1^4)-(T3^4)))/(σ*ϵ*S*((T1^4)-(T2^4))))/.res]

σ=5.67*(10^(-8));
ϵ=0.5;
resα=αrad/.Solve[σ*ϵ*((T1^4)-(T2^4))==αrad*(T1-T2),αrad][[1]]

Manipulate[Evaluate[resα],{T1,300,800},{T2,300,800}]

cas=4*60*60;
Tkonec=1085;
Tzacatek=Tokoli=20;
hmotnost=5000;
hustota=8940;

((hmotnost/hustota)^(1/3.));
a=1;

diz=0.02;
λiz=0.8;
λsibral=0.14;
Tpovrch=40;
Svnitrni=(a^2)*6;
α=5;

Rizolaceasibral=(diz/(λiz*Svnitrni))+(dsibral/(λsibral*Svnitrni));
Pztraty=α*6*(((a+2*(diz+dsibral)))^2);
tloustka=FindRoot[Pztraty==((Tkonec-Tpovrch)/Rizolaceasibral),{dsibral,1}]