3

I am writing a paper for an IEEE conference using IEEEtran.cls. The primary language of the paper is English but my work deals with Bengali language. I want to know how do I insert some Bengali words such as পারে in the paper.

Arun Debray
  • 7,126
  • 2
  • 30
  • 54

2 Answers2

6

You should use XeTeX or luaTeX and your font should support Bengali. I have used Mukti Narrow (I had issues with Free Serif, whitout fontspec package):

\documentclass{article}
\font\beng="Mukti Narrow Bold:script=beng"

\begin{document}

This is Bengali: {\beng পারে}

\end{document}

This is an example from ieeetran class, which works just fine:

\documentclass[conference]{IEEEtran}
\font\beng="Mukti Narrow Bold:script=beng"

\ifCLASSINFOpdf
\else
\fi
\hyphenation{op-tical net-works semi-conduc-tor}
\begin{document}
\title{Bare Demo of IEEEtran.cls for Conferences}
\author{\IEEEauthorblockN{Michael Shell}
\IEEEauthorblockA{School of Electrical and\\Computer Engineering\\
Georgia Institute of Technology\\
Atlanta, Georgia 30332--0250\\
Email: http://www.michaelshell.org/contact.html}
\and
\IEEEauthorblockN{Homer Simpson}
\IEEEauthorblockA{Twentieth Century Fox\\
Springfield, USA\\
Email: homer@thesimpsons.com}
\and
\IEEEauthorblockN{James Kirk\\ and Montgomery Scott}
\IEEEauthorblockA{Starfleet Academy\\
San Francisco, California 96678-2391\\
Telephone: (800) 555--1212\\
Fax: (888) 555--1212}}
\maketitle

\begin{abstract}
The abstract goes here.
\end{abstract}

\IEEEpeerreviewmaketitle



\section{Introduction}
This demo file is intended to serve as a ``starter file''
for IEEE conference papers produced under \LaTeX\ using
IEEEtran.cls version 1.7 and later.

{\beng অপ্রিয় বাক্য এড়িয়ে মধুর ব্যবহারে কার্যোদ্ধার।}

I wish you the best of success.

\hfill mds

\hfill January 11, 2007

\subsection{Subsection Heading Here}
Subsection text here.


\subsubsection{Subsubsection Heading Here}
Subsubsection text here.

\section{Conclusion}
The conclusion goes here.
\section*{Acknowledgment}


The authors would like to thank...

\begin{thebibliography}{1}

\bibitem{IEEEhowto:kopka}
H.~Kopka and P.~W. Daly, \emph{A Guide to \LaTeX}, 3rd~ed.\hskip 1em plus
  0.5em minus 0.4em\relax Harlow, England: Addison-Wesley, 1999.

\end{thebibliography}

\end{document}

This is part of the output that contains the Bengali text:

Bengali Text in IEEEtran LaTeX class

Ho1
  • 1,302
  • but the output of the word is not correct – Saprativa Bhattacharjee Jul 02 '15 at 19:23
  • Do you have Free Serif font installed? It is available on Linux, but if you are on windows, you can use Shonar Bangla : http://www.microsoft.com/typography/fonts/font.aspx?FMID=1799 . You should also be sure that this font exists where your article is typesetted. – Ho1 Jul 02 '15 at 19:38
  • can you tell me how do I specify the script=bengali? – Saprativa Bhattacharjee Jul 02 '15 at 19:48
  • You don't need to do so. You need a font that have Bengali characters. Download GNU FreeFont from here: http://ftp.gnu.org/gnu/freefont/freefont-ttf.zip . Want to know more? See this: https://en.wikipedia.org/wiki/GNU_FreeFont – Ho1 Jul 02 '15 at 19:59
  • I have the FreeSerif font installed on my system and I am getting the Bengali characters in the PDF output but the problem is instead of getting পারে (correct form), I am getting http://prntscr.com/7o7qp1 as output (wrong form). – Saprativa Bhattacharjee Jul 03 '15 at 04:03
  • The same problem is mentioned in Section 9.18.1 (Page no. 35) of the fontspec manual: http://ctan.imsc.res.in/macros/latex/contrib/fontspec/fontspec.pdf – Saprativa Bhattacharjee Jul 03 '15 at 04:46
  • Where should or how should I mention the Script=Bengali option? – Saprativa Bhattacharjee Jul 03 '15 at 04:47
  • 1
    Just before the font name. I have fixed the example. You can also define a font family and use it in a document where most of the text is English. – Ho1 Jul 03 '15 at 10:55
  • Thanks a lot. I am using the \newfontfamily command as I just have a few Bengali words to be inserted in a English document. But the problem now is that the font for the English part has changed and it does not look like an IEEE paper anymore. – Saprativa Bhattacharjee Jul 03 '15 at 16:03
  • You should have the command inside braces {}. Test the example again. – Ho1 Jul 03 '15 at 18:01
  • The problem still persists. – Saprativa Bhattacharjee Jul 03 '15 at 18:30
  • Original font of IEEEtran: http://prntscr.com/7ofuif Modified font with Bengali text inserted: http://prntscr.com/7ofvd6 – Saprativa Bhattacharjee Jul 03 '15 at 18:32
  • 1
    Do it without fontspec package: \font\beng="FreeSerif". I changed the example, tested with ieeetran and it worked fine – Ho1 Jul 03 '15 at 19:09
  • some of the word forms are getting changed...may be it has got to do something with the font...i am not sure...correct form should be like this: http://prntscr.com/7onc34 but i am getting this as the output: http://prntscr.com/7oncib the 1st, 2nd and 5th words are getting changed – Saprativa Bhattacharjee Jul 04 '15 at 08:12
  • Can you paste the text here? – Ho1 Jul 04 '15 at 10:08
  • অপ্রিয় বাক্য এড়িয়ে মধুর ব্যবহারে কার্যোদ্ধার। – Saprativa Bhattacharjee Jul 04 '15 at 10:32
  • I have added an example from IEEEtran class, it works just fine for me, but you have to make sure that the font is available where the actual output is being made, for example on the submission server. – Ho1 Jul 04 '15 at 11:28
  • can you please show me the screenshot of your pdf output – Saprativa Bhattacharjee Jul 04 '15 at 15:08
  • Just added to the answer. – Ho1 Jul 04 '15 at 17:31
  • I am getting the same output but the forms of the words 1, 2 and 5 are not as expected. These should have been like this : http://prntscr.com/7onc34 – Saprativa Bhattacharjee Jul 04 '15 at 17:42
  • 1
    Maybe it is a font problem. I could get the right output with \font\beng="Mukti Narrow". Please not that script=beng is not necessary, but I provided this to note that you should use "beng" here instead of Bengali, if you want to use it. – Ho1 Jul 04 '15 at 18:11
  • 1
    Great! If you want to sumbit your paper to a conference, then you have to make sure that they have the needed fonts. Usually, you can see the output in the paper submission system. – Ho1 Jul 04 '15 at 19:12
  • okay..thnx for the awesome help. – Saprativa Bhattacharjee Jul 05 '15 at 05:00
1

You can use any font you want. You just need the ttf file of that font and XeLaTeX compiler. Follow my answer to another question of similar type.