# Question:problem generating latex for hbar.

## Question:problem generating latex for hbar.

Maple 2021

Maple generates latex for hbar as  \mathit{hbar}  instead of just \hbar which makes it not render in PDF.  Here is an example

expr:= hbar*x;
latex(expr)


The screen display is correct. But not the latex. When compiling the above in Latex this is the output

\documentclass[12pt]{article}
\usepackage{amssymb}

\begin{document}

%Maple generated
$\mathit{hbar} x$

%default
$\hbar x$

%need amssymb for this
$\hslash x$
\end{document}

Compiling the above gives

So to use the standard hbar,  \mathit should not be used around it.

ps. I like \hslash more myself than \hbar , so if there is a choice, will vote for \hslash for latex.

Maple 2021, windows 10.

Physics:-Version()
The "Physics Updates" version in the MapleCloud is 973 and is

the same as the version installed in this computer, created

2021, May 3, 18:54 hours Pacific Time.

﻿