[Tex/LaTex] causing undefined control sequence

errors

I'm getting this error:

Undefined control sequence
1.67 ....ideology function $v_1 : A \to \R$, that represents....

which is from:

$v_i : A \to \R$

And this is my header:

\documentclass[smallextended]{svjour3}
\usepackage{latexsym}
\usepackage{graphicx} 
\usepackage{amssymb, amsmath,endnotes}
\usepackage{rotating}
\usepackage{color}
\usepackage[T1]{fontenc}
\usepackage{geometry}
\usepackage{tikz}
\usepackage{pgfplots}
\usepackage{tikz-3dplot}

Can somebody help me out with this one.

Best Answer

You don't have the macro \R defined. Presumably you want to represent a mapping from (the set A to the real domain. The latter is commonly defined using \mathbb{R}. As such, it would suffice to define

\newcommand{\R}{\mathbb{R}}

in your preamble:

enter image description here

\documentclass{article}
\usepackage{amssymb}
\newcommand{\R}{\mathbb{R}}
\begin{document}
$v_i : A \to \R$
\end{document}