How to align these two expressions, one has one more number?aligning a multiline formula with the bullet of itemizeSame height for list of comma-separated vectorsFirst paragraph in environment without indent or spaceNew command adding extra spaceHow to vertically align two or more random places of a document?A parbox inside a textblockExtra space between entries in references when putting them on one line using natbib's numbers optionAlignment of terms within align environment
What Australian Megafauna Would be Suitable for Domestication, if Any?
Moisture leaking out of chip in floor tile
Where to search for PhD level jobs in OR?
Is there a way to auto-resolve a fight and account for resource consumption?
Antonym for “boilerplate” or “cookie-cutter”
Wood glue versus epoxy for doweling stripped screw holes
What's the short and accented note at the very end of a song called?
Create a box using the tcolorbox package or any other? (image)
Countering an uncounterable spell, triggers, and state-based actions
Why are one-word titles so dominant in books, film, and games?
Why is double encryption that's equivalent to single encryption no better than single encryption?
What does exhaust smell on oil and transmission dipstick mean?
Is there a name for the phenomenon of false positives counterintuitively outstripping true positives
Rational Number RNG
Why do Climate activists attack public transport?
My professor has no direction
Dragons have an armor that is similar to that of sungazer lizards. Why would the dragons have the spikes as well?
My cat gets angry and scared at me if I stand
instead of pressurizing an entire spacesuit with oxygen could oxygen just pressurize the head and the rest of the body be pressurized with water?
Why is Robin Hood French in Shrek?
Covering an 8x8 grid with X pentominoes
How to answer to the "We do not want to create any precedent" argument in salary negotiation?
Would a nuclear weapon be morbidly efficient against an Antedeluvian?
Is Bcrypt a hashing algorithm or is my study material wrong?
How to align these two expressions, one has one more number?
aligning a multiline formula with the bullet of itemizeSame height for list of comma-separated vectorsFirst paragraph in environment without indent or spaceNew command adding extra spaceHow to vertically align two or more random places of a document?A parbox inside a textblockExtra space between entries in references when putting them on one line using natbib's numbers optionAlignment of terms within align environment
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;
I am trying to align (-(a-1)^2-1)x+(-(a-1)^2-1)
and (-(a-1)^2-1)x+1
using phantom
command. Since (-(a-1)^2-1)x+1
is missing the (-(a-1)^2-1)
part, I added phantom(-(a-1)^2-1)
, but there is an extra space that I am not sure from were it comes:
I guess it comes from adding the "1
", but I do not know how to compensate this extra space.
MWE:
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)1
endarray]
enddocument
I want this output:
How to achieve it?
spacing vertical-alignment phantom
add a comment
|
I am trying to align (-(a-1)^2-1)x+(-(a-1)^2-1)
and (-(a-1)^2-1)x+1
using phantom
command. Since (-(a-1)^2-1)x+1
is missing the (-(a-1)^2-1)
part, I added phantom(-(a-1)^2-1)
, but there is an extra space that I am not sure from were it comes:
I guess it comes from adding the "1
", but I do not know how to compensate this extra space.
MWE:
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)1
endarray]
enddocument
I want this output:
How to achieve it?
spacing vertical-alignment phantom
add a comment
|
I am trying to align (-(a-1)^2-1)x+(-(a-1)^2-1)
and (-(a-1)^2-1)x+1
using phantom
command. Since (-(a-1)^2-1)x+1
is missing the (-(a-1)^2-1)
part, I added phantom(-(a-1)^2-1)
, but there is an extra space that I am not sure from were it comes:
I guess it comes from adding the "1
", but I do not know how to compensate this extra space.
MWE:
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)1
endarray]
enddocument
I want this output:
How to achieve it?
spacing vertical-alignment phantom
I am trying to align (-(a-1)^2-1)x+(-(a-1)^2-1)
and (-(a-1)^2-1)x+1
using phantom
command. Since (-(a-1)^2-1)x+1
is missing the (-(a-1)^2-1)
part, I added phantom(-(a-1)^2-1)
, but there is an extra space that I am not sure from were it comes:
I guess it comes from adding the "1
", but I do not know how to compensate this extra space.
MWE:
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)1
endarray]
enddocument
I want this output:
How to achieve it?
spacing vertical-alignment phantom
spacing vertical-alignment phantom
edited Oct 13 at 1:01
manooooh
asked Oct 13 at 0:58
manoooohmanooooh
1,3691 gold badge5 silver badges20 bronze badges
1,3691 gold badge5 silver badges20 bronze badges
add a comment
|
add a comment
|
2 Answers
2
active
oldest
votes
You have to remove the 1
from the phantom
, since it shows up explicitly outside the phantom
. I replace it with placeholder.
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-)1
endarray]
enddocument
In response to a comment from the OP, I leave this also, to show what can be done when the phantom
and residual term do not share common digits.
documentclassarticle
usepackagemathtools
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)mathllap5-4+2^2
endarray]
enddocument
Thank you, it worked! A side question: what if the second line has e.g.5-4+2^2
instead of1
? There will be no more comparisons.
– manooooh
Oct 13 at 1:04
1
In that case, I would leave the original (complete)phantom
and then use themathtools
package to place amathllap5-4+2^2
. Please see edit.
– Steven B. Segletes
Oct 13 at 1:06
add a comment
|
Add more alignment points:
documentclassarticle
usepackageamsmath
usepackagearray
begindocument
[
beginarray@ l @>c<@ r @
(-(a-1)^2-1)x &+& (-(a-1)^2-1)\
(-(a-1)^2-1)x &+& 1
endarray
]
enddocument
Thank you! You have manipulatedarray
arguments when I only need it for this question, but it is a good approach. I will have to study yourarray
parameters more carefully to understand it.
– manooooh
Oct 13 at 12:13
add a comment
|
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',
autoActivateHeartbeat: false,
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/4.0/"u003ecc by-sa 4.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
);
);
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%2f512035%2fhow-to-align-these-two-expressions-one-has-one-more-number%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
You have to remove the 1
from the phantom
, since it shows up explicitly outside the phantom
. I replace it with placeholder.
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-)1
endarray]
enddocument
In response to a comment from the OP, I leave this also, to show what can be done when the phantom
and residual term do not share common digits.
documentclassarticle
usepackagemathtools
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)mathllap5-4+2^2
endarray]
enddocument
Thank you, it worked! A side question: what if the second line has e.g.5-4+2^2
instead of1
? There will be no more comparisons.
– manooooh
Oct 13 at 1:04
1
In that case, I would leave the original (complete)phantom
and then use themathtools
package to place amathllap5-4+2^2
. Please see edit.
– Steven B. Segletes
Oct 13 at 1:06
add a comment
|
You have to remove the 1
from the phantom
, since it shows up explicitly outside the phantom
. I replace it with placeholder.
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-)1
endarray]
enddocument
In response to a comment from the OP, I leave this also, to show what can be done when the phantom
and residual term do not share common digits.
documentclassarticle
usepackagemathtools
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)mathllap5-4+2^2
endarray]
enddocument
Thank you, it worked! A side question: what if the second line has e.g.5-4+2^2
instead of1
? There will be no more comparisons.
– manooooh
Oct 13 at 1:04
1
In that case, I would leave the original (complete)phantom
and then use themathtools
package to place amathllap5-4+2^2
. Please see edit.
– Steven B. Segletes
Oct 13 at 1:06
add a comment
|
You have to remove the 1
from the phantom
, since it shows up explicitly outside the phantom
. I replace it with placeholder.
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-)1
endarray]
enddocument
In response to a comment from the OP, I leave this also, to show what can be done when the phantom
and residual term do not share common digits.
documentclassarticle
usepackagemathtools
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)mathllap5-4+2^2
endarray]
enddocument
You have to remove the 1
from the phantom
, since it shows up explicitly outside the phantom
. I replace it with placeholder.
documentclassarticle
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-)1
endarray]
enddocument
In response to a comment from the OP, I leave this also, to show what can be done when the phantom
and residual term do not share common digits.
documentclassarticle
usepackagemathtools
begindocument
[beginarrayc
(-(a-1)^2-1)x+(-(a-1)^2-1)\
(-(a-1)^2-1)x+phantom(-(a-1)^2-1)mathllap5-4+2^2
endarray]
enddocument
edited Oct 13 at 1:09
answered Oct 13 at 1:01
Steven B. SegletesSteven B. Segletes
172k9 gold badges218 silver badges447 bronze badges
172k9 gold badges218 silver badges447 bronze badges
Thank you, it worked! A side question: what if the second line has e.g.5-4+2^2
instead of1
? There will be no more comparisons.
– manooooh
Oct 13 at 1:04
1
In that case, I would leave the original (complete)phantom
and then use themathtools
package to place amathllap5-4+2^2
. Please see edit.
– Steven B. Segletes
Oct 13 at 1:06
add a comment
|
Thank you, it worked! A side question: what if the second line has e.g.5-4+2^2
instead of1
? There will be no more comparisons.
– manooooh
Oct 13 at 1:04
1
In that case, I would leave the original (complete)phantom
and then use themathtools
package to place amathllap5-4+2^2
. Please see edit.
– Steven B. Segletes
Oct 13 at 1:06
Thank you, it worked! A side question: what if the second line has e.g.
5-4+2^2
instead of 1
? There will be no more comparisons.– manooooh
Oct 13 at 1:04
Thank you, it worked! A side question: what if the second line has e.g.
5-4+2^2
instead of 1
? There will be no more comparisons.– manooooh
Oct 13 at 1:04
1
1
In that case, I would leave the original (complete)
phantom
and then use the mathtools
package to place a mathllap5-4+2^2
. Please see edit.– Steven B. Segletes
Oct 13 at 1:06
In that case, I would leave the original (complete)
phantom
and then use the mathtools
package to place a mathllap5-4+2^2
. Please see edit.– Steven B. Segletes
Oct 13 at 1:06
add a comment
|
Add more alignment points:
documentclassarticle
usepackageamsmath
usepackagearray
begindocument
[
beginarray@ l @>c<@ r @
(-(a-1)^2-1)x &+& (-(a-1)^2-1)\
(-(a-1)^2-1)x &+& 1
endarray
]
enddocument
Thank you! You have manipulatedarray
arguments when I only need it for this question, but it is a good approach. I will have to study yourarray
parameters more carefully to understand it.
– manooooh
Oct 13 at 12:13
add a comment
|
Add more alignment points:
documentclassarticle
usepackageamsmath
usepackagearray
begindocument
[
beginarray@ l @>c<@ r @
(-(a-1)^2-1)x &+& (-(a-1)^2-1)\
(-(a-1)^2-1)x &+& 1
endarray
]
enddocument
Thank you! You have manipulatedarray
arguments when I only need it for this question, but it is a good approach. I will have to study yourarray
parameters more carefully to understand it.
– manooooh
Oct 13 at 12:13
add a comment
|
Add more alignment points:
documentclassarticle
usepackageamsmath
usepackagearray
begindocument
[
beginarray@ l @>c<@ r @
(-(a-1)^2-1)x &+& (-(a-1)^2-1)\
(-(a-1)^2-1)x &+& 1
endarray
]
enddocument
Add more alignment points:
documentclassarticle
usepackageamsmath
usepackagearray
begindocument
[
beginarray@ l @>c<@ r @
(-(a-1)^2-1)x &+& (-(a-1)^2-1)\
(-(a-1)^2-1)x &+& 1
endarray
]
enddocument
answered Oct 13 at 9:30
egregegreg
776k92 gold badges2020 silver badges3382 bronze badges
776k92 gold badges2020 silver badges3382 bronze badges
Thank you! You have manipulatedarray
arguments when I only need it for this question, but it is a good approach. I will have to study yourarray
parameters more carefully to understand it.
– manooooh
Oct 13 at 12:13
add a comment
|
Thank you! You have manipulatedarray
arguments when I only need it for this question, but it is a good approach. I will have to study yourarray
parameters more carefully to understand it.
– manooooh
Oct 13 at 12:13
Thank you! You have manipulated
array
arguments when I only need it for this question, but it is a good approach. I will have to study your array
parameters more carefully to understand it.– manooooh
Oct 13 at 12:13
Thank you! You have manipulated
array
arguments when I only need it for this question, but it is a good approach. I will have to study your array
parameters more carefully to understand it.– manooooh
Oct 13 at 12:13
add a comment
|
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.
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%2f512035%2fhow-to-align-these-two-expressions-one-has-one-more-number%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