A series of numerical simulations are conducted using the Weather Research and Forecasting (WRT-ARW) model with a 9-km mesh to examine the physical processes responsible for the torrential rainfall associated with a mesoscale convective system (MCS) along the Mei-Yu front that caused severe damage over southwestern Taiwan on 12 June 2005. In the control experiment (with full Taiwan terrain), the MCS tends to propagate northward along the windward (western) slope, rather than being advected downstream, as it encounters the southern Central Mountain Range (CMR). The low-level convergence between the dynamically-driven return flow and the incoming southwesterly flow is an important factor for the northward propagation of the MCS. The values of the unsaturated moist Froude number (F-w) and the convective available potential energy (CAPE) are about 0.333 and 2858 J kg(-1) for the convectively unstable basic flow. This airflow belongs to the flow-around regime as suggested by previous studies. In this flow regime, the torrential rainfall associated with the simulated MCS occurs on both the upslope side and adjacent plains over southwestern Taiwan, which agrees well with the observed rainfall distribution. A sensitivity study of lowering the Taiwan terrain elevations to 80% (F-w similar to 0.416) or 60% (F-w similar to 0.555) of that in the control experiment reveals that the airflow is characterized by a long-lasting orographic convective system near the mountain peaks. The simulated torrential rainfall mainly occurs along the mountain peaks of the southern CMR. The experiment with a reduced elevation to 40% (F-w similar to 0.833) or 20% (F-w similar to 1.666) in the control experiment shows a downstream-propagating MCS, which falls into the flow-over regime. This study demonstrates that the northward propagating MCS, which is mainly caused by the flow deflection by southern CMR, played a key role in producing torrential rainfall over southwestern Taiwan during 0000 1200 UTC 12 June 2005.