LyX/LaTeX 中连接 (\bowtie) 操作的下标

发布于 2024-09-02 18:37:36 字数 412 浏览 4 评论 0原文

我正在使用 LyX 编写一些关系代数查询。 我使用 \bowtie 符号进行连接操作,但是当我尝试将文本直接放在该符号下的下标中时,出现以下错误:

...a_{\t{pId}}\t{person}\right)\bowtie\limits {\t{pId}{1}=\t{pId}_{2}...我忽略了这个错误的 \limits 或 \nolimits 命令。

有人知道如何做我想做的事吗?最好是在 LyX 中,但 ERT 代码片段也将受到赞赏。谢谢!

编辑: \t\text 的宏。

I'm using LyX to write some Relational Algebra queries.
I'm using the \bowtie symbol for the join operation but when I try to put a text in subscript directly under the symbol, I get the following error:

...a_{\t{pId}}\t{person}\right)\bowtie\limits
{\t{pId}{1}=\t{pId}_{2}... I'm ignoring this misplaced \limits or
\nolimits command.

Anyone knows how to do what I want? Preferably in LyX, but ERT code snippets will also be appreciated. Thanks!

Edit: \t is a macro for \text.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

淡淡的优雅 2024-09-09 18:37:36

更好地使用

\Join

它对我来说效果很好

Better use

\Join

It works fine for me

慈悲佛祖 2024-09-09 18:37:36

你的问题是 \bowtie 不是数学运算符,例如 \int\sum 等。

在序言中尝试这个:

\usepackage{amsmath}
\DeclareMathOperator*{\btie}{\bowtie}

在文档中尝试这个:

\(\btie\limits_{subscript}^{superscript}\)

我希望这就是您正在寻找的。

Your problem is that \bowtie is not math operator such as \int, \sum etc.

Try this in preamble:

\usepackage{amsmath}
\DeclareMathOperator*{\btie}{\bowtie}

and this in document:

\(\btie\limits_{subscript}^{superscript}\)

I hope it's what you're looking for.

东风软 2024-09-09 18:37:36

来自 http://en.wikibooks.org/wiki/LaTeX/Advanced_Mathematics#Above_and_below:

在序言中:

\usepackage{amsmath}

在等式中:

\underset{your_subscript_here}{\bowtie}

From http://en.wikibooks.org/wiki/LaTeX/Advanced_Mathematics#Above_and_below:

In preamble:

\usepackage{amsmath}

In equation:

\underset{your_subscript_here}{\bowtie}
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文