Patterned attachment of carbon nanotubes to silicon