RH and LH Double-Quotes in MathJax

  • MHB
  • Thread starter Ackbach
  • Start date
  • Tags
    Mathjax
In summary: Their unicode method does work: \unicode{x201C} \text{ some text }\unicode{x201D} \( \unicode{x201C} \text{ some text }\unicode{x201D} \)Concur with CB - I would add that the unicode method seems to be the only method that works.
  • #1
Ackbach
Gold Member
MHB
4,155
93
Anyone know how to do handed double-quotes in Mathjax? I know how to do it in normal $\LaTeX$, but the code

Code:
$$\frac{d}{dx}\,f(x)\;\text{``is one notation''}$$

yields

$$\frac{d}{dx}\,f(x)\;\text{``is one notation''}$$

So that doesn't quite work like it normally does in $\LaTeX$. The alternative

Code:
$$\frac{d}{dx}\,f(x)\;\text{"is one notation"}$$

yields

$$\frac{d}{dx}\,f(x)\;\text{"is one notation"}$$

So that doesn't work, either. How to do this?
 
Physics news on Phys.org
  • #2
You can use \unicode command to produce the proper character.

Code:
\unicode{x201C}\text{Hello Ackbach!''}

will give

$\unicode{x201C}\text{Hello Ackbach!''}$
 
Last edited:
  • #3
sbhatnagar said:
You can use \unicode command to produce the proper character.

Code:
\unicode{x201C}\text{Hello Ackbach!''}

will give

$\unicode{x201C}\text{Hello Ackbach!''}$

Wow, that is a hack. But it works! Thanks much.
 
  • #4
Ackbach said:
Anyone know how to do handed double-quotes in Mathjax? I know how to do it in normal $\LaTeX$, but the code

Code:
$$\frac{d}{dx}\,f(x)\;\text{``is one notation''}$$

yields

$$\frac{d}{dx}\,f(x)\;\text{``is one notation''}$$

So that doesn't quite work like it normally does in $\LaTeX$. The alternative

Code:
$$\frac{d}{dx}\,f(x)\;\text{"is one notation"}$$

yields

$$\frac{d}{dx}\,f(x)\;\text{"is one notation"}$$

So that doesn't work, either. How to do this?

Hi Ackbach, :)

I asked this question from the MathJax community and here is the reply.

Kind Regards,
Sudharaka.
 
  • #5
Sudharaka said:
Hi Ackbach, :)

I asked this question from the MathJax community and here is the reply.

Kind Regards,
Sudharaka.

Their unicode method does work: \unicode{x201C} \text{ some text }\unicode{x201D}

\( \unicode{x201C} \text{ some text }\unicode{x201D} \)
 
  • #6
Concur with CB - I would add that the unicode method seems to be the only method that works.
 

FAQ: RH and LH Double-Quotes in MathJax

What is the purpose of using double-quotes in MathJax?

Double-quotes in MathJax are used to enclose text that should be treated as a single unit, such as a variable name or a function name. This helps to distinguish the text from other elements in the equation and ensures proper formatting.

How do I use double-quotes in MathJax to indicate a variable?

To indicate a variable in MathJax, you can enclose the variable name in double-quotes, such as "x". This will ensure that the variable is treated as a single unit and will be properly formatted in the equation.

Can I use double-quotes in MathJax for text that is not a variable or function name?

Yes, you can use double-quotes in MathJax for any text that should be treated as a single unit, such as a unit of measurement or a label. This will ensure that the text is properly formatted and distinguished from other elements in the equation.

What is the difference between using double-quotes and single-quotes in MathJax?

In MathJax, double-quotes are used to enclose text that should be treated as a single unit, while single-quotes are used to enclose text that should be treated as a literal string. For example, if you want to display the text "x" as a variable, you would use double-quotes, but if you want to display the text "x" as a string, you would use single-quotes.

Are there any special characters that cannot be used inside double-quotes in MathJax?

Yes, there are a few special characters that cannot be used inside double-quotes in MathJax, such as the backslash (\) and the dollar sign ($). These characters have special meanings in MathJax and must be escaped or used in a different way when used inside double-quotes.

Similar threads

Replies
12
Views
2K
Replies
3
Views
939
Replies
5
Views
9K
Replies
11
Views
6K
Replies
15
Views
25K
Replies
11
Views
2K
Replies
1
Views
2K
Back
Top