Math equation display issues
up vote
1
down vote
favorite
I write this math equation in mathtype first, and then convert it into latex code:
begin{block}{Membership functions Trapezoidal - Low}
[forall u in R,{rm{ }}{mu _L}(u) = left{ {begin{array}{*{20}{c}}{1{rm{ if }}0 le u le 0,2}\{frac{{0,3 - u}}{{0,1}}{rm{ if }}0,2 < u < 0,3}\{0{rm{ if u}} ge 0,3}end{array}} right.]
end{block}
However, as you can see, the display is not the same. So how can I fix this issues? Thanks


math-mode
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
up vote
1
down vote
favorite
I write this math equation in mathtype first, and then convert it into latex code:
begin{block}{Membership functions Trapezoidal - Low}
[forall u in R,{rm{ }}{mu _L}(u) = left{ {begin{array}{*{20}{c}}{1{rm{ if }}0 le u le 0,2}\{frac{{0,3 - u}}{{0,1}}{rm{ if }}0,2 < u < 0,3}\{0{rm{ if u}} ge 0,3}end{array}} right.]
end{block}
However, as you can see, the display is not the same. So how can I fix this issues? Thanks


math-mode
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" () before and after each "if", within the scope of the braced{rm if }.
– barbara beeton
Nov 27 at 3:11
Thermcommand has been deprecated for well over 20 years.
– egreg
Nov 27 at 7:54
add a comment |
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I write this math equation in mathtype first, and then convert it into latex code:
begin{block}{Membership functions Trapezoidal - Low}
[forall u in R,{rm{ }}{mu _L}(u) = left{ {begin{array}{*{20}{c}}{1{rm{ if }}0 le u le 0,2}\{frac{{0,3 - u}}{{0,1}}{rm{ if }}0,2 < u < 0,3}\{0{rm{ if u}} ge 0,3}end{array}} right.]
end{block}
However, as you can see, the display is not the same. So how can I fix this issues? Thanks


math-mode
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I write this math equation in mathtype first, and then convert it into latex code:
begin{block}{Membership functions Trapezoidal - Low}
[forall u in R,{rm{ }}{mu _L}(u) = left{ {begin{array}{*{20}{c}}{1{rm{ if }}0 le u le 0,2}\{frac{{0,3 - u}}{{0,1}}{rm{ if }}0,2 < u < 0,3}\{0{rm{ if u}} ge 0,3}end{array}} right.]
end{block}
However, as you can see, the display is not the same. So how can I fix this issues? Thanks


math-mode
math-mode
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked Nov 27 at 1:39
Dai Tran
82
82
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Dai Tran is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" () before and after each "if", within the scope of the braced{rm if }.
– barbara beeton
Nov 27 at 3:11
Thermcommand has been deprecated for well over 20 years.
– egreg
Nov 27 at 7:54
add a comment |
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" () before and after each "if", within the scope of the braced{rm if }.
– barbara beeton
Nov 27 at 3:11
Thermcommand has been deprecated for well over 20 years.
– egreg
Nov 27 at 7:54
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" (
) before and after each "if", within the scope of the braced {rm if }.– barbara beeton
Nov 27 at 3:11
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" (
) before and after each "if", within the scope of the braced {rm if }.– barbara beeton
Nov 27 at 3:11
The
rm command has been deprecated for well over 20 years.– egreg
Nov 27 at 7:54
The
rm command has been deprecated for well over 20 years.– egreg
Nov 27 at 7:54
add a comment |
2 Answers
2
active
oldest
votes
up vote
1
down vote
accepted
Don't use MathType to write equations: the code it generates is awful and, in some cases, plainly wrong.
For instance, the command rm has been deprecated for well over twenty years.
Here's a suggestion with a two-column array: the first column is center aligned and in displaystyle; the second column is left aligned and in text mode.
documentclass{beamer}
usepackage{mathtools,array}
usetheme{Warsaw}
begin{document}
begin{frame}
frametitle{A test}
begin{block}{Membership functions Trapezoidal - Low}
[
forall u in R,quad
mu_L(u) =
begin{cases}
begin{array}{@{} >{displaystyle}c >{$}l<{$} @{}}
1 & if $0 le u le 0{,}2$ \[1ex]
frac{0{,}3 - u}{0,1} & if $0{,}2 < u < 0{,}3$ \[2ex]
0 & if $u ge 0{,}3$
end{array}
end{cases}
]
end{block}
end{frame}
end{document}
Note how to avoid the unwanted space after the comma in numbers.

add a comment |
up vote
0
down vote
You can change the array function to have three entries. For example the following code:
begin{equation}
forall u in R,{rm{ }}{mu _L}(u) = left{ begin{array}{lll}1&;;{rm{ if }}&;;0 le u le 0,2\ frac{0,3 - u}{0,1}&;;{rm{ if }}&;;0,2 < u < 0,3\0&;;rm{ if } &;;uge 0,3end{array} right.
end{equation}

New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
Don't use MathType to write equations: the code it generates is awful and, in some cases, plainly wrong.
For instance, the command rm has been deprecated for well over twenty years.
Here's a suggestion with a two-column array: the first column is center aligned and in displaystyle; the second column is left aligned and in text mode.
documentclass{beamer}
usepackage{mathtools,array}
usetheme{Warsaw}
begin{document}
begin{frame}
frametitle{A test}
begin{block}{Membership functions Trapezoidal - Low}
[
forall u in R,quad
mu_L(u) =
begin{cases}
begin{array}{@{} >{displaystyle}c >{$}l<{$} @{}}
1 & if $0 le u le 0{,}2$ \[1ex]
frac{0{,}3 - u}{0,1} & if $0{,}2 < u < 0{,}3$ \[2ex]
0 & if $u ge 0{,}3$
end{array}
end{cases}
]
end{block}
end{frame}
end{document}
Note how to avoid the unwanted space after the comma in numbers.

add a comment |
up vote
1
down vote
accepted
Don't use MathType to write equations: the code it generates is awful and, in some cases, plainly wrong.
For instance, the command rm has been deprecated for well over twenty years.
Here's a suggestion with a two-column array: the first column is center aligned and in displaystyle; the second column is left aligned and in text mode.
documentclass{beamer}
usepackage{mathtools,array}
usetheme{Warsaw}
begin{document}
begin{frame}
frametitle{A test}
begin{block}{Membership functions Trapezoidal - Low}
[
forall u in R,quad
mu_L(u) =
begin{cases}
begin{array}{@{} >{displaystyle}c >{$}l<{$} @{}}
1 & if $0 le u le 0{,}2$ \[1ex]
frac{0{,}3 - u}{0,1} & if $0{,}2 < u < 0{,}3$ \[2ex]
0 & if $u ge 0{,}3$
end{array}
end{cases}
]
end{block}
end{frame}
end{document}
Note how to avoid the unwanted space after the comma in numbers.

add a comment |
up vote
1
down vote
accepted
up vote
1
down vote
accepted
Don't use MathType to write equations: the code it generates is awful and, in some cases, plainly wrong.
For instance, the command rm has been deprecated for well over twenty years.
Here's a suggestion with a two-column array: the first column is center aligned and in displaystyle; the second column is left aligned and in text mode.
documentclass{beamer}
usepackage{mathtools,array}
usetheme{Warsaw}
begin{document}
begin{frame}
frametitle{A test}
begin{block}{Membership functions Trapezoidal - Low}
[
forall u in R,quad
mu_L(u) =
begin{cases}
begin{array}{@{} >{displaystyle}c >{$}l<{$} @{}}
1 & if $0 le u le 0{,}2$ \[1ex]
frac{0{,}3 - u}{0,1} & if $0{,}2 < u < 0{,}3$ \[2ex]
0 & if $u ge 0{,}3$
end{array}
end{cases}
]
end{block}
end{frame}
end{document}
Note how to avoid the unwanted space after the comma in numbers.

Don't use MathType to write equations: the code it generates is awful and, in some cases, plainly wrong.
For instance, the command rm has been deprecated for well over twenty years.
Here's a suggestion with a two-column array: the first column is center aligned and in displaystyle; the second column is left aligned and in text mode.
documentclass{beamer}
usepackage{mathtools,array}
usetheme{Warsaw}
begin{document}
begin{frame}
frametitle{A test}
begin{block}{Membership functions Trapezoidal - Low}
[
forall u in R,quad
mu_L(u) =
begin{cases}
begin{array}{@{} >{displaystyle}c >{$}l<{$} @{}}
1 & if $0 le u le 0{,}2$ \[1ex]
frac{0{,}3 - u}{0,1} & if $0{,}2 < u < 0{,}3$ \[2ex]
0 & if $u ge 0{,}3$
end{array}
end{cases}
]
end{block}
end{frame}
end{document}
Note how to avoid the unwanted space after the comma in numbers.

answered Nov 27 at 8:36
egreg
702k8618703144
702k8618703144
add a comment |
add a comment |
up vote
0
down vote
You can change the array function to have three entries. For example the following code:
begin{equation}
forall u in R,{rm{ }}{mu _L}(u) = left{ begin{array}{lll}1&;;{rm{ if }}&;;0 le u le 0,2\ frac{0,3 - u}{0,1}&;;{rm{ if }}&;;0,2 < u < 0,3\0&;;rm{ if } &;;uge 0,3end{array} right.
end{equation}

New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
add a comment |
up vote
0
down vote
You can change the array function to have three entries. For example the following code:
begin{equation}
forall u in R,{rm{ }}{mu _L}(u) = left{ begin{array}{lll}1&;;{rm{ if }}&;;0 le u le 0,2\ frac{0,3 - u}{0,1}&;;{rm{ if }}&;;0,2 < u < 0,3\0&;;rm{ if } &;;uge 0,3end{array} right.
end{equation}

New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
add a comment |
up vote
0
down vote
up vote
0
down vote
You can change the array function to have three entries. For example the following code:
begin{equation}
forall u in R,{rm{ }}{mu _L}(u) = left{ begin{array}{lll}1&;;{rm{ if }}&;;0 le u le 0,2\ frac{0,3 - u}{0,1}&;;{rm{ if }}&;;0,2 < u < 0,3\0&;;rm{ if } &;;uge 0,3end{array} right.
end{equation}

New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
You can change the array function to have three entries. For example the following code:
begin{equation}
forall u in R,{rm{ }}{mu _L}(u) = left{ begin{array}{lll}1&;;{rm{ if }}&;;0 le u le 0,2\ frac{0,3 - u}{0,1}&;;{rm{ if }}&;;0,2 < u < 0,3\0&;;rm{ if } &;;uge 0,3end{array} right.
end{equation}

New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
edited Nov 27 at 5:31
Stefan Pinnow
19.2k83175
19.2k83175
New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
answered Nov 27 at 5:10
Onur Tavaslıoğlu
12
12
New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Onur Tavaslıoğlu is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
add a comment |
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
Thank you. Change array function is really useful.
– Dai Tran
Nov 27 at 5:20
add a comment |
Dai Tran is a new contributor. Be nice, and check out our Code of Conduct.
Dai Tran is a new contributor. Be nice, and check out our Code of Conduct.
Dai Tran is a new contributor. Be nice, and check out our Code of Conduct.
Dai Tran is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to TeX - LaTeX Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f461921%2fmath-equation-display-issues%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
welcome to tex.sx. the main problem i see is that there are no spaces around the "if" in the output. input spaces are essentially ignored in (la)tex, so have either to be entered explicitly, or entered in a "text" mode. (the latex code provided by the converter is not really very good, but you haven't said what converter was used, so i'll let it go at that.) probably the easiest way to salvage this is to add a "slash space" (
) before and after each "if", within the scope of the braced{rm if }.– barbara beeton
Nov 27 at 3:11
The
rmcommand has been deprecated for well over 20 years.– egreg
Nov 27 at 7:54