I am having a little but painful problem that is the registered trademark symbol in my thesis is going beyond the right margin (see the figure). I have noticed that if I do not use \addtolength command then the problem is solved. However, I am searching a solution using which the problem could be solved without removing the \addtolength.
\documentclass[12pt]{book}
\hoffset-7mm
\usepackage{amsmath,amsfonts,amssymb, amsthm}
%======================================================
\addtolength{\textwidth}{18mm}
\addtolength{\textheight}{10mm}
\addtolength{\topmargin}{-10mm}
\begin{document}
\begin{itemize}
\item The \textbf{Preprocessing time} means the average time taken, in seconds, by MATLAB{$^{\mbox{\small\textregistered}}$} to generate the constraint matrix and other parameters required to solve the model by the CPLEX{$^{\mbox{\small\textregistered}}$} solver.
\end{itemize}
\end{document}

MATLAB{$^{\mbox{\small\textregistered}}$}you probably wantMATLAB\textsuperscript{\textregistered}. – campa Oct 08 '19 at 15:30sloppyparenvironment: How to avoid using \sloppy document-wide to fix overfull \hbox problems? – barbara beeton Oct 08 '19 at 16:22