For the thermal hydraulics analysis of nuclear reactor components of LWRs (Light Water Reactors) such as reactor vessel, steam generator, containment, a multi-dimensional two-phase flow code, named CUPID, has been being developed. The CUPID code pursues a capability of multi-physics and multi scale thermal hydraulics analysis. In the present study, multi-scale simulation was performed by coupling with system-scale code, MARS. The coupled code was assessed to visualize the flow behavior of the steam generator of the Advanced Power Reactor (APR1400). The primary side of the steam generator and remaining Reactor Coolant System (RCS) is modeled by MARS and secondary side is by CUPID. For the secondary side simulation by the CUPID part, a porous media approach was adopted to two-fluid model and conductor model to simplify the complicated geometry of the steam generator. In order to obtain a porosity of a given computing cell, a special algorithm was employed to directly calculate volume ratio by mapping the 3D CAD file onto the grid system. Besides, the proper constitutive relationships for U-tubes are considered further. To treat the complex thermo-hydraulic phenomena on the shell side of a steam generator, a set of constitutive models available in the literature for a two-phase flow map, interfacial heat and mass transfer, interfacial drag, wall friction, wall heating, and heat partitioning in flows over tube bundles were applied to close the numerical model. This paper presents the description of the coupling method, porous media approach to simplify the steam generator, and the simulation results using the coupled code. (C) 2016 Elsevier Ltd. All rights reserved.