Below you will find descriptions and links to files for analyzing AFM images for nanotribology research. This page provides free access to the analysis tools developed by the Carpick group at the University of Pennsylvania. Among the tools available here are instructions for gathering friction versus load (FvL) data from a Bruker (formerly Veeco and Digital Instruments or DI) NanoScope (III or IV) AFM, MatLab scripts for analyzing FvL and adhesion data, and directions for the use of these scripts. Please read carefully the headers in each of the scripts and the directions in the manual provided below: FvL Analysis Manual Please note that all materials on this page are Copyrighted by the Carpick Group at the University of Pennsylvania. They are authorized for use in government or academic research laboratories and non-profit institutions only. You are welcome to modify, re-post, and distribute these files as long as you provide attribution to the original source (this web site). Please report any bugs by writing a Comment below. Processing a NanoScope fileThe following scripts handle DI data files as described in the manual. You will need ‘get_image_data,’ ‘di_version,’ ‘di_header_find,’ and ‘extract_num’ to read DI data into a MatLab array. The two files ‘nano3read’ and ‘getparameter’ are the original copyrighted source code for each of the files as indicated.
- nano3read.m (original source code for get_image_data)
- getparameter.m (orig. code for di_header_find and extract_num)
Calculating Friction vs Load (UPDATED DEC. 2010) The most important script to analyze your FvL data is ‘friction_v_load_new.’ To process large batches of data, use ‘batch_process’ (see the manual). File ‘latcal’ is a Mathcad file that uses the output of the Lateral Calibration function of ‘friction_v_load’ to find the ratio between normal and lateral calibration factors.
- friction_v_load_new (Matlab file – save this file, then change the “.txt” extension to “.m” to use in Matlab) UPDATED DEC., 2010
- batch_process.m (Matlab file)
- friction_v_load_new_stripped.m (MatLab file to find the ratio of lateral and normal calibration factors)
- If you wish to use latcal.mcd (a MathCad file) instead of “friction_v_load_new_stripped.m“, then download this file: latcal, then re-name it with the extension “.mcd” and open in MathCad.
Measuring Pull-Off Forces (UPDATED JULY, 2010) The following files are applicable to force-distance data files only. The output of ‘getfd’ is the pull-off force in volts and the slope of the contact region of a force curve (normal signal deflection sensitivity in volts per nm).
batchfd_new.m is the actual code that you run. This one allows you to run the analysis on a series of force-distance curves. It uses either getfd_new.m or getfd_new_oldNanoscope.m to do the analysis (you can change this on line #48 in batchfd_new.m).
If you are using a newer version of Nanoscope (v6.x), use getfd_new, and if you are using an older version, use the getfd_new_oldNanoscope one. To use batchfd_new.m as-is, all the base names of the files need to be the same, and the file extensions should be consecutive (e.g., forcecurve.000, forcecurve.001, forcecurve.002 …). So you will first pick the first file, and then you will tell the program what the extension is on the last file in the sequence. When you run the code, it will show you each force-distance curve, and it will put some markers on the plots. The green and blue markers indicate the range over which the in-contact slope is calculated (V/nm). The red marker indicates the pull-off point. The black marker indicates what the out-of-contact voltage is, and it’s positioned directly above the pull-off point. The code will then display the average pull-off deflection (nm) and its standard deviation. A file is saved that contains the slope (V/nm), pull-off voltage (V), pull-off deflection (nm), and max deflection (nm). If you use Kaleidagraph, you can drag this file into Kaleidagraph (using Space as the delimiter, skipping 0 lines, and reading the titles).
For your convenience, all Matlab and Mathcad files are zipped here: SWfiles (note: this ZIP file does not include the new versions of getfd and batchfd. Upload those directly above. Sorry for the inconvenience.)