# Missing $inserted. …3mm]{\includegraphics[width=4.002cm]{6a}} I can not remove this error: Missing$ inserted. ...

\usepackage{subfig}
\usepackage{graphicx}
\graphicspath{ {D:/Users/test/} }


and my code is:

\begin{figure}[t]
\centering
\subfloat[\kappa_1=0.01mm]{\includegraphics[width=4cm]{6a}}
\hfill
\subfloat[\kappa_2=0.02mm]{\includegraphics[width=3.9cm]{6b}} \\
\caption{Test}\label{foo}
\end{figure}

• Welcome to TeX.SE! Please as usual here show us a short compilable code we can test on our own computer. Have you tried to use \subfloat[$\kappa_1$=0.01mm]{\includegraphics[width=4cm]{6a}}? – Mensch Oct 22 '18 at 1:51

You need to use $\kappa_1$ and $\kappa_2$ to get rid of that error message.

See the following mwe:

\documentclass{article}

\usepackage{subfig}
\usepackage{graphicx}

\begin{document}
\begin{figure}[t]
\centering
\subfloat[$\kappa_1$=0.01mm]{\includegraphics[width=4cm]{example-image-a}}
\hfill
\subfloat[$\kappa_2$=0.02mm]{\includegraphics[width=3.9cm]{example-image-b}} \\
\caption{Test}\label{foo}
\end{figure}
\end{document}


and its result: