.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "auto_examples/plot_tip_calibration.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr_auto_examples_plot_tip_calibration.py: Indentation Tip Calibration =========================== This example calibrates a tip from Agilent calibration measurements and uses the calibrated tip to initialize a measurement file. .. GENERATED FROM PYTHON SOURCE LINES 8-18 .. code-block:: Python from pathlib import Path import micromechanics from micromechanics.indentation import Indentation repository_root = Path(micromechanics.__file__).resolve().parents[1] calibration_file = repository_root / "examples/Agilent/FS_Calibration.xls" measurement_file = repository_root / "examples/Agilent/NiAl_250nm_TUIL_max_depth_1000nm_GM3_SM_previousGM1.xls" .. GENERATED FROM PYTHON SOURCE LINES 19-22 Inspect the calibration measurements first. ``analyse`` evaluates the current test, and ``K2P`` plots stiffness squared over load, a common diagnostic for frame stiffness and tip-area calibration quality. .. GENERATED FROM PYTHON SOURCE LINES 22-27 .. code-block:: Python calibration = Indentation(str(calibration_file), nuMat=0.18) calibration.analyse() calibration.plotAsDepth("K2P") .. image-sg:: /auto_examples/images/sphx_glr_plot_tip_calibration_001.png :alt: plot tip calibration :srcset: /auto_examples/images/sphx_glr_plot_tip_calibration_001.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out .. code-block:: none Open Agilent file: /home/runner/work/micromechanics/micromechanics/examples/Agilent/FS_Calibration.xls Fit: K2P=714+ -21*h .. GENERATED FROM PYTHON SOURCE LINES 28-31 Fit the frame stiffness and tip shape. ``plotStiffness`` shows the frame correction step; ``plotTip`` shows the calibrated tip shape against the reference geometry. .. GENERATED FROM PYTHON SOURCE LINES 31-34 .. code-block:: Python calibration.calibration(plotStiffness=True, plotTip=True) .. rst-class:: sphx-glr-horizontal * .. image-sg:: /auto_examples/images/sphx_glr_plot_tip_calibration_002.png :alt: plot tip calibration :srcset: /auto_examples/images/sphx_glr_plot_tip_calibration_002.png :class: sphx-glr-multi-img * .. image-sg:: /auto_examples/images/sphx_glr_plot_tip_calibration_003.png :alt: plot tip calibration :srcset: /auto_examples/images/sphx_glr_plot_tip_calibration_003.png :class: sphx-glr-multi-img * .. image-sg:: /auto_examples/images/sphx_glr_plot_tip_calibration_004.png :alt: plot tip calibration :srcset: /auto_examples/images/sphx_glr_plot_tip_calibration_004.png :class: sphx-glr-multi-img .. rst-class:: sphx-glr-script-out .. code-block:: none Start compliance fitting fit f(x)= 0.0378 *x+ 4e-05 frame compliance: 4.3469e-05 um/mN = 4.3469e-08 m/N compliance and stiffness standard error in %: 20.24 frame stiffness: 23005 mN/um = 2.30e+07 N/m **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. Tip shape: **DEPRECATION** For backward compatibility, use tip.areaPrefactors instead. iterated prefactors [26.0, 309.1, 2023.8] standard error [0.03, 57.53, 833.63] True .. GENERATED FROM PYTHON SOURCE LINES 35-38 Reuse the calibrated tip for a measurement file. Passing ``tip=calibration.tip`` ensures the later analysis uses the area function found from the calibration workbook instead of the default ideal tip. .. GENERATED FROM PYTHON SOURCE LINES 38-40 .. code-block:: Python measurement = Indentation(str(measurement_file), tip=calibration.tip) .. rst-class:: sphx-glr-script-out .. code-block:: none Open Agilent file: /home/runner/work/micromechanics/micromechanics/examples/Agilent/NiAl_250nm_TUIL_max_depth_1000nm_GM3_SM_previousGM1.xls .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 1.218 seconds) .. _sphx_glr_download_auto_examples_plot_tip_calibration.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_tip_calibration.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_tip_calibration.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_tip_calibration.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_