Forgive me, it feels lame to ask such easy questions, but plowing through Google pages which don't appear to answer the question is maddening.
It is, I hope, very simple:
I'm trying to show, for maths homework, a top-heavy vulgar fraction rewritten as a whole number and a fraction.
The actual fraction is:
\frac{43,365,000}{17}
If anything below is bad form, do say:
The division by calculator gives:
2550882.3529411764705882352941176
To find the remainder, multiply integer part by 17 and I get:
43364994
Subtract this result from the numerator and I get:
43,365,000 - 43,364,994 = 6.
So, it's remainder 6.
So then, how do I typeset:
43,365,000 / 17 = 2550882 remainder 6?
So that I can get to the final answer, 2550882
and 6/17
?
Surely LaTeX has a method to handle this?
Thanks.
PS. It's interesting(?) I can't use a "modulo"/"modulus" tag below, because there isn't one and I can't create it.
Best Answer
I don't know if you only want to display, or also calculate. Here is a proposal:
In the second case common trailing zeros in the initial fraction are discarded from output, but that's the only simplification made. The package xintfrac has a macro
\xintIrr
that you could use to reduce the input to smallest terms first.Or the output, for example:
Notice how the "modulo" part is reduced to smallest terms.