LaTeX 板


LINE

恭賀LaTeX開板, 在此分享一下我論文的撰寫過程, 部份文章內容copy我從phD板上po過 但未被m的文章內容, 本文章並非著重於LaTeX技巧, 而是一套"研究生LaTeX+Win+Office" 使用心得, 你如何在 Word/PowerPoint/Visio 及 LaTeX 間取得良好平衡, 並幫你無往 不利的完成paper/presentation preparation (至少對我而言成立). 註:我稱不上LaTeX高手,這不是唯一的方法,這套方法也不一定完全適用於你/妳, 但也許對你/妳有參考價值 作業系統: Win XP 使用軟體: MS-OFFICE 2003 Word/PowerPoint/Visio MikTeX 2.4.x WinEdt 5 (I recommend it because its project management capabilities) PDF standard 6.0/7.0 or Pro + PS reader ghostview Matlab 6 to 7 (eps; C/C++ guides usually love to use Matlab's plot function) cwTeX (optional if you really need to generate chinese document) Environmental setup: Matlab/office installation is independent to that of LaTeX. 先後順序 MikTeX/PDF/PS reader 平行 => WinEdt => cwTeX (不使用中文可不安裝) Matlab設定=>preference=>FigureCopyTemplate=>CopyOptions clipboard format 選擇 preserve information Figure Background Color 選擇 ForceWhite or Transparent background 當你使用畫圖在Figure Window時 Edit=>Copy Figure, 貼到PowerPoint時, 不會有灰色背景 編輯軟體使用時機(類似當兵的用槍時機x條):constraint "preparation time/quality" 1. 數學式多準備時間夠長,投稿單位為Journal/conference(好的國際期刊/會議),使用 LaTeX + WinEdt 2. 普通技術報告且文字多於數學式例如conference急件(2-7天),國科會報告使用word 3. 任何中文文件用word,相信我我用過cwTeX編過補習班講義400頁, 莫名奇妙的亂碼暴走痛苦阿,但我還是咬牙苦撐完成,吳教授我做到了!! 4. 非LaTeX不用的人, 1-3都用LaTeX..... XD 如何準備圖片檔eps for LaTeX, 及教戰守則 1. 我發誓我絕對不在LaTeX文件中插入 .jpg/.png 圖片 (如何插入jpg/png檔方法詳見吳老師網站bitmap.pdf) 2. 所有非eps/ps圖片都先轉成PDF, 如果在PDF上看不到好的效果, LaTeX也不會好 因此極盡所能將原始圖片(例如你/妳掃描某文件的圖...)的quality調好, 轉成PDF 後,可以修修邊界調整空白區大小,在另存新檔時選擇.eps(設定可以需要調整) 3. 利用PowerPoint/Visio繪製圖形的人,也是先轉成PDF調整邊界後再轉存成eps 別小看這點, 想想你可以利用PowerPoint/visio建立元件庫, 以後做presentation 寫論文, 寫paper都只要做點小修改或重新組合元件而不必重畫, PowerPoint 與 LaTeX都用同一版本的圖, 也不必因為你要用LaTeX而重畫 4. 其他研究生朋友有使用TextPoint之類軟體可在PowerPoint上插入LaTeX數學式, 超好用的拉 5. Matlab畫完圖後(可支援部份LaTeX)有兩條路 5.1 Matlab 6:export=>.eps 檔 Matlab 7: save as => .eps 檔 or export setup=> export => .eps 這是直接將Matlab畫的圖直接轉成eps給LaTeX,這是最佳的選擇,稍後再補充 Matlab圖形編輯技巧 5.2 很多時候Matlab output並不能滿足你的需求, 例如你需要合併Matlab輸出圖形與 其他圖形, 這時候我推薦在PowerPoint上完成, 首先利用copy figure將圖存在 PowerPoint上並解除群組(2次)把不要的東西移除,(你會發現Matlab圖上的字變成 文字方塊,其他則為線條), 然後加入你想要的文字、符號、圖形,編輯好再轉成 PDF=>EPS。 若你要使用Word編輯時記得轉成"Windows增強型中繼檔"後再貼上, 記得要調整word文字 行距大小不然會被切掉看不到,以為圖有問題 6. 依照前面執行一段時間,你會發現圖形部分你只有PowerPoint和Matlab 的.fig需要管理 需要用到eps時可立刻修改或調整 補充: Matlab Figure window 其實可以用來編輯所有Matlab所畫圖形, 例如說你需要兩張圖放 在一起, 首先你先個別畫好兩張或畫在同一Figure Window上, 你對於他的間距字型 滿意嗎? 通常太寬了些, 你可以 "unlock" 圖形, 然後任意調整圖片外框大小, 你 也可將某張圖unlock後 copy(Ctl+C) 或某條曲線(注意scale是否相同),貼到另一張 圖上, 再插入 (a) (b) + 註解等文字, 你也可以省去在LaTeX上的一些麻煩格式 設定。記得兩邊都要在"箭號"被按下後下執行喔(在 "A:插入文字" 旁邊那個) LaTeX論文撰寫簡介及教戰守則: 1.開頭到結尾,以IEEEtran為例 \documentclass[journal]{IEEEtran} //文件格式宣告 \usepackage{amsmath, array, amssymb, latexsym, graphics, cite} //include 元件 \begin{document} //文件開始 \title{ 文件標題名稱 } //這一段是在標題下的作者欄 及 第一頁第一個column下的作者簡介 \author{ Xx-Cc Bb,~\IEEEmembership{Student Member,~IEEE}, Your Boss,~\IEEEmembership{Senior Member,~IEEE}, and others \\ //換行 \thanks{Manuscript received Jan. 5, 2006, %revised June 15, 2005. % This research was supported in part by the National Science Council of Taiwan under Grant NSC-xx-xxxx-E-xxx-xxx and NSC-xx-xxxx-E-xxx-xxx}% <-this % stops a space \thanks{Xx-Cc Bb and Others are with Your institution} \thanks{Communication Author is the XXXX, Taiwan Taipei 106, Taiwan. (Tel: +886-x-xxxx-xxxx, Fax: +886-x-xxxx-xxxx, E-mail: [email protected])} } \markboth{Name of Journal:display on each odd page}{Xx-Cc. Bb {\em et al.}: Title of your paper: display on each even page} \maketitle //告訴LaTeX可以排title囉 \begin{abstract} 你的摘要 \end{abstract} \begin{keyword} 文章關鍵字 DPSK, PSK, ... \end{keyword} \section{Introduction} \PARstart{P}{hase}-modulated signal ...Bla Bla Bla //簡介第一個字一定要\PARstart Bla Bla This following sections of this paper is organized as .... \section{XXX} Bla Bla .... \section{XXX} Bla Bla .... \section{Conclusion} \begin{thebibliography}{10} //參考文獻區 \bibitem{gnauck02} //conference 範例(使用方法為 \cite{gnauck02}) A.~H. Gnauck, G.~Raybon, ....., and D.~M. Gill, ``2.5 {T}b$/$s (64 $\times$ 42.7 {G}b$/$s) transmission over 40 $\times$ 100 km {NZDSF} using {RZ-DPSK} format and all-{R}aman-amplified spans,'' in {\em Optical Fiber Commun. Conf.}, Optical Society of America, Washington, D.C., 2002. \newblock postdeadline paper FC2. \bibitem{gnauck05} //Journal 範例 A.~H. Gnauck and P.~J. Winzer, ``Optical phase-shift-keyed transmission,'' {\em J. Lightwave Technol.}, vol.~23, no.~1, pp.~115--130, 2005. \bibitem{recipe} //書籍範例 W.~H. Press, B.~P. Flannery, S.~A. Teukolsky, and W.~T. Vetterling, {\em Numerical Recipes in C}. \newblock Cambridge, UK: Cambridge Univ., 1992, ch. 10. \bibitem{agilent} //其他技術報告格式 Agilent App.~Note 1550-7: Making Time-Resolved Chirp Measurements Using the Optical Spectrum Analyzer and Digital Communications Analyzer, 2002. \bibitem{spectrogram} //如果你需要refer to wikipedia 的定義時 Spectrogram, Wikipedia Encyclopedia. \url{http://en.wikipedia.org/wiki/Spectrogram}. \end{thebibliography} \end{document} //結束囉 ^^" 2. bibtex (.bib) 檔案格式範例 在.tex最後加入下列兩行,就可以使用.bib囉(用以取代 thebibliography) \bibliographystyle{ieeetr} \bibliography{xxx .bib檔的檔案名稱,最好跟主要檔案放一起} % IEEE Journals. //定義一些縮寫字串 @String{ptl = "IEEE Photon. Technol. Lett."} @String{jlt = "J. Lightwave Technol."} @String{info = "IEEE Trans. Info. Theory"} @String{jstqe = "IEEE J. Sel. Top. Quantum Electron."} @String{jsac = "IEEE J. Sel. Areas Commun."} @String{jqe = "IEEE J. Quantum Electron."} @String{el = "Electron. Lett."} @String{com = "IEEE Trans. Commun."} @String{optcom = "Opt. Commun."} @String{rsi = "Rev. Sci. Instrum."} % OSA Journal @String{ol = "Opt. Lett."} @String{oe = "Opt. Express"} @String{josab = "J. Opt. Soc. Amer. B"} @String{josaa = "J. Opt. Soc. Amer. A"} @String{apb = "Appl. Phys. B"} % conference @String{ofc = "Optical Fiber Commun. Conf."} @String{ecoc = "European Conf. on Optical Commun."} % @String{osa = "Optical Society of America, Washington, D.C."} % Name @String{xxx = "x.-x. Xx"} //Journal @Article{dorrer05, //這是辨別字串 使用時為\cite{dorrer05} author = "C.~Dorrer and C.~R. Doerr and I.~Kang and R.~Ryf and J.~Leuthold and P.~J. Winzer", title = "Measurement of eye diagrams and constellation diagrams of optical sources using linear optics and waveguide technology", journal= jlt, //利用你前面定義過的字串 volume = "23", number = "1", pages = "178-186", year = "2005", } //Book @book{qian, author = "S. Qian", title = "Introduction to Time-Frequency and Wavelet Transforms", publisher = "Prentice Hall", address = "Upper Saddle River, NJ", year = "2001" } //網頁 @Book{spectrogram, title = "Spectrogram", publisher = "Wikipedia Encyclopedia.", url = "http://en.wikipedia.org/wiki/Spectrogram", } //技術報告 @Book{agilent, publisher = "Agilent App.~Note 1550-7, Making Time-Resolved Chirp Measurements Using the Optical Spectrum Analyzer and Digital Communications Analyzer", year = "2002", } 3. 常用樣版檔 3.1數學式 a=大括號 變兩行 (我最常被問的問題) \begin{equation} a = \left \{ \begin{array}[rr] (<= 有r l c 三種參數置右 置左 置中對齊) \cos(t) & t > 5 \\[x cm] (<= 兩行間隔大小控制) \sin(t) & t < 5 \end{array} \right . (<= 右邊不加框) \end{equation} 3.2 $\sum $ 與 \begin{equation} \sum \end{equation} 的差別 $$為文字中間顯示數學符號模式,下標會做調整, summation的上下限位置在符號左上及右下 \begin{eqution}\end{equation} or $$ $$ or \[ \] 為數學模式 summation的上下線位置在下方及上方 3.3 如何強制轉換數學符號由文字模式到數學模式 $ "\displaystyle"{ \sum } $ 應用: 在3.1的"兩行"為文字排版模式喔, 所以若要轉為數學排版模式, 加 displaystyle 即可 3.4 括號 請利用 \left\{ \left[ \left( \right) \right ] \right\}, 由LaTeX來決定 括號大小, 我以前都傻傻自己在 \big \Big \Bigg ..., 除非在某寫超長數學式換行時才會因為\left 對不到 \right產生error才需要自己決定 3.5 圖檔範例1 \begin{figure} \begin{center} //大小比例 // ./路徑/檔案名稱 "./"為根目錄 \includegraphics[width = 1 \textwidth]{./ch1/outline1.eps} \end{center} \caption{ 說明區 } \label{f1.outline} //類似取 bookmark \end{figure} 3.6 圖檔範例2 : 2x2 共四張圖 \begin{figure} \begin{center} \begin{tabular}{c} \includegraphics[width = 0.5 \textwidth]{./ch1/nrz-dpsk.tx.eps} \\ (a) DPSK transmitter \\[0.2cm] \includegraphics[width = 0.55 \textwidth]{./ch1/dpsk.hetero.rx.eps} \\ (b) Heterodyne DPSK receiver \\[0.2cm] \includegraphics[width = 0.5 \textwidth]{./ch1/dpsk.dd.rx.eps} \\ (c) Direct-Detection DPSK receiver \end{tabular} \end{center} \caption{Typical transmitter and receivers structure for optical DPSK signal.} \label{f1.dpsk.tx-rx} \end{figure} 呼!!! 累了 先這樣吧 下次在說明如何使用 WinEdt 管理論文 by project 以上, 有錯請指正 -- 研究所念書沒買過PC也不需網路, 租房子只到用床和浴室 畢業後工作決定買NB在家用ADSL, 結果還是只用床和浴室 人生像是C語言, do "making money" while "you awake" --
QR Code



※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.41.157 ※ 編輯: jackyw99 來自: 140.112.41.157 (08/30 16:28)
1F:推 radom:印象中對於3.4節中/left對不到/right,可以用"."來解決 08/30 17:21
2F:推 htl:推 08/31 09:30
3F:推 jackyw99:謝謝指正, \left ( \right.\\(換行) \left. \right ) 08/31 21:21







like.gif 您可能會有興趣的文章
icon.png[問題/行為] 貓晚上進房間會不會有憋尿問題
icon.pngRe: [閒聊] 選了錯誤的女孩成為魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一張
icon.png[心得] EMS高領長版毛衣.墨小樓MC1002
icon.png[分享] 丹龍隔熱紙GE55+33+22
icon.png[問題] 清洗洗衣機
icon.png[尋物] 窗台下的空間
icon.png[閒聊] 双極の女神1 木魔爵
icon.png[售車] 新竹 1997 march 1297cc 白色 四門
icon.png[討論] 能從照片感受到攝影者心情嗎
icon.png[狂賀] 賀賀賀賀 賀!島村卯月!總選舉NO.1
icon.png[難過] 羨慕白皮膚的女生
icon.png閱讀文章
icon.png[黑特]
icon.png[問題] SBK S1安裝於安全帽位置
icon.png[分享] 舊woo100絕版開箱!!
icon.pngRe: [無言] 關於小包衛生紙
icon.png[開箱] E5-2683V3 RX480Strix 快睿C1 簡單測試
icon.png[心得] 蒼の海賊龍 地獄 執行者16PT
icon.png[售車] 1999年Virage iO 1.8EXi
icon.png[心得] 挑戰33 LV10 獅子座pt solo
icon.png[閒聊] 手把手教你不被桶之新手主購教學
icon.png[分享] Civic Type R 量產版官方照無預警流出
icon.png[售車] Golf 4 2.0 銀色 自排
icon.png[出售] Graco提籃汽座(有底座)2000元誠可議
icon.png[問題] 請問補牙材質掉了還能再補嗎?(台中半年內
icon.png[問題] 44th 單曲 生寫竟然都給重複的啊啊!
icon.png[心得] 華南紅卡/icash 核卡
icon.png[問題] 拔牙矯正這樣正常嗎
icon.png[贈送] 老莫高業 初業 102年版
icon.png[情報] 三大行動支付 本季掀戰火
icon.png[寶寶] 博客來Amos水蠟筆5/1特價五折
icon.pngRe: [心得] 新鮮人一些面試分享
icon.png[心得] 蒼の海賊龍 地獄 麒麟25PT
icon.pngRe: [閒聊] (君の名は。雷慎入) 君名二創漫畫翻譯
icon.pngRe: [閒聊] OGN中場影片:失蹤人口局 (英文字幕)
icon.png[問題] 台灣大哥大4G訊號差
icon.png[出售] [全國]全新千尋侘草LED燈, 水草

請輸入看板名稱,例如:iOS站內搜尋

TOP