I'm using ipython-notebook to convert my code to tex file and then to a pdf file, and an issue occurred when converting from the generated tex file to pdf (I've posted an issue here). The whole generated tex file is here.
Then I tried to find some other tools to convert tex to pdf, and I found pdftex under my cygwin\bin path (I'm on windows7), then I tried it, and again got errors:
D:\Documents\Desktop> pdftex CSMATH-hw1.tex
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Cygwin)
restricted \write18 enabled.
entering extended mode
(./CSMATH-hw1.tex
! Undefined control sequence.
l.10 \documentclass
[letterpaper,10pt,english]{d:/Anaconda/lib/site-packa...
?
! Undefined control sequence.
l.13 \usepackage
[utf8]{inputenc}
I've searched the tex.sx and find this post referred to pdfTeX and pdfLaTeX, but I don't find a pdfLaTex.exe on my machine. Thx in advance ;)
EDIT:
I found file D:\cygwin\bin\pdflatex on my machine, and find there is only one line in that file:
!<symlink>pdftex.exe
Then I try it in the cygwin terminal, like this:
zhangxaochen@zhangxaochen-PC /cygdrive/d/Documents/Desktop
$ pdflatex CSMATH-hw1.tex
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Cygwin)
restricted \write18 enabled.
entering extended mode
(./CSMATH-hw1.tex
LaTeX2e <2011/06/27>
Babel <3.9f> and hyphenation patterns for 78 languages loaded.
! LaTeX Error: File `d:/Anaconda/lib/site-packages/sphinx/texinputs/sphinxhowto
.cls' not found.
Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: cls)
Enter file name:
The file "d:/Anaconda/lib/site-packages/sphinx/texinputs/sphinxhowto.cls" does exist in my pc, so why I get such an error? Is it because of the Windows style path being not recognized?
EDIT2:
Indeed cygwin needs the *nix style path, I edited the path like:
d:/Anaconda/lib/site-packages/sphinx/texinputs/sphinxhowto
to:
/cygdrive/d/Anaconda/lib/site-packages/sphinx/texinputs/sphinxhowto
and now I can generate an pdf file from cygwin terminal, despite the Chinese characters could not be shown correctly:
! Package ucs Error: Unknown Unicode character 19968 = U+4E00,
(ucs) possibly declared in uni-78.def.
(ucs) Type H to see if it is available with options.
See the ucs package documentation for explanation.
Type H <return> for immediate help.
...
l.300 ...e, 浠ュ強鐢熸垚鐨勫甫鍣0鐐逛釜鏁▒ n, }
? h
Unicode character 19968 = U+4E00:
Contained in range 'CJK Ideograph'
Character available with following options:
cjkbg5, cjkgb, cjkjis.
Enter I!<RET> to define the glyph.
? I!<ret>
Please enter definition for unicode character 19968
\definition=
pdflatex. What TeX distribution do you have? How did you install it? It should be in the same place aspdftex... – mbork Apr 02 '14 at 05:00pdflatexis simply a!<symlink>pdftex.exein cygwin, see my edit plz – zhangxaochen Apr 02 '14 at 07:30"\\", and it didn't work. I had to change path to/cygdrive/d/.... – zhangxaochen Apr 02 '14 at 09:16