Estimating the time-dependent contact rate of SIR and SEIR models in mathematical epidemiology using physics-informed neural networks (Electronic transactions on numerical analysis, 2022)