Numerical simulations of flow in the melt (CdZnTe) with different conditions are conducted using the finite-difference method. When the top surface of the melt is solid wall under microgravity condition, the thermocapillary convection is caused in the melt by the surface tension gradient on the free surface. As the Marangoni number is small, the flow is steady thermocapillary convection. As the Marangoni number exceeds the critical value, the steady flow transits into unstable thermocapillary convection. When the top surface of the melt is free surface under microgravity, two roll cells are observed in the melt, which are driven by both the surface tension gradients on the upper and lower free surfaces. When the top surface of the melt is free surface under gravity condition, the effect of the buoyancy on the flow is little as the Marangoni number is small. With the Marangoni number increasing, the effect of the buoyancy increases, which makes the upper roll cell weaken and the lower roll cell strengthen. detached solidification, thermocapillary convection, buoyancy, CdZnTe, numerical simulation Citation: Peng L, Fan J Y, Li Y R, et al. Two-dimensional numerical simulation of thermocapillary convection in detached solidification. Sci China Tech Sci, 2012, 55: 527536,