Why are my inputs invalid in math mode? Why are my words running together?











up vote
0
down vote

favorite












Please help. I can't figure out why I keep getting a message saying "command textgreater invalid in math mode on line.." I get the same message for textless. Also, does this have anything to do with why my words are running together? Please help.



enter image description here



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{hyperref}
usepackage{amsmath}
usepackage{amssymb}
usepackage{amsthm}

% set page and text layout
linespread{1.8}
textwidth = 6.5 in
textheight = 9 in
oddsidemargin = 0.1 in
evensidemargin = 0.1 in
topmargin = 0.0 in
headheight = 0.0 in
headsep = 0.0 in

% set theorem numbering
newtheorem{theorem}{Theorem}[section]
newtheorem{proposition}[theorem]{Proposition}
newtheorem{corollary}[theorem]{Corollary}
newtheorem{lemma}[theorem]{Lemma}
newtheorem{definition}[theorem]{Definition}

% header information
title{F18-311 Writing Project 1}
author{kuyguk}
date{today}

begin{document}

maketitle

section{The Division Algorithm}

% Don't worry that the numbers won't match up exactly like in the textbook.

begin{theorem} (Division Algorithm) Let a and b be integers, with b textgreater 0. Then there exist unique integers q and r such that [a=bq+r] where 0 $leq r leq b$.

end{theorem}

begin{proof}
Existence of q and r. Let

[S = a - bk : k in mathbb{Z} and a - bk geq 0 .]
newline $If 0 in S$, then then b divides a, and we can let q=a/b and r=0. If $0 notin S$, we can use the Well-Ordering Principle. We must first show that S is nonempty. If $a - b * 0 in S.$ If a textless 0, then a - b (2a) = a (1-2b) $in$ S. Therefore, a = bq + r, r $leq$ 0. Then [ a - b (q + 1) = a - bq - b = r - b textgreater 0. ]
newline Since 0 $notin$ S, r $neq$ b and so r textless b.

Uniqueness of q and r. Suppose there exist integers r, $r^prime$, q, and $q^prime$ such that [a = bq + r, 0 leq r textless b and a = bq^prime + r^prime , 0 leq r^prime textless b.]

end{proof}









share|improve this question









New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
    – David Carlisle
    yesterday












  • for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
    – LaRiFaRi
    yesterday








  • 1




    as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
    – LaRiFaRi
    yesterday















up vote
0
down vote

favorite












Please help. I can't figure out why I keep getting a message saying "command textgreater invalid in math mode on line.." I get the same message for textless. Also, does this have anything to do with why my words are running together? Please help.



enter image description here



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{hyperref}
usepackage{amsmath}
usepackage{amssymb}
usepackage{amsthm}

% set page and text layout
linespread{1.8}
textwidth = 6.5 in
textheight = 9 in
oddsidemargin = 0.1 in
evensidemargin = 0.1 in
topmargin = 0.0 in
headheight = 0.0 in
headsep = 0.0 in

% set theorem numbering
newtheorem{theorem}{Theorem}[section]
newtheorem{proposition}[theorem]{Proposition}
newtheorem{corollary}[theorem]{Corollary}
newtheorem{lemma}[theorem]{Lemma}
newtheorem{definition}[theorem]{Definition}

% header information
title{F18-311 Writing Project 1}
author{kuyguk}
date{today}

begin{document}

maketitle

section{The Division Algorithm}

% Don't worry that the numbers won't match up exactly like in the textbook.

begin{theorem} (Division Algorithm) Let a and b be integers, with b textgreater 0. Then there exist unique integers q and r such that [a=bq+r] where 0 $leq r leq b$.

end{theorem}

begin{proof}
Existence of q and r. Let

[S = a - bk : k in mathbb{Z} and a - bk geq 0 .]
newline $If 0 in S$, then then b divides a, and we can let q=a/b and r=0. If $0 notin S$, we can use the Well-Ordering Principle. We must first show that S is nonempty. If $a - b * 0 in S.$ If a textless 0, then a - b (2a) = a (1-2b) $in$ S. Therefore, a = bq + r, r $leq$ 0. Then [ a - b (q + 1) = a - bq - b = r - b textgreater 0. ]
newline Since 0 $notin$ S, r $neq$ b and so r textless b.

Uniqueness of q and r. Suppose there exist integers r, $r^prime$, q, and $q^prime$ such that [a = bq + r, 0 leq r textless b and a = bq^prime + r^prime , 0 leq r^prime textless b.]

end{proof}









share|improve this question









New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















  • also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
    – David Carlisle
    yesterday












  • for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
    – LaRiFaRi
    yesterday








  • 1




    as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
    – LaRiFaRi
    yesterday













up vote
0
down vote

favorite









up vote
0
down vote

favorite











Please help. I can't figure out why I keep getting a message saying "command textgreater invalid in math mode on line.." I get the same message for textless. Also, does this have anything to do with why my words are running together? Please help.



enter image description here



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{hyperref}
usepackage{amsmath}
usepackage{amssymb}
usepackage{amsthm}

% set page and text layout
linespread{1.8}
textwidth = 6.5 in
textheight = 9 in
oddsidemargin = 0.1 in
evensidemargin = 0.1 in
topmargin = 0.0 in
headheight = 0.0 in
headsep = 0.0 in

% set theorem numbering
newtheorem{theorem}{Theorem}[section]
newtheorem{proposition}[theorem]{Proposition}
newtheorem{corollary}[theorem]{Corollary}
newtheorem{lemma}[theorem]{Lemma}
newtheorem{definition}[theorem]{Definition}

% header information
title{F18-311 Writing Project 1}
author{kuyguk}
date{today}

begin{document}

maketitle

section{The Division Algorithm}

% Don't worry that the numbers won't match up exactly like in the textbook.

begin{theorem} (Division Algorithm) Let a and b be integers, with b textgreater 0. Then there exist unique integers q and r such that [a=bq+r] where 0 $leq r leq b$.

end{theorem}

begin{proof}
Existence of q and r. Let

[S = a - bk : k in mathbb{Z} and a - bk geq 0 .]
newline $If 0 in S$, then then b divides a, and we can let q=a/b and r=0. If $0 notin S$, we can use the Well-Ordering Principle. We must first show that S is nonempty. If $a - b * 0 in S.$ If a textless 0, then a - b (2a) = a (1-2b) $in$ S. Therefore, a = bq + r, r $leq$ 0. Then [ a - b (q + 1) = a - bq - b = r - b textgreater 0. ]
newline Since 0 $notin$ S, r $neq$ b and so r textless b.

Uniqueness of q and r. Suppose there exist integers r, $r^prime$, q, and $q^prime$ such that [a = bq + r, 0 leq r textless b and a = bq^prime + r^prime , 0 leq r^prime textless b.]

end{proof}









share|improve this question









New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











Please help. I can't figure out why I keep getting a message saying "command textgreater invalid in math mode on line.." I get the same message for textless. Also, does this have anything to do with why my words are running together? Please help.



enter image description here



documentclass{article}
usepackage[utf8]{inputenc}
usepackage{hyperref}
usepackage{amsmath}
usepackage{amssymb}
usepackage{amsthm}

% set page and text layout
linespread{1.8}
textwidth = 6.5 in
textheight = 9 in
oddsidemargin = 0.1 in
evensidemargin = 0.1 in
topmargin = 0.0 in
headheight = 0.0 in
headsep = 0.0 in

% set theorem numbering
newtheorem{theorem}{Theorem}[section]
newtheorem{proposition}[theorem]{Proposition}
newtheorem{corollary}[theorem]{Corollary}
newtheorem{lemma}[theorem]{Lemma}
newtheorem{definition}[theorem]{Definition}

% header information
title{F18-311 Writing Project 1}
author{kuyguk}
date{today}

begin{document}

maketitle

section{The Division Algorithm}

% Don't worry that the numbers won't match up exactly like in the textbook.

begin{theorem} (Division Algorithm) Let a and b be integers, with b textgreater 0. Then there exist unique integers q and r such that [a=bq+r] where 0 $leq r leq b$.

end{theorem}

begin{proof}
Existence of q and r. Let

[S = a - bk : k in mathbb{Z} and a - bk geq 0 .]
newline $If 0 in S$, then then b divides a, and we can let q=a/b and r=0. If $0 notin S$, we can use the Well-Ordering Principle. We must first show that S is nonempty. If $a - b * 0 in S.$ If a textless 0, then a - b (2a) = a (1-2b) $in$ S. Therefore, a = bq + r, r $leq$ 0. Then [ a - b (q + 1) = a - bq - b = r - b textgreater 0. ]
newline Since 0 $notin$ S, r $neq$ b and so r textless b.

Uniqueness of q and r. Suppose there exist integers r, $r^prime$, q, and $q^prime$ such that [a = bq + r, 0 leq r textless b and a = bq^prime + r^prime , 0 leq r^prime textless b.]

end{proof}






math-mode






share|improve this question









New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











share|improve this question









New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this question




share|improve this question








edited yesterday









LaRiFaRi

35.4k243120




35.4k243120






New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









asked yesterday









Regine Harris

1




1




New contributor




Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






Regine Harris is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.












  • also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
    – David Carlisle
    yesterday












  • for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
    – LaRiFaRi
    yesterday








  • 1




    as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
    – LaRiFaRi
    yesterday


















  • also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
    – David Carlisle
    yesterday












  • for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
    – LaRiFaRi
    yesterday








  • 1




    as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
    – LaRiFaRi
    yesterday
















also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
– David Carlisle
yesterday






also you math variables should be in math so ... Let $a$ and $b$ be integers... and $r^prime$ is better to be input as $r'$
– David Carlisle
yesterday














for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
– LaRiFaRi
yesterday






for the text in math: Do something like [a = bq + r, 0 leq r < b text{and} a = bq^prime + r^prime , 0 leq r^prime < b.] or text{ and } or use the command wedge. In any case, you might want to define a custom command so that you may switch later on.
– LaRiFaRi
yesterday






1




1




as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
– LaRiFaRi
yesterday




as the command name says, those commands are meant for usage within text. Just do > and < in your formulae
– LaRiFaRi
yesterday










2 Answers
2






active

oldest

votes

















up vote
0
down vote













You should read some newer documentation, because there are ways to set up the margins not like that, for example, with package geometry or with KOMA-Script packages like typearea.



Also, if you want to put things in different paragraphts, just leave a blank line in between.



In any case, when something is math, it should be math. And math is written between $..$ in text and [ .. ] in displaystyle.



section{The Division Algorithm}

begin{theorem}[Division Algorithm]
Let $a$ and $b$ be integers, with $b > 0$. Then there exist unique integers $q$ and $r$
such that
[
a = bq + r
]
where $0 leq r leq b$.

end{theorem}

begin{proof}
Existence of $q$ and $r$. Let
[
S = a - bk : k in mathbb{Z} text{ and } a - bk geq 0.
% instead of `text{ and }` you can use ` text{and} ` or `quad text{and} quad`
]

If $0 in S$, then then $b$ divides $a$, and we can let $q = a/b$ and $r = 0$.
If $0 notin S$, we can use the Well-Ordering Principle. We must first show that $S$ is
nonempty. If $a - b * 0 in S$. If $a < 0$, then $a - b (2a) = a (1 - 2b) in S$.
Therefore, $a = bq + r$, $r leq 0$. Then
[
a - b (q + 1) = a - bq - b = r - b > 0.
]
Since 0 $notin S$, $r neq b$ and so $r < b$.

Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$, $q$, and $q'$ such
that
[
a = bq + r, 0 leq r < b quadtext{and}quad a = bq' + r' ,  0 leq r^' < b.
qedhere
]
end{proof}


Note that I just changed the things related to math mode. If a variable is math mode, you should put it in math mode, even if it's just a letter. And if an expression is math you have to put the whole expression in math so that the program takes care of the typesetting.






share|improve this answer




























    up vote
    0
    down vote













    documentclass{article}
    usepackage[utf8]{inputenc}
    usepackage{hyperref}
    usepackage{amsmath}
    usepackage{amssymb}
    usepackage{amsthm}

    % set page and text layout
    linespread{1.8}
    textwidth = 6.5 in
    textheight = 9 in
    oddsidemargin = 0.1 in
    evensidemargin = 0.1 in
    topmargin = 0.0 in
    headheight = 0.0 in
    headsep = 0.0 in

    % set theorem numbering
    newtheorem{theorem}{Theorem}[section]
    newtheorem{proposition}[theorem]{Proposition}
    newtheorem{corollary}[theorem]{Corollary}
    newtheorem{lemma}[theorem]{Lemma}
    newtheorem{definition}[theorem]{Definition}

    % header information
    title{F18-311 Writing Project 1}
    author{kuyguk}
    date{today}

    begin{document}

    maketitle

    section{The Division Algorithm}

    % Don't worry that the numbers won't match up exactly like in the textbook.

    begin{theorem} (Division Algorithm) Let
    % not a and b
    $a$ and $b$ be integers, with
    % not textgreater
    $b > 0$. Then there exist unique integers $q$ and $r$ such that [a=bq+r] where
    % the whole expression in math 0 $leq r leq b$.
    $0 leq r leq b$.

    end{theorem}

    begin{proof}
    Existence of $q$ and $r$. Let % never leave a blank line before display math
    [S = a - bk : k in mathbb{Z}
    % and in text
    text{ and }a - bk geq 0
    text{.}]


    % avoid forced line breaksnewline

    $If 0 in S$, then then $b$ divides $a$, and we can let
    % whole expression in math
    $q=a/b$ and $r=0$. If $0 notin S$, we can use the Well-Ordering Principle.
    We must first show that $S$ is nonempty. If
    % . not in math
    $a - b * 0 in S$.
    %whole expressions in math
    If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
    Therefore, $a = bq + r$, $r leq 0$. Then
    [ a - b (q + 1) = a - bq - b = r - b > 0. ]
    Since $0 notin S$, $r neq b$ and so $r < b$.

    Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$,
    $q$, and $q'$ such that [a = bq + r, 0 leq r < b text{ and } a = bq' + r' , 0 leq r' M btext{}.]

    end{proof}

    end{document}





    share|improve this answer





















    • If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
      – Manuel
      yesterday











    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "85"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });






    Regine Harris is a new contributor. Be nice, and check out our Code of Conduct.










     

    draft saved


    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f460690%2fwhy-are-my-inputs-invalid-in-math-mode-why-are-my-words-running-together%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    0
    down vote













    You should read some newer documentation, because there are ways to set up the margins not like that, for example, with package geometry or with KOMA-Script packages like typearea.



    Also, if you want to put things in different paragraphts, just leave a blank line in between.



    In any case, when something is math, it should be math. And math is written between $..$ in text and [ .. ] in displaystyle.



    section{The Division Algorithm}

    begin{theorem}[Division Algorithm]
    Let $a$ and $b$ be integers, with $b > 0$. Then there exist unique integers $q$ and $r$
    such that
    [
    a = bq + r
    ]
    where $0 leq r leq b$.

    end{theorem}

    begin{proof}
    Existence of $q$ and $r$. Let
    [
    S = a - bk : k in mathbb{Z} text{ and } a - bk geq 0.
    % instead of `text{ and }` you can use ` text{and} ` or `quad text{and} quad`
    ]

    If $0 in S$, then then $b$ divides $a$, and we can let $q = a/b$ and $r = 0$.
    If $0 notin S$, we can use the Well-Ordering Principle. We must first show that $S$ is
    nonempty. If $a - b * 0 in S$. If $a < 0$, then $a - b (2a) = a (1 - 2b) in S$.
    Therefore, $a = bq + r$, $r leq 0$. Then
    [
    a - b (q + 1) = a - bq - b = r - b > 0.
    ]
    Since 0 $notin S$, $r neq b$ and so $r < b$.

    Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$, $q$, and $q'$ such
    that
    [
    a = bq + r, 0 leq r < b quadtext{and}quad a = bq' + r' ,  0 leq r^' < b.
    qedhere
    ]
    end{proof}


    Note that I just changed the things related to math mode. If a variable is math mode, you should put it in math mode, even if it's just a letter. And if an expression is math you have to put the whole expression in math so that the program takes care of the typesetting.






    share|improve this answer

























      up vote
      0
      down vote













      You should read some newer documentation, because there are ways to set up the margins not like that, for example, with package geometry or with KOMA-Script packages like typearea.



      Also, if you want to put things in different paragraphts, just leave a blank line in between.



      In any case, when something is math, it should be math. And math is written between $..$ in text and [ .. ] in displaystyle.



      section{The Division Algorithm}

      begin{theorem}[Division Algorithm]
      Let $a$ and $b$ be integers, with $b > 0$. Then there exist unique integers $q$ and $r$
      such that
      [
      a = bq + r
      ]
      where $0 leq r leq b$.

      end{theorem}

      begin{proof}
      Existence of $q$ and $r$. Let
      [
      S = a - bk : k in mathbb{Z} text{ and } a - bk geq 0.
      % instead of `text{ and }` you can use ` text{and} ` or `quad text{and} quad`
      ]

      If $0 in S$, then then $b$ divides $a$, and we can let $q = a/b$ and $r = 0$.
      If $0 notin S$, we can use the Well-Ordering Principle. We must first show that $S$ is
      nonempty. If $a - b * 0 in S$. If $a < 0$, then $a - b (2a) = a (1 - 2b) in S$.
      Therefore, $a = bq + r$, $r leq 0$. Then
      [
      a - b (q + 1) = a - bq - b = r - b > 0.
      ]
      Since 0 $notin S$, $r neq b$ and so $r < b$.

      Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$, $q$, and $q'$ such
      that
      [
      a = bq + r, 0 leq r < b quadtext{and}quad a = bq' + r' ,  0 leq r^' < b.
      qedhere
      ]
      end{proof}


      Note that I just changed the things related to math mode. If a variable is math mode, you should put it in math mode, even if it's just a letter. And if an expression is math you have to put the whole expression in math so that the program takes care of the typesetting.






      share|improve this answer























        up vote
        0
        down vote










        up vote
        0
        down vote









        You should read some newer documentation, because there are ways to set up the margins not like that, for example, with package geometry or with KOMA-Script packages like typearea.



        Also, if you want to put things in different paragraphts, just leave a blank line in between.



        In any case, when something is math, it should be math. And math is written between $..$ in text and [ .. ] in displaystyle.



        section{The Division Algorithm}

        begin{theorem}[Division Algorithm]
        Let $a$ and $b$ be integers, with $b > 0$. Then there exist unique integers $q$ and $r$
        such that
        [
        a = bq + r
        ]
        where $0 leq r leq b$.

        end{theorem}

        begin{proof}
        Existence of $q$ and $r$. Let
        [
        S = a - bk : k in mathbb{Z} text{ and } a - bk geq 0.
        % instead of `text{ and }` you can use ` text{and} ` or `quad text{and} quad`
        ]

        If $0 in S$, then then $b$ divides $a$, and we can let $q = a/b$ and $r = 0$.
        If $0 notin S$, we can use the Well-Ordering Principle. We must first show that $S$ is
        nonempty. If $a - b * 0 in S$. If $a < 0$, then $a - b (2a) = a (1 - 2b) in S$.
        Therefore, $a = bq + r$, $r leq 0$. Then
        [
        a - b (q + 1) = a - bq - b = r - b > 0.
        ]
        Since 0 $notin S$, $r neq b$ and so $r < b$.

        Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$, $q$, and $q'$ such
        that
        [
        a = bq + r, 0 leq r < b quadtext{and}quad a = bq' + r' ,  0 leq r^' < b.
        qedhere
        ]
        end{proof}


        Note that I just changed the things related to math mode. If a variable is math mode, you should put it in math mode, even if it's just a letter. And if an expression is math you have to put the whole expression in math so that the program takes care of the typesetting.






        share|improve this answer












        You should read some newer documentation, because there are ways to set up the margins not like that, for example, with package geometry or with KOMA-Script packages like typearea.



        Also, if you want to put things in different paragraphts, just leave a blank line in between.



        In any case, when something is math, it should be math. And math is written between $..$ in text and [ .. ] in displaystyle.



        section{The Division Algorithm}

        begin{theorem}[Division Algorithm]
        Let $a$ and $b$ be integers, with $b > 0$. Then there exist unique integers $q$ and $r$
        such that
        [
        a = bq + r
        ]
        where $0 leq r leq b$.

        end{theorem}

        begin{proof}
        Existence of $q$ and $r$. Let
        [
        S = a - bk : k in mathbb{Z} text{ and } a - bk geq 0.
        % instead of `text{ and }` you can use ` text{and} ` or `quad text{and} quad`
        ]

        If $0 in S$, then then $b$ divides $a$, and we can let $q = a/b$ and $r = 0$.
        If $0 notin S$, we can use the Well-Ordering Principle. We must first show that $S$ is
        nonempty. If $a - b * 0 in S$. If $a < 0$, then $a - b (2a) = a (1 - 2b) in S$.
        Therefore, $a = bq + r$, $r leq 0$. Then
        [
        a - b (q + 1) = a - bq - b = r - b > 0.
        ]
        Since 0 $notin S$, $r neq b$ and so $r < b$.

        Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$, $q$, and $q'$ such
        that
        [
        a = bq + r, 0 leq r < b quadtext{and}quad a = bq' + r' ,  0 leq r^' < b.
        qedhere
        ]
        end{proof}


        Note that I just changed the things related to math mode. If a variable is math mode, you should put it in math mode, even if it's just a letter. And if an expression is math you have to put the whole expression in math so that the program takes care of the typesetting.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered yesterday









        Manuel

        21k845105




        21k845105






















            up vote
            0
            down vote













            documentclass{article}
            usepackage[utf8]{inputenc}
            usepackage{hyperref}
            usepackage{amsmath}
            usepackage{amssymb}
            usepackage{amsthm}

            % set page and text layout
            linespread{1.8}
            textwidth = 6.5 in
            textheight = 9 in
            oddsidemargin = 0.1 in
            evensidemargin = 0.1 in
            topmargin = 0.0 in
            headheight = 0.0 in
            headsep = 0.0 in

            % set theorem numbering
            newtheorem{theorem}{Theorem}[section]
            newtheorem{proposition}[theorem]{Proposition}
            newtheorem{corollary}[theorem]{Corollary}
            newtheorem{lemma}[theorem]{Lemma}
            newtheorem{definition}[theorem]{Definition}

            % header information
            title{F18-311 Writing Project 1}
            author{kuyguk}
            date{today}

            begin{document}

            maketitle

            section{The Division Algorithm}

            % Don't worry that the numbers won't match up exactly like in the textbook.

            begin{theorem} (Division Algorithm) Let
            % not a and b
            $a$ and $b$ be integers, with
            % not textgreater
            $b > 0$. Then there exist unique integers $q$ and $r$ such that [a=bq+r] where
            % the whole expression in math 0 $leq r leq b$.
            $0 leq r leq b$.

            end{theorem}

            begin{proof}
            Existence of $q$ and $r$. Let % never leave a blank line before display math
            [S = a - bk : k in mathbb{Z}
            % and in text
            text{ and }a - bk geq 0
            text{.}]


            % avoid forced line breaksnewline

            $If 0 in S$, then then $b$ divides $a$, and we can let
            % whole expression in math
            $q=a/b$ and $r=0$. If $0 notin S$, we can use the Well-Ordering Principle.
            We must first show that $S$ is nonempty. If
            % . not in math
            $a - b * 0 in S$.
            %whole expressions in math
            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            Therefore, $a = bq + r$, $r leq 0$. Then
            [ a - b (q + 1) = a - bq - b = r - b > 0. ]
            Since $0 notin S$, $r neq b$ and so $r < b$.

            Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$,
            $q$, and $q'$ such that [a = bq + r, 0 leq r < b text{ and } a = bq' + r' , 0 leq r' M btext{}.]

            end{proof}

            end{document}





            share|improve this answer





















            • If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
              – Manuel
              yesterday















            up vote
            0
            down vote













            documentclass{article}
            usepackage[utf8]{inputenc}
            usepackage{hyperref}
            usepackage{amsmath}
            usepackage{amssymb}
            usepackage{amsthm}

            % set page and text layout
            linespread{1.8}
            textwidth = 6.5 in
            textheight = 9 in
            oddsidemargin = 0.1 in
            evensidemargin = 0.1 in
            topmargin = 0.0 in
            headheight = 0.0 in
            headsep = 0.0 in

            % set theorem numbering
            newtheorem{theorem}{Theorem}[section]
            newtheorem{proposition}[theorem]{Proposition}
            newtheorem{corollary}[theorem]{Corollary}
            newtheorem{lemma}[theorem]{Lemma}
            newtheorem{definition}[theorem]{Definition}

            % header information
            title{F18-311 Writing Project 1}
            author{kuyguk}
            date{today}

            begin{document}

            maketitle

            section{The Division Algorithm}

            % Don't worry that the numbers won't match up exactly like in the textbook.

            begin{theorem} (Division Algorithm) Let
            % not a and b
            $a$ and $b$ be integers, with
            % not textgreater
            $b > 0$. Then there exist unique integers $q$ and $r$ such that [a=bq+r] where
            % the whole expression in math 0 $leq r leq b$.
            $0 leq r leq b$.

            end{theorem}

            begin{proof}
            Existence of $q$ and $r$. Let % never leave a blank line before display math
            [S = a - bk : k in mathbb{Z}
            % and in text
            text{ and }a - bk geq 0
            text{.}]


            % avoid forced line breaksnewline

            $If 0 in S$, then then $b$ divides $a$, and we can let
            % whole expression in math
            $q=a/b$ and $r=0$. If $0 notin S$, we can use the Well-Ordering Principle.
            We must first show that $S$ is nonempty. If
            % . not in math
            $a - b * 0 in S$.
            %whole expressions in math
            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            Therefore, $a = bq + r$, $r leq 0$. Then
            [ a - b (q + 1) = a - bq - b = r - b > 0. ]
            Since $0 notin S$, $r neq b$ and so $r < b$.

            Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$,
            $q$, and $q'$ such that [a = bq + r, 0 leq r < b text{ and } a = bq' + r' , 0 leq r' M btext{}.]

            end{proof}

            end{document}





            share|improve this answer





















            • If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
              – Manuel
              yesterday













            up vote
            0
            down vote










            up vote
            0
            down vote









            documentclass{article}
            usepackage[utf8]{inputenc}
            usepackage{hyperref}
            usepackage{amsmath}
            usepackage{amssymb}
            usepackage{amsthm}

            % set page and text layout
            linespread{1.8}
            textwidth = 6.5 in
            textheight = 9 in
            oddsidemargin = 0.1 in
            evensidemargin = 0.1 in
            topmargin = 0.0 in
            headheight = 0.0 in
            headsep = 0.0 in

            % set theorem numbering
            newtheorem{theorem}{Theorem}[section]
            newtheorem{proposition}[theorem]{Proposition}
            newtheorem{corollary}[theorem]{Corollary}
            newtheorem{lemma}[theorem]{Lemma}
            newtheorem{definition}[theorem]{Definition}

            % header information
            title{F18-311 Writing Project 1}
            author{kuyguk}
            date{today}

            begin{document}

            maketitle

            section{The Division Algorithm}

            % Don't worry that the numbers won't match up exactly like in the textbook.

            begin{theorem} (Division Algorithm) Let
            % not a and b
            $a$ and $b$ be integers, with
            % not textgreater
            $b > 0$. Then there exist unique integers $q$ and $r$ such that [a=bq+r] where
            % the whole expression in math 0 $leq r leq b$.
            $0 leq r leq b$.

            end{theorem}

            begin{proof}
            Existence of $q$ and $r$. Let % never leave a blank line before display math
            [S = a - bk : k in mathbb{Z}
            % and in text
            text{ and }a - bk geq 0
            text{.}]


            % avoid forced line breaksnewline

            $If 0 in S$, then then $b$ divides $a$, and we can let
            % whole expression in math
            $q=a/b$ and $r=0$. If $0 notin S$, we can use the Well-Ordering Principle.
            We must first show that $S$ is nonempty. If
            % . not in math
            $a - b * 0 in S$.
            %whole expressions in math
            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            Therefore, $a = bq + r$, $r leq 0$. Then
            [ a - b (q + 1) = a - bq - b = r - b > 0. ]
            Since $0 notin S$, $r neq b$ and so $r < b$.

            Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$,
            $q$, and $q'$ such that [a = bq + r, 0 leq r < b text{ and } a = bq' + r' , 0 leq r' M btext{}.]

            end{proof}

            end{document}





            share|improve this answer












            documentclass{article}
            usepackage[utf8]{inputenc}
            usepackage{hyperref}
            usepackage{amsmath}
            usepackage{amssymb}
            usepackage{amsthm}

            % set page and text layout
            linespread{1.8}
            textwidth = 6.5 in
            textheight = 9 in
            oddsidemargin = 0.1 in
            evensidemargin = 0.1 in
            topmargin = 0.0 in
            headheight = 0.0 in
            headsep = 0.0 in

            % set theorem numbering
            newtheorem{theorem}{Theorem}[section]
            newtheorem{proposition}[theorem]{Proposition}
            newtheorem{corollary}[theorem]{Corollary}
            newtheorem{lemma}[theorem]{Lemma}
            newtheorem{definition}[theorem]{Definition}

            % header information
            title{F18-311 Writing Project 1}
            author{kuyguk}
            date{today}

            begin{document}

            maketitle

            section{The Division Algorithm}

            % Don't worry that the numbers won't match up exactly like in the textbook.

            begin{theorem} (Division Algorithm) Let
            % not a and b
            $a$ and $b$ be integers, with
            % not textgreater
            $b > 0$. Then there exist unique integers $q$ and $r$ such that [a=bq+r] where
            % the whole expression in math 0 $leq r leq b$.
            $0 leq r leq b$.

            end{theorem}

            begin{proof}
            Existence of $q$ and $r$. Let % never leave a blank line before display math
            [S = a - bk : k in mathbb{Z}
            % and in text
            text{ and }a - bk geq 0
            text{.}]


            % avoid forced line breaksnewline

            $If 0 in S$, then then $b$ divides $a$, and we can let
            % whole expression in math
            $q=a/b$ and $r=0$. If $0 notin S$, we can use the Well-Ordering Principle.
            We must first show that $S$ is nonempty. If
            % . not in math
            $a - b * 0 in S$.
            %whole expressions in math
            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            Therefore, $a = bq + r$, $r leq 0$. Then
            [ a - b (q + 1) = a - bq - b = r - b > 0. ]
            Since $0 notin S$, $r neq b$ and so $r < b$.

            Uniqueness of $q$ and $r$. Suppose there exist integers $r$, $r'$,
            $q$, and $q'$ such that [a = bq + r, 0 leq r < b text{ and } a = bq' + r' , 0 leq r' M btext{}.]

            end{proof}

            end{document}






            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered yesterday









            David Carlisle

            477k3811061840




            477k3811061840












            • If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
              – Manuel
              yesterday


















            • If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
              – Manuel
              yesterday
















            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            – Manuel
            yesterday




            If $a < 0$$, then a - b (2a) = a (1-2b) in S$.
            – Manuel
            yesterday










            Regine Harris is a new contributor. Be nice, and check out our Code of Conduct.










             

            draft saved


            draft discarded


















            Regine Harris is a new contributor. Be nice, and check out our Code of Conduct.













            Regine Harris is a new contributor. Be nice, and check out our Code of Conduct.












            Regine Harris is a new contributor. Be nice, and check out our Code of Conduct.















             


            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f460690%2fwhy-are-my-inputs-invalid-in-math-mode-why-are-my-words-running-together%23new-answer', 'question_page');
            }
            );

            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







            Popular posts from this blog

            Accessing regular linux commands in Huawei's Dopra Linux

            Can't connect RFCOMM socket: Host is down

            Kernel panic - not syncing: Fatal Exception in Interrupt