-1

I wrote in this way:

\documentclass[11pt]{article}

\usepackage{amsmath,amssymb}

\usepackage{tikz-cd}

\usepackage[all,cmtip]{xy}

\usepackage{geometry}

 \geometry{

 a4paper,

 total={170mm,257mm},

 left=20mm,

 top=15mm,
 }
 \begin{document}

and I have a lot of errors of types

''Please use \mathaccent for accents in math mode. ...el \^{i}n\c^{a}t fiecare este prieten\u{a}''

or

''You can't use `\spacefactor' in math mode. ...el \^{i}n\c^{a}t fiecare este prieten\u{a}''

leandriis
  • 62,593
rafa
  • 99

2 Answers2

2

It seems you inadvertently ended up in mathematics mode (special LaTeX mode for mathematical formulae), thus the complaints. Check if you opened an inline equation (e.g. by a $ or \() that you haven't closed (with a $ respectively \)). Or perhaps you are using $this text in italics$ (that doesn't work right, while the mathematics fonts are sort-of-italics, the letter spacing is all wrong -- a word is handled as a string of one-letter variables multiplied --; use \textit{italics text}or better \emph{emphasized text}).

vonbrand
  • 5,473
2

(This should really be a comment, but it's easier to explain with more flexible formatting.)

Both error messages show this input string:

\^{i}n\c^{a}t

It isn't shown as math (it isn't between $...$), but some elements will be interpreted as math, and latex will switch to math mode when that happens.

If the switch to math mode was made before this string was encountered, the two text accents \^ (circumflex) and \c (cedilla) will be found invalid, not permitted in math mode. If the precessing gets that far without problems, the ^ will be found invalid as it is permitted only in math mode, and latex will switch into math mode. So there's a problem either way.

Actually, I suspect that the switch to math mode occurred before this string, but you haven't shown the whole message. If you will provide a compilable example that demonstrates the errors you show, that will make it much easier to experiment and identify the real problem.