0

I am using align environment and sometimes can see that there is an unwated space in some parts of the aligned equations. Hence, I use \hspace with negative length to get the desired spacing.

Even though it works well for the equation itself, the tag sometimes moves horizontally with an amount equal to the argument of \hspace.

Here is a sample. Before

enter image description here

After enter image description here

The tag of some other equations seem to stay where it should be even after using \hspace

enter image description here

This is What is the difference that made one set of equation affect the tags but the other set work well?

Source code

\documentclass{IEEEtran}

\usepackage[T1]{fontenc}
\usepackage[no-math]{fontspec}
\usepackage{amsmath,amsfonts}
\usepackage{mathtools}
\usepackage[symbolmisc]{mathastext}
\usepackage{blindtext}

\begin{document}
\blindtext
    \begin{align}
        && \frac{X_{th, kp} - X_{b}} {\chi} > \frac{X_{th, kp}} {\chi} & \implies & \frac{1}{\Theta} &> \frac{1}{\Xi} &&
        \notag
        \\
        && &
        \implies & \Theta &< \Xi &&
    \end{align}
\blindtext
    \begin{align}
        && \frac{X_{th, kp} - X_{b}} {\chi} > \frac{X_{th, kp}} {\chi} & \implies \hspace{-10mm} & \frac{1}{\Theta} &> \frac{1}{\Xi}
        \notag
        \\
        && &
        \implies \hspace{-10mm} &  \Theta &< \Xi
    \end{align}
\blindtext
    \begin{align}
        I_{sc} & = I_{sc, ref} & \hspace{-11mm} \bigg[  1 + \frac{\alpha}{100} (T_{op}-T_{ref}) \biggl]
        \vspace{2 mm}
        \\
        V_{oc} & = V_{oc,ref} & \hspace{-11mm} \bigg[  1 + \frac{\beta}{100} (T_{op}-T_{ref}) \biggl]
        \vspace{2 mm}
        \\
        P_{mp} & = P_{mp,ref} & \hspace{-11mm} \bigg[  1 + \frac{\gamma}{100} (T_{op}-T_{ref}) \biggl]
    \end{align}
\end{document}
5
  • off topic: instead of using \vspace{2 mm}\\ you can use \\[.5em] for example, to increase space between lines.
    – Sigur
    Aug 23, 2018 at 20:22
  • why are you starting each row with && ? Aug 23, 2018 at 20:28
  • unrelated but \bigg[ ...\biggl] should be \biggl[ ...\biggr] Aug 23, 2018 at 20:30
  • also your packages seem inconsistent you have \usepackage[T1]{fontenc} \usepackage[no-math]{fontspec} but T1 encoding should only be used with (pdf)latex but fontspec requires xetex or luatex, which tex engine are you using? Aug 23, 2018 at 20:33
  • Since you have some responses below that seem to answer your question, please consider marking one of them as ‘Accepted’ by clicking on the tickmark below their vote count (see How do you accept an answer?). This shows which answer helped you most, and it assigns reputation points to the author of the answer (and to you!). It's part of this site's idea to identify good questions and answers through upvotes and acceptance of answers. Mar 12, 2019 at 10:00

1 Answer 1

1

The negative spacing was only being used to correct for space forced by the extra &, if the alignment is marked with a single & as usual then a far more natural spacing is used

enter image description here

I removed fontspec here so the example can be used with pdflatex

\documentclass{IEEEtran}


\usepackage{amsmath,amsfonts}


\usepackage{blindtext}

\begin{document}
\blindtext
    \begin{align}
        \frac{X_{th, kp} - X_{b}} {\chi} > \frac{X_{th, kp}} {\chi} & \implies \frac{1}{\Theta} > \frac{1}{\Xi} 
        \notag
      \\
        &\implies  \Theta < \Xi
    \end{align}

\end{document}
2
  • Thanks for the answer, but I still want to align the inequality signs precisely with each other and I think I knew how Aug 23, 2018 at 20:55
  • @Al-MotasemAldaoudeyeh if you really want that you could use alignat (but still you don't need && at the start of every row, and do not need negative s[ace) Aug 23, 2018 at 20:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.