LaTeX forum ⇒ General! LaTeX Error: This file needs format `pLaTeX2e' with Japanese jarticle template

LaTeX specific issues not fitting into one of the other forums of this category.
ririro93
Posts: 3
Joined: Wed Jan 25, 2017 3:43 pm

! LaTeX Error: This file needs format `pLaTeX2e' with Japanese jarticle template

Postby ririro93 » Wed Jan 25, 2017 4:54 pm

I just started today and I have no idea how to fix this error. I'm tyring to build my template for an article by using Texmaker(And I downloaded MikTeX 2.9). It have lots of Japanese in it and I think it was originally made from Linux(I'm new so I don't know if this can be the cause but maybe I have errors because I use Windows instead of Linux). I know there's nothing wrong with the template file itself because it works well on the Linux computers in my lab.

The template starts like this

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \documentclass[twocolumn,9pt]{jarticle}
  2. \usepackage{amsmath}
  3. \usepackage{here,jsmea4p2,txfonts,overcite}
  4. \usepackage[dvipdfmx]{graphicx}
  5. %\usepackage[dvips,draft]{graphicx}
  6. \usepackage[dvips]{psfrag}
  7. \usepackage{subfigure}
  8. \usepackage{url}
  9. \usepackage{bm}
  10. \newfont{\cmss}{cmss10 scaled\magstep2}
  11. \def\空白{\hspace*{1zw}}
  12. \renewcommand\citeform[1]{#1)}
  13. \def\Frac#1#2{\displaystyle\frac{#1}{#2}}
  14. \def\d{{\rm d}}
  15. % \makeatletter
  16. % \renewcommand{\@biblabel}[1]{#1)}
  17. % \makeatother
  18.  
  19. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  20. % 初期設定
  21. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  22. %% 著者の人数
  23. \jauthorNm{4}
  24. %% 論文タイトル(欧文) 記入しないとき \etitleNm{0}にする
  25. \etitleNm{1}
  26. %% 欧文の氏名と所属 記入しないとき \jauthorEn{0}にする
  27. \jauthorEn{0}
  28. %% 連絡先 記入しないとき \addressNm{0}にする
  29. \addressNm{0}
  30. %% アブストラクト 記入しないとき \addressNm{0}にする
  31. \abstractNm{0}
  32. %% キーワード 記入しないとき \KeywordNm{0}にする
  33. \KeywordNm{0}
  34. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  35.  
  36.  
  37. %% 論文タイトル(和文)
  38. \jtitle{\LARGE{多重安定性を有する小自由度力学系の\\構造転移ダイナミクスに関する研究}}
  39. %% 論文タイトル(欧文)
  40. \etitle{A study on dynamics of structural transition\\ in small-degree-of-freedom dynamical systems with multiple stability }
  41. %% 公演番号
  42. \talknumber{3P12}
  43.  
  44. %% a.発表者に○ b.資格 c.氏名 d.所属 e.氏名(欧文)f.所属(欧文)
  45. %% 著者A
  46. \jauthorAa{○}
  47. \jauthorAb{学}
  48. \jauthorAc{岡本 和大}
  49. \jauthorAd{(阪   大)}
  50. \jauthorAe{Naoki H{\footnotesize IGASHIYAMA}}
  51. % \jauthorAf{School of Engineering,Osaka University\\ 2-1 Yamadaoka,
  52. % Suita, Osaka 565-0871}
  53. %\jauthorAf{Department of Adaptive Machine Systems, \\
  54. % Graduate School of Engineering, Osaka University \\
  55. % 2-1 Yamadaoka, Suita, Osaka 565-0871, Japan }
  56. \jauthorAf{ Osaka University, 2-1 Yamadaoka, Suita, Osaka 565-0871}
  57.  
  58. %% 著者B
  59. \jauthorBa{}
  60. \jauthorBb{正}
  61. \jauthorBc{土 井 祐 介}
  62. \jauthorBd{(阪 大 工)}
  63. \jauthorBe{Yusuke D{\footnotesize OI}}
  64. \jauthorBf{Osaka University}
  65. %% 著者C
  66. \jauthorCa{}
  67. \jauthorCb{正}
  68. \jauthorCc{中 谷 彰 宏}
  69. \jauthorCd{(阪 大 工)}
  70. \jauthorCe{Akihiro N{\footnotesize AKATANI}}
  71. \jauthorCf{Osaka University}
  72. %% 著者D
  73. \jauthorDa{}
  74. \jauthorDb{}
  75. \jauthorDc{}
  76. \jauthorDd{}
  77. \jauthorDe{}
  78. \jauthorDf{}
  79. %% 著者E
  80. \jauthorEa{}
  81. \jauthorEb{}
  82. \jauthorEc{}
  83. \jauthorEd{}
  84. \jauthorEe{}
  85. \jauthorEf{}
  86. %% 著者F
  87. \jauthorFa{}
  88. \jauthorFb{}
  89. \jauthorFc{}
  90. \jauthorFd{}
  91. \jauthorFe{}
  92. \jauthorFf{}
  93. %% 連絡先
  94. \address{FAX:06-6879-7246\hspace*{2em}E-mail:{\tt nakatani@.ams.eng.osaka-u.ac.jp}}
  95. % アブストラクト
  96. \abstract{
  97. }
  98. %% キーワード
  99. \Keyword{}
  100.  
  101. \pdfNm{0}
  102.  
  103. \begin{document}


Sorry for the long code. I don't know which ones might be causing the trouble so I just pasted everything. The errors say, to list a few at the top,

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. ! LaTeX Error: This file needs format `pLaTeX2e'
  2. but this is `LaTeX2e'
  3.  
  4. ! Illegal unit of measure (pt inserted).
  5. <to be read again>
  6. z
  7. l.31 \setlength{\parindent}{1zw}
  8. Dimensions can be in units of em, ex, in, pt, pc,
  9. cm, mm, dd, cc, nd, nc, bp, or sp; but yours is a new one!
  10. I'll assume that you meant to say pt, for printer's points.
  11. To recover gracefully from this error, it's best to
  12. delete the erroneous units; e.g., type `2' to delete
  13. two letters. (See Chapter 27 of The TeXbook.)
  14. ! LaTeX Error: Missing \begin{document}.
  15. See the LaTeX manual or LaTeX Companion for explanation.
Last edited by Stefan Kottwitz on Wed Jan 25, 2017 4:58 pm, edited 1 time in total.

Tags:

User avatar
Stefan Kottwitz
Site Admin
Posts: 9444
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Wed Jan 25, 2017 5:08 pm

Hi,

welcome to the forum!

The document class jarticle.cls requires pLaTeX (or the extended version upLaTeX). That's a LaTeX version with specific Japanese support. You need to change the command for compiling in your editor. Open the settings for Texmaker via the menu, in "Configure Texmaker" it looks like this:

configure-texmaker.png
configure-texmaker.png (107.92 KiB) Viewed 6953 times


In the first field, replace latex by platex or by uplatex.

Stefan
Site admin

ririro93
Posts: 3
Joined: Wed Jan 25, 2017 3:43 pm

Postby ririro93 » Wed Jan 25, 2017 5:23 pm

Thank you for the quick reply!
But I tried changing latex to both platex and uplatex and neither of them worked.
I attached a screenshot of the error message I got hoping it would give some hints.
Attachments
Document  CUserst61Desktopmy texmy ronbun.png
Document CUserst61Desktopmy texmy ronbun.png (92.57 KiB) Viewed 6950 times

User avatar
Stefan Kottwitz
Site Admin
Posts: 9444
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Wed Jan 25, 2017 5:56 pm

The error message still shows that you are not yet using pLaTeX. The other error messages can be consequences or can have other reasons.

Stefan
Site admin

ririro93
Posts: 3
Joined: Wed Jan 25, 2017 3:43 pm

Postby ririro93 » Wed Jan 25, 2017 6:37 pm

ok so do you have any other suggestions on how I can use pLaTeX?

User avatar
Stefan Kottwitz
Site Admin
Posts: 9444
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Wed Jan 25, 2017 7:04 pm

The same suggestion: configure platex in Texmaker. The error message shows that platex is not yet used. Besides configuring it, of cause that way of compiling (LaTeX to DVI) has to be used. PDF can be created via dvipdfmx.

Besides Texmaker, you could use another editor, or compile from the command prompt using the command platex documentname.

Stefan
Site admin

Rainwood1234
Posts: 1
Joined: Tue Aug 13, 2019 10:22 am

Postby Rainwood1234 » Tue Aug 13, 2019 10:26 am

You cannot use pdflatex for japanese input.

You always have to convert a file inbetween:
tex -> dvi -> pdf

@Settings for texmaker:
- Open options for "Quick build"
- Select: "LaTeX + dvips + ps2pdf + ViewPDF"

In general: make sure whatever command you're running, you have LaTeX in there, not PdfLatex. Otherwise the changed latex command (that you changed to platex) will not have any effect.


Return to “General”

Who is online

Users browsing this forum: No registered users and 13 guests