A method of dynamic homogenization: application to 2D core calculation