Math & ScienceBad math environment error

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
pclarkUH3770
Posts: 1
Joined: Sat Sep 02, 2023 4:22 am

Bad math environment error

Post by pclarkUH3770 »

I'm getting Bad math environment delimiter error for the entry below. It is also telling me that I have missing \endgroup inserted, <inserted text>. The output is typeset correctly, but the error is still showing??? Can anyone assist?


\documentclass[11pt]{article}
\newcommand{\Rho}{\mathrm{P}}

\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}

\begin{document}

\begin{equation}
\boldsymbol{\dot{\hat\rho}}=\[[\boldsymbol\omega\times]\boldsymbol{\hat\rho}_0}
\end{equation}

\end{document}

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

rais
Posts: 419
Joined: Sun Nov 16, 2014 8:51 pm

Bad math environment error

Post by rais »

Hello and Welcome aboard :)
Your \[ (just after the equal sign) tries to start a new (displayed) math environment, but you're already in math mode.
The last closing brace has no partner, either.
BTW: you're defining \Rho, but you're using \rho. Since (La)TeX is case-sensitive, the definition of \Rho is superfluous at best.

Code: Select all

\documentclass[11pt]{article}
%\newcommand{\Rho}{\mathrm{P}}

\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}

\begin{document}

\begin{equation}
\boldsymbol{\dot{\hat\rho}}=[\boldsymbol\omega\times]\boldsymbol{\hat\rho}_0%}
\end{equation}

\end{document}
should work without error.
KR
Rainer
Post Reply