A pyrene-functionalized polymer was patterned via electron beam lithography onto a silicon wafer and shown to selectively bind with carbon nanotubes.