嗨,这是我用过的序言
\documentclass[prd,aps,superscriptaddress,twocolumn,10pt]{revtex4-1}
\usepackage{times}
\usepackage[a4paper, left=1.85cm, right=1.85cm,top=1.85cm, bottom=1.85cm]{geometry}
\usepackage[font=small,labelfont=bf]{caption}
\usepackage{graphics,graphicx,epsfig,ulem}
\usepackage{amsmath}
\usepackage{etoolbox}
\makeatletter
\patchcmd{\frontmatter@RRAP@format}{(}{}{}{}
\patchcmd{\frontmatter@RRAP@format}{)}{}{}{}
\renewcommand\Dated@name{}
\makeatother
\usepackage{fancyhdr}
\pagestyle{fancy}
\date{Submitted: \today{}, Date of Experiment: \nth{11} December 2018}
这是我需要帮助的最后部分
\date{Submitted: \today{}, Date of Experiment: \nth{11} December 2018}
正如你所看到的,我已经完成了, \nth{11} December 2018
效果很好,我只是想知道是否有办法将它添加到\today{}
因为我似乎无法做到这一点:(请帮助我是乳胶新手
答案1
随软件包datetime2
一起提供fmtcount
的允许您轻松创建新的日期格式,并且它具有序数日期命令。它还允许您创建命名日期以供显示。我已经为实验日期完成了此操作。
\documentclass{revtex4-1}
\usepackage{fmtcount}% required in addition to datetime2
\usepackage[calc]{datetime2}
\DTMnewdatestyle{usvardate}{%
\renewcommand{\DTMdisplaydate}[4]{%
\DTMmonthname{##2} \protect\ordinalnum{##3}, \number##1 }%
\renewcommand{\DTMDisplaydate}{\DTMdisplaydate}%
}
\DTMsetdatestyle{usvardate}
\DTMsavedate{expdate}{2018-12-11}
\date{\today{}. Date of experiment: \DTMusedate{expdate}}
\usepackage{etoolbox}
\makeatletter
\patchcmd{\frontmatter@RRAP@format}{(}{}{}{}
\patchcmd{\frontmatter@RRAP@format}{)}{}{}{}
\renewcommand\Dated@name{}
\makeatother
\begin{document}
\maketitle
\end{document}