Simple carbon nanotube device

In this tutorial you will build a single-wall carbon nanotube (CNT), relax it along the tube length, and then turn it into a device configuration suitable for nanoscale transport studies.


This is a two-step procedure:

  1. Build and geometry optimize a single CNT unit cell.
  2. Elongate the relaxed CNT and turn it into a device configuration.


Geometry relaxing the CNT is particularly important for phonon calculations: Negative phonon frequencies will appear in the phonon band structure if the configuration is not properly relaxed.

Build and geometry optimize a short CNT

Open the QuantumATK Builder builder_icon, and use Add ‣ From Plugin ‣ Nanotube to create a (6,0) carbon nanotube.


Then send the configuration to the Script Generator script_generator_icon by using the sendto_icon botton. In the Scripter, add the following blocks:

  • calculator_icon New Calculator.
  • optimization_icon Optimization ‣ OptimizeGeometry.

Change the output file to cnt.hdf5 and double-click the New Calculator block calculator_icon to edit the settings:

  • Select the ATK-ForceField calculator and the “Tersoff_C_2010” potential.



For QuantumATK-versions older than 2017, the ATK-ForceField calculator can be found under the name ATK-Classical.

Then open the OptimizeGeometry optimization_icon block and edit it:

  • Set the maximum force to 0.01 eV/Å.
  • Set the maximum stress to 0.001 eV/Å3.
  • Remove the checkmark for “z” under “Constrain cell” to allow relaxation of the cell along the periodic direction.

Send the script to the Job Manager job_manager_icon, save the script as, and run the calculation by clicking jm_play_enabled_icon. The calculation uses a classical potential, so it should be very fast.


Once finished, you should find the output cnt.hdf5 on the QuantumATK LabFloor. It contains two objects of the type bulk_configuration bulk_icon - the initial (glD000) and the optimized (glD001) CNT structures. You can click an object to highligt it and then use the Viewer viewer_icon to visualize it.


CNT device configuration

Drag and drop the optimized CNT onto the Builder builder_icon. Then do the following to make it longer:

  • In the right-hand side panel, open the Bulk Tools ‣ Repeat plugin.
  • Enter a repetition of 10 along C (the tube axis) and click Apply to create a longer CNT.


You are finally ready to convert the configuration to a device and save it:

  • Open the Device Tools ‣ Device From Bulk plugin.
  • Leave the electrode lengths at default.
  • Click OK to create the device.
  • Highlight the device configuration, right-click it, and choose Save as in the drop-down menu. You can now save the configuration in either a HDF5 file (cnt_device.hdf5) or as a Python script (
  • Note that the CNT device consists of a central scattering region sandwiched between left and right electrodes.



The instructions above result in a CNT device with a central region that is roughly 43 Å long. This is a somewhat arbitrary choice and it may well be that specific applications require a shorter or a longer central region!

The central region and electrode lengths are easily modified:

  • Highlight the device Stash item.
  • Use the Device Tools ‣ Central Region Size plugin to change the central region length along the C axis.
  • Similarly, the Device Tools ‣ Electrode Size plugin lets you change the electrode lengths.


What next?
You have created a carbon nanotube device configuration. You can now use it in scientific studies of electron and phonon transport in CNTs.

For example, you can check out the tutorial Thermoelectric effects in a CNT with isotope doping, where phonon and electron transmission spectra, thermal conductance, and the ZT product is calculated for CNTs with and without isotope impurities.

For your reference, you can download the CNT device configuration created in this tutorial here: