Difference between revisions of "Documentation/FAQ/Formula"

From Apache OpenOffice Wiki
Jump to: navigation, search
 
Line 23: Line 23:
 
[[Image:001a.gif]]you
 
[[Image:001a.gif]]you
 
should enter<font color="red">''' x=left lbrace binom -5 3 right none'''</font>.
 
should enter<font color="red">''' x=left lbrace binom -5 3 right none'''</font>.
 +
 +
==I enter <font color="red">'''x^*'''</font> to typeset x<SUP>*</SUP>, but get an error message. Why?==
 +
 +
The problem is that<font color="red">''' * '''</font>is a binary operator, that is
 +
there has to be an expression on both sides of the symbol.
 +
 +
You either have to enter the expression<font color="red">''' x^{{}*{}} '''</font>to avoid the
 +
error message, or you could type <font color="red">''' x^"*"'''</font> as well, where the quotes
 +
will interprete the asterisk not as a binary operator but as a "standalone" symbol.
 +
 +
If you use this construction a lot you might want to define the
 +
symbol as a userdefined symbol. See <A HREF="012.html">FAQ #012</A>.
 +
If you have defined the * as a userdefined symbol, say<font color="red">''' %ast'''</font>,
 +
you can enter<font color="red">''' x^%ast'''</font>.
 +
 +
This answer applies to a lot of other symbols as well. Some
 +
operators, such as +, are unary, that is there only has to be an
 +
expression to the right of the symbol. To typeset x<SUP>+</SUP> you
 +
can enter<font color="red">''' x^{+{}}<'''</font> or, of course, <font color="red">'''x^"+"'''</font>.

Revision as of 22:58, 13 June 2006

How can I get a left bracket without a right bracket?

Since brackets have a grouping function they must always match and be correctly nested.

To get a single bracket without a matching bracket partner you have to escape the bracket with a backslash. For example to get a "[" without a corresponding "]" you should enter "\[".

Thus to typeset the interval [3;8) you should enter \[3 ";" 8\). The quotation marks around the semicolon ensures that it is not typeset in italic. (You're right, this has nothing to do with brackets!)

For scalable brackets it is essential that left and right matches, since the content that the brackets encloses must be well defined.

In this case you can use the invisible bracket none to get a single bracket. For example to get a scalable "[" without a corresponding "]" you should enter left [ ... right none.

Thus to typeset File:001a.gifyou should enter x=left lbrace binom -5 3 right none.

I enter x^* to typeset x*, but get an error message. Why?

The problem is that * is a binary operator, that is there has to be an expression on both sides of the symbol.

You either have to enter the expression x^{{}*{}} to avoid the error message, or you could type x^"*" as well, where the quotes will interprete the asterisk not as a binary operator but as a "standalone" symbol.

If you use this construction a lot you might want to define the symbol as a userdefined symbol. See <A HREF="012.html">FAQ #012</A>. If you have defined the * as a userdefined symbol, say %ast, you can enter x^%ast.

This answer applies to a lot of other symbols as well. Some operators, such as +, are unary, that is there only has to be an expression to the right of the symbol. To typeset x+ you can enter x^{+{}}< or, of course, x^"+".

Personal tools