The occurrence geology and hydrogeological characteristics of main coal seam in northwest China are different from those in shallow mining areas, so how to reduce the risk of mine water inrush is particularly important for safe coal mining. Taking Baotashan sandstone aquifer in Shicaocun Coal Mine as the engineering background, a three-dimensional visualization model of the aquifer is constructed, and the model is verified by single and porous unsteady flow models, and the position of the roof drainage point is estimated by inversion. The results show that: (1) The unsteady flow model data of the roof group holes in the mining area have good fit with the measured data of water discharge from the observed holes, and the model has high reliability; (2) The optimal solution of aquifer numerical reconstruction is divided into six zones: Ⅰ high permeability medium water storage zone, Ⅱ medium permeability high water storage zone, Ⅲ high permeability high water storage zone, Ⅳ low permeability medium water storage zone, Ⅴ low permeability low water storage zone, Ⅵ medium permeability medium water storage zone; (3) The water discharge point of the well is located between G1-1 observation point and F1-3 observation point, and the water discharge is 150m3
/d. The research results have good practical significance for realizing precise water discharge of aquifer roof and reducing the risk of mine water inrush accident.