A molecular dynamics study of effective thermal conductivity in nanocomposites