Mathematica implementation of the Gaver-Stehfest method with an Example
Leonardo Dagdug,  Ivan Pompa-García,  Jason Peña
From the book:
 Diffusion Under Confinement: A Journey Through Counterintuition

Gaver-Stehfest method

Implementation of the Gaver-Stehfest method to find numerically the inverse Laplace transform, where f is the function to invert, t is the time to be evaluated, and n is the number of terms used. The number n should be an even integer between 4 and 20.

csteh[n_,k_]=(-1)^(k+n) Sum[j^(n/2) (2j)!/((n/2-j)! j! (j-1)! (k-j)! (2j-k)!),{j,Floor[(k+1)/2],Min[k,n/2]}];

NLInvSteh[f_,s_,t_,n_]:=Log[2]/t Sum[csteh[n,k] f/. s->k Log[2]/t,{k,1,n}]//N

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~Example~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Below is the code presented in Listing. 5.2 from the book as a use example of the NLInvSteh function.

table = Table[
{
t,
NLInvSteh[1 / ( Sqrt[s]+ Sqrt[s + 1] ), s ,t ,20]
},
{t, 1, 10, 0.20}
]

ListLinePlot[
table,
AxesLabel->{t, 1 / ( Sqrt[s]+ Sqrt[s + 1] )},
LabelStyle->{Bold,Black}
]