\PassOptionsToPackage{quiet}{fontspec}
\documentclass[12pt,a4paper]{article}
\usepackage{thesis} % 格式控制
\usepackage{indentfirst}
\setlength{\parindent}{2em} % 控制首行缩进
\addtolength{\parskip}{3pt} % 控制段落距离
\onehalfspacing % 1.5倍行距
\graphicspath{{./figures/}} % 指定图片所在文件夹
\InputIfFileExists{config.tex}{}{\errmessage{Missing config.tex}}
\makepagestyle{\printname\ \printid}{\printclass ~实验报告}
\begin{document}
\maketitlepage{\printexpname}{\printlocation}{\printname}{\printid}{\printdate}{\printteacher} %封面页
\maketoc %目录页
\section{实验目的和要求}
\begin{enumerate}
\item 了解用集成运算放大器构成简单的正弦波、方波、三角波发生电路的方法。
\end{enumerate}
\section{主要仪器设备}
\begin{table}[htbp]
\centering
\begin{tabular}{ccp{20em}}
\toprule
编号 & 仪器用具名称 & 主要参数(型号,测量范围,测量精度等) \\
\midrule
1 & 数字万用表\\
2 & 直流稳压电源\\
3 & 电子技术实验箱\\
4 & 示波器\\
5 & 函数信号发生器\\
6 & 运放LM358\\
\bottomrule
\end{tabular}%
\label{tab:device}%
\end{table}%
\clearpage % 换页
\section{实验内容和原理}
\zhlipsum[5]
\clearpage
\section{实验结果}
\zhlipsum[5]
\clearpage
\section{实验探究}
\zhlipsum[5]
\begin{problem}
adsfa
\end{problem}
\begin{solution}
\end{solution}
\begin{lstlisting}[language=Python, caption=Python example]
def hello_world():
print("Hello, world!")
\end{lstlisting}
\begin{figure}[htbp]
\centering
\includegraphics[width=0.4\linewidth]{example.png}
\caption{example image}
\end{figure}
\clearpage
\appendix
\section{附录1:文档结构}
\begin{lstlisting}
Latex_exp/
├── thesis.tex # 主文件,包含报告正文
├── thesis.sty # 文档格式控制,包括页面设置、样式定义等
├── config.tex # 配置文件,包含个人信息、课程名称等设置
├── ref.bib # 参考文献列表
├── Makefile # 编译脚本
├── figures/ # 图片文件夹
│ ├── char.png # 字符图片
│ ├── example.png # 示例图片
│ └── logo.png # ZJU LOGO
├── thesis.pdf # 生成的 PDF 文件(编译后自动复制到根目录)
├── build/ # 编译输出目录(自动生成,包含所有辅助文件)
└── README.md # 项目说明文档
\end{lstlisting}
\clearpage
\section{附录2:版本更新记录}
\clearpage
\reference
\end{document}

PDF Preview
Create an account to compile and preview