views:

2049

answers:

17

I have come across this problem in a calculation I do in my code, where the divisor is 0 if the divident is 0 too. In my code I return 0 for that case. I am wondering, while division by zero is generally undefined, why not make an exception for this case? My understanding why division by zero is undefined is basically that it cannot be reversed. However, I do not see this problem in the case 0/0.

EDIT OK, so this question spawned a lot of discussion. I made the mistake of over-eagerly accepting an answer based on the fact that it received a lot of votes. I now accepted AakashM's answer, because it provides an idea on how to analyze the problem.

+41  A: 
Andrzej Doyle
+1 _-_ succinct
Andras Zoltan
-1 Anything divided by 0 is **undefined**, unless you extend arithmetic with infinity - and then you get into the question of what the results of involving infinity in arithmethic operations would be. (Yes, I believe some teachers still perpetrate this description of the problem, but it's poor mathematics.)
Pontus Gagge
You're making my 12th grade calculus teacher very unhappy by not using limits.
Dave Markle
@Pontus: I agree, I admit I was sacrificing some accuracy to get the point across intuitively. Saying that "anything divided by 0 is undefined" kind of begs the question, as it proves the issue by itself without really showing *why*.
Andrzej Doyle
@Pontus In many proves of Maths theory when the answer should be infinity, anything divided by 0 is written as infinity as `undefined` cannot be written in maths language.
Himadri
Anything divided by 0 is either positive or negative infinity, depending on which side you look at it from.
wrosecrans
re rule number 2 --> it is possible to turn an indeterminate form into a determinate form using derivatives in order to evaluate the limit of an equation. See "L'Hôpital's rule" for further information
Tony Breyal
-1 anything divided by 0 is undefined.
JeremyP
I never got how something divided by 0 was infinity. I mean, that implies that if you keep on adding 0 you'll eventually reach x. This is not correct. The summation of a set of the size aleph naught containing nothing but zeros still has a total value of 0.
diadem
@diadem; 1/0 does not equal anything, but in the limit where x approaches 0, 1/x approaches infinity -> it's almost correct to say 1/0 = infinity. Infinity is a tricky thing.
roe
You hit your reputation cap with this? Sheesh...
robinjam
@Himadri @wrosecrans @Andrzej: infinity is not and never has been a number. Stating that it is the solution to some (non-limiting) equation is both confusing and meaningless.
BlueRaja - Danny Pflughoeft
This answer is: No math, and not correct. You guys upvoting this..oh dear, divide yourself by 0 and go straight to infinity...
InsertNickHere
This is just misleading nonsense. (For example, why shouldn't 0/x be negative infinity?)
sth
@sth: because `0/x` is `0` forall `x != 0`. @roe: `1/x` tends to infinity as `x` approaches `0` *from above*. But `1/x` tends to negative infinity as `x` approaches `0` *from beneath*. Since there is a discontinuity, we say `1/x` is undefined.
Ben Voigt
Relax everyone: 'anything divided by zero is infinity' is fine. It's not strictly correct (as any Maths 1 fule kno), but at the level of formality represented by this answer -- which is the _correct_ level of formality for this question -- it's good enough. In any pedagogical context, intelligible insight trumps accuracy every time.
Norman Gray
@ShreevatsaR you made the answer worse (less intelligible, less useful to the questioner) by your unilateral edit. Useless pedantry serves only the vanity of the teacher. Kindly revert it.
Norman Gray
Looks like we could do with a Talk page for this answer... I completely agree that the second point is mathematically nonsense, so I don't have a problem with the edit per se. I never intended my answer to be rigorous, it was merely meant as a common-sense rebuttal to the claim that 0/0 should be 0 in the context of programming. 0/0 is undefined *by definition of the languages*, and I don't think limit theory has much place in justifying that. (This answer definitely didn't deserve as many votes as it got, though.)
Andrzej Doyle
I don't understand the posts that deny the existence of infinity. Since at least Newton and Leibniz, it's a perfectly good number which can be manipulated mathematically. Yes, the statement that anything divided by zero equals infinity is technically incorrect because it ignores the case where the numerator is zero, but clearly that is Mr Doyle's point. If you read the whole post, yes, you could quibble about some technical points, but the gist of what he says is correct.
Jay
@Andrzej: Feel free to edit the answer with anything that is correct; it's your answer after all. Stack Overflow is a wiki, and the goal is to have good answers that last for eternity.@Jay: No, 1/0 is not infinity either. It's just meaningless. (Would you say that -1/0 is infinity too? Why not negative infinity?)This answer got so many upvotes because it "looks" correct, while it's not. There is no sense in which something divided by zero can be infinity, but something divided by a number approaching 0 can approach positive infinity if both have same sign, and negative infinity otherwise.)
ShreevatsaR
@Jay: What do you mean by "a perfectly good number which can be manipulated mathematically"? It's not a real number, and it certainly makes no sense to say it is rational or integer.
Larry Wang
@ShreevatsaR - I can't really think of any edits that would make my answer correct. The only "correct" answers would be to either simply state that division by zero is undefined, which doesn't solve the question, or to discuss limit theory, which I personally consider beyond the scope of the asker's problem and what I wanted to convey with the answer. By definition I didn't intend this answer to be correct in a strict mathematical sense. Since that seems to be causing the issues, I don't think there's an edit that preserves the context of the answer while keeping everyone happy.
Andrzej Doyle
Rather the point was simply to present analogues to the asker's position that (paraphrasing) "one should make an exception for 0/0 because we can see it should be 0", by presenting similar cases where you can see it should be 1 (or ahem, the non-number-that-shall-not-be-named) - thus showing the argument is flawed.
Andrzej Doyle
@Kaestur: Do you think that the square root of 2 is a "perfectly good number"? But how can you say that? It's not a rational number and it's certainly not an integer. The fact that infinity is not a real number doesn't mean that it's not a number, any more than that fact that square root of 2 is not rational does not mean that it's not a number. The square root of 2 is a number that falls out of certain mathematical operations, namely, the square root function. Infinity is a number that falls out of certain mathematical operations, namely, division by zero or repetitive sums.
Jay
@Jay: I don't mean to diss anyone's choice of number system. I simply meant that infinity is definitely a special case, and one that not everyone accepts as part of their number system. Furthermore, even if you do treat infinity as a number (extended reals, for instance) it doesn't necessarily mean that 1/0 should be infinity.
Larry Wang
Infinity is a beast. Did you know, there are infinities that are greater than others? Think of a infinite line with infinite mathematical points on if. Then think of a infinite square...you will see that the first infinite < the second. You can see this too with natural numbers and rational numbers...you cant use the natural to "count" the rational. So infinity of the natural is very smaller than infinity of the rationa. This is called innumerable infinity.
InsertNickHere
@InsertNickHere: Your basic idea is correct: some infinities are bigger than others. But the example you gave does not actually demonstrate this! One of the more mind-boggling things about infinity is that an infinite square does not contain any more points than one of its 'edges.' For every rational number, we can find a matching natural number! A proof can be found here: http://www.homeschoolmath.net/teaching/rational-numbers-countable.php
Larry Wang
Re latest edit: "in that x/ε tends to infinity as ε tends to zero" — this is true for positive x. Even without being formally correct, it's clearer to say "(a positive number)/0 = infinity, but (a negative number)/0 = -infinity, and 0/0 is neither".
ShreevatsaR
A: 

See the examples on the wikipedia page. Especially the chapter "Division as the inverse of multiplication" will show you the real problem with it.

Raffael Luthiger
This is completely wrong. NO number solves x*0=5 (when considering 5/0=x) while EVERY number solves x*0=0 (when considering 0/0=x). A big difference.
zvrba
Sorry. I wrote the comment too fast. you are right. I corrected it now. I only wanted to say that there is in both cases no single solution and therefore the "same problem" for the computer.
Raffael Luthiger
+67  A: 

Let's say:

0/0 = x

Now, rearranging the equation (multiplying both sides by 0) gives:

x * 0 = 0

Now do you see the problem? There are an infinite number of values for x as anything multiplied by 0 is 0.

Yacoby
Why the downvotes? I am curious...
Yacoby
Not downvoted myself but multiplying by zero is undefined. Example x = 1 has a clear result for x , but x * 0 = 1 * 0 does not. So mult by zero is an invalid transformation.
josefx
Mutliplying by 0 has a clear result... 0. This is the basis of a lot of maths.
Yacoby
Yeah it is also good to prove 1 = 2. After all we can do 1 = 2 => 1 * 0 = 2 * 0 => 0 = 0 => true. Or x = 1 => x * 0 = 1 * 0 => x * 0 = 0 => every value of x is valid. Are those two examples good enough to show that multiplying by zero is not a good idea if you need valid results or do I have to add more?
josefx
@Yacoby could you name one of those maths?
josefx
@josefx. If you start with 1 = 2, it is possible to prove just about whatever you want. You can't use it as the basis for an argument that you can't multiply by 0. Anyway, take a look at [Wikipedia](http://en.wikipedia.org/wiki/Multiplication#Properties)
Yacoby
@Yacoby the basis of my first example is that we all know that 1 = 2 is wrong - the second one works without it. A multiplication with zero as your wikipedia link points out will result in zero for any values multiplied, so the wrong 1 = 2 becomes right with 1 * 0 = 2 * 0. Like x = 1 is only valid for x = 1 and x * 0 = 1 * 0 is valid for any value. Once multiplied with zero you have a completly different function with different valid values for x. This all is caused by the zero property.
josefx
@Yacoby to build on your link alone: the zero property causes anything multiplied by zero to become zero, so multiplying both sides of the equation with zero will result in 0 = 0 - this is not a property of 0/0 = x AFAIC using zero multiplication in any mathematical proof is an error because you can proof anything with it.
josefx
@josefx The fact that you have started with something that is false and got something that is true is meaningless. You can do the same thing by raising both sides to the power of 0. For example lets generalize the equation, x = y => x*0 = y*0 => 0 = 0. 0 = 0 tells us nothing. It in no way proves that 1 = 2 or x = y.
Yacoby
In summary, multiplying by 0 has a clearly defined result. 0.
Yacoby
There is a good [explanation here](http://mathforum.org/library/drmath/view/53093.html). I can't believe I am arguing about this.
Yacoby
@Yacoby that is what I wanted to point out, you do exactly the same with 0/0 = x. You multiply both sides with 0 to get your result. My examples show that the result of multiplying both sides with zero is in fact meaningles => my examples are just as meaningles as your x * 0 = 0 as both are only based on the wrong idea that multiplication with 0 can be used as a transformation without changing the results.
josefx
@Yacoby the midth of your explanation link shows why multiplying by zero is a bad idea, why would it be any better in your answer than in my examples? What makes your multiply both sides by 0 better than mine? There is no difference.
josefx
@josefx Mine is reversible...
Yacoby
@josefx: This is incredible. Multiplying a number by 0 is always well-defined, and has the value 0. This is a basic property of 0 in any ring. x*0 = 0 for any x. I can't believe you're arguing about this.
ShreevatsaR
@ShreevatsaR im not arguing about multiplication by 0 itself being undefined, im arguing that the zero property makes the function meaningless. Yacobys explanation page states this too and I have jet to see anything that states that there are exceptions to this. The multiplication by 0 removes the x from the equation. Say x = y we know that x is always y. However if we multiply this by 0 => x * 0 = y * 0 - is that the same equation as before? No, here x and y can be anything and are independent of each other. This example is reversible in the same way as Yacobys
josefx
We can resolve x * 0 = y * 0 with x = 1 and y = 2, these are valid for this equation but not for the original equation x = y. So we can say that the multiplication by zero introduces a large number of invalid results.
josefx
@josefx: Um, do you realise you're saying the same thing Yacoby's original answer says? x*0 (= y*0) = 0 for any x, which is one reason we don't want to define 0/0 as 0. Multiplying by 0 does not introduce any invalid result; it's your inference that "x*0 = y*0 => x=y" that is false: this faulty inference involves division by 0.
ShreevatsaR
@ShreevatsaR Yacoby multiplies by zero => x = y multiplied by zero => x * 0 = y * 0; valid results for x = y only those where x = y; valid results for x * 0 = y * 0 any x is valid independent of y; x = 1 , y = 2 => 1*0 = 2 *0 valid, 1=2 invalid; so this result is invalid for the original equation, but valid for the one with zero multiplication. The only change i made is multiplication by zero (third line of Yacobys answer : multiplication by zero) now tell me where does this result come from?? x = 1 and y = 2 is not valid for the original equation! Note I did not use division in this equation.
josefx
Actually the flaw in the demonstration is that you cannot rearrange that equation. You have `x = 0/0`. Multiply both sides by 0 and you get `x * 0 = 0/0 * 0`. You cannot simplify the right term, as it involves dividing 0 by 0... Or, if you're just saying that anything multiplied by 0 gives 0 your equation just turns into `0 = 0`. That's why this demonstration does not hold.
nico
@nico That is why 0/0 is left as a fraction. I haven't evaluated it so can still manipulate it as I wish. It is designed to show that the range of possible values of x is infinite.
Yacoby
@nico What I am saying is that if the top equation is true, then the bottom equation must also be true but the values of x for which the bottom equation is true is infinite. i.e. it is true for all values of x.
Yacoby
@Yacoby: Yes, but (unless I misunderstood your point) you say that `x * 0 = 0/0 * 0` equals to `x * 0 = 0`, so you are essentially saying that `0/0 * 0 = 0` which you cannot as you are trying to demonstrate what the result of `0/0` is. You could use your proof if you already had defined the result of `0/0`, otherwise you're answering your question using the result of the question itself... which you don't know!
nico
@nico It is well known that for all real numbers and integers: `(a/b) * b = a` Now let `a = b = 0`. I am not evaluating the result of 0/0 is in any way shape or form because it is undefined.
Yacoby
@Yacoby: as far as I know `(a/b) * b = a` is not defined for `a = b = 0`, but I'm not a mathematician so I may be wrong.
nico
@nico Why wouldn't it be defined?
Yacoby
@Yacoby: Because 0/0 is not defined! To do `0 / 0 * 0` you can either do `(0/0) * 0` in which case you do not know the left term or `0 * (0/0)` in which case you do not know the right term.
nico
@nico the *result* of 0/0 is undefined
Yacoby
@Yacoby: exactly, so you are trying to say that `undefined * 0 = 0` which is clearly not the case...
nico
@nico No, the result is undefined. It is still possible to manipulate 0/0. So when I multiply everything by 0, I just cancel the denominator in the fraction 0/0 to get the result 0.
Yacoby
@Yacoby: Cancelling the denominator equals divinig and multiplying by 1. When you say that `2 / 3 * 3 = 2` you actually do `2 * 3 / 3 = 2 * 1 = 2`. But you cannot simplify `0 / 0 * 0` as ` 0 * 1 = 0`: that would imply `0 / 0 = 1`.
nico
+3  A: 

Look at division in reverse: if a/b = c then c*b = a. Now, if you substitute a=b=0, you end up with c*0 = 0. But ANYTHING multiplied by zero equals zero, so the result can be anything at all. You would like 0/0 to be 0, someone else might like it to be 1 (for example, the limiting value of sin(x)/x is 1 when x approaches 0). So the best solution is to leave it undefined and report an error.

zvrba
+3  A: 

Read this article: Division by Zero

Galwegian
@Galwegian since this the best answer here at least, I would like to undo my downvote. If you want to, please edit. ;-)
InsertNickHere
A: 

How many times does 0 go into 0? 5. Yes - 5 * 0 = 0, 11. Yes - 11 * 0 = 0, 43. Yes - 43 * 0 = 0. Perhaps you can see why it's undefined now? :)

Will A
+5  A: 

Here's a full explanation:

http://en.wikipedia.org/wiki/Division_by_zero

( Including the proof that 1 = 2 :-) )

You normally deal with this in programming by using an if statement to get the desired behaviour for your application.

tovare
+1  A: 

Since x/y=z should be equivalent to x=yz, and any z would satisfy 0=0z, how useful would such an 'exception' be?

Pontus Gagge
Normally, I tend to ignore downvotes, especially on questions which are borderline offtopic to SO, but I must say I'm curious: do you consider the answer wrong, misleading, unhelpful, irrelevant -- or do you just hate maths?
Pontus Gagge
A: 

If a/b = c, then a = b * c. In the case of a=0 and b=0, c can be anything because 0 * c = 0 will be true for all possible values of c. Therefore, 0/0 is undefined.

fmunkert
+43  A: 

This is maths rather than programming, but briefly:

  • It's in some sense justifiable to assign a 'value' of positive-infinity to some-strictly-positive-quantity / 0, because the limit is well-defined

  • However, the limit of x / y as x and y both tend to zero depends on the path they take. For example, lim (x -> 0) 2x / x is clearly 2, whereas lim (x -> 0) x / 5x is clearly 1/5. The mathematical definition of a limit requires that it is the same whatever path is followed to the limit.

AakashM
+1 for the first answer I've seen that explains this in terms of limits
Martin B
It's good to learn the theory behind this, but limits aren't really meaningful in the discrete world.
Larry Wang
@Kaestur: Good point, hadn't considered the rationals when I made that comment. The "x * 0 = 0" argument is probably the most general one and works for any type of field, not just the reals...
Martin B
@Kaestur Hakarl: Actually, limits are meaningful in the discrete world too (in any metric space, not necessarily complete) — it's just that the limit (e.g. of rationals) may not lie within the discrete set. In other words: even if limited to some fixed accuracy, we can still observe things like 0.0000002/0.0000001=2, while 0.0000001/0.0000005=1/5.
ShreevatsaR
@ShreevatsaR Of course, everyone has their own definition of 'meaningful.' The standard representations of numbers in a computer (float, double, etc) are not closed, and metrics are maps to R anyways. It just bothers me a little that so many answers talk about limits when we don't really have a good definition for 'limit' in terms of numbers a computer understands. Your examples are correct, of course, but not terribly useful. Once we reach the limits of our accuracy, why make assumptions about what happens past that when a more robust explanation exists?
Larry Wang
A simple example: f(x)=0 for x<=2^100, 1 for x>=2^100+2^-100, and a straight line in between. We know the limit as x goes to 2^100+2^-101 exists, but anyone whose precision is not fine enough may think the limit does not exist, and of course, you can construct an example for any precision. Better to avoid dealing with limits in situations like the original question when you have a choice.
Larry Wang
@Kaestur: One can argue that math in the real domain is an anaylitic continuation of math in the integer of IEEE floating point domain, and that one can therefore use results derived from real (or even complex after we extend again) domain in integer arithmetic. 0/0 is fundamentally undefined, so it would be bad practice to assign it some usable value in the CPU.
dmckee
@dmckee: It depends on the specific result. To use your example, if you were to tell someone that in the reals, exponential was a bounded function and sine unbounded, do you think they would accept the result because you say "it works in C, and R is part of C?" Some results may still hold, and 0/0 being undefined certainly does, but that doesn't mean the same proofs will all work.
Larry Wang
+2  A: 

The structure of modern math is set by mathematicians who think in terms of axioms. Having additional axioms that aren't productive and don't really allow one to do more stuff is against the ideal of having clear math.

Christian
A: 

why not make an exception for this case?

Because:

  • as others said, it's not that easy;)
  • there's no application for defining 0/0 - adding exception would complicate mathematics for no gains.
el.pescado
A: 

As Andrzej Doyle said:

Anything dived by zero is infinity. 0/0 is also infinity. You can't get 0/0 = 1. That's the basic principle of maths. That's how the whole world goes round. But you can sure edit a program to say "0/0 is not possible" or "Cannot divide by zero" as they say in cell phones.

subanki
It is possible to turn an indeterminate form into a determinate form using derivatives in order to evaluate the limit of an equation. See "L'Hôpital's rule" for further information.
Tony Breyal
+5  A: 

The problem is with the denominator. The numerator is effectively irrelevant.

10 / n
10 / 1 = 10
10 / 0.1 = 100
10 / 0.001 = 1,000
10 / 0.0001 = 10,000
Therefore: 10 / 0 = infinity (in the limit as n reaches 0)

The Pattern is that as n gets smaller, the results gets bigger. At n = 0, the result is infinity, which is a unstable or non-fixed point. You can't write infinity down as a number, because it isn't, it's a concept of an ever increasing number.

Otherwise, you could think of it mathematically using the laws on logarithms and thus take division out of the equation altogther:

    log(0/0) = log(0) - log(0)

BUT

    log(0) = -infinity

Again, the problem is the the result is undefined because it's a concept and not a numerical number you can input.

Having said all this, if you're interested in how to turn an indeterminate form into a determinate form, look up l'Hopital's rule, which effectively says:

f(x) / g(x) = f'(x) / g'(x)

assuming the limit exists, and therefore you can get a result which is a fixed point instead of a unstable point.

Hope that helps a little,

Tony Breyal

P.S. using the rules of logs is often a good computational way to get around the problems of performing operations which result in numbers which are so infinitesimal small that given the precision of a machine’s floating point values, is indistinguishable from zero. Practical programming example is 'maximum likelihood' which generally has to make use of logs in order to keep solutions stable

Tony Breyal
If n/0 = ∞, then n = 0 * ∞ = 0. If what you write is true then all numbers are equal to 0.
Yacoby
@Yacoby - Infinity is a concept, not a number and therefore you can not multiply it by anything and still expect to get a meaningful result. I think you're interpreting infinity to be a quantitative metric number in the equation you give, when instead it is in fact a qualitative descriptive concept. Hope that makes sense :-)
Tony Breyal
@Tony I would suppose it is going to be how you treat infinity. Using limits and defining infinity as a infinite limit, the result z/0 = ∞ would be correct. To my very limited knowledge this isn't true outside things like complex analysis. *shrugs*
Yacoby
@Yacoby Asymptomatically speaking that's true that it equals infinity in the limit. I don't see where that wouldn't be true to be honest...
Tony Breyal
+1  A: 

Another explanation of why 0/0 is undefined is that you could write:

0/0 = (4 - 4)/0 = 4/0 - 4/0

And 4/0 is undefined.

Florin
+17  A: 

(Was inspired by Tony Breyal's rather good answer to post one of my own)

Zero is a tricky and subtle beast - it does not conform to the usual laws of algebra as we know them.

Zero divided by any number (except zero itself) is zero. Put more mathematically:

 0/n = 0      for all non-zero numbers n.

You get into the tricky realms when you try to divide by zero itself. It's not true that a number divided by 0 is always undefined. It depends on the problem. I'm going to give you an example from calculus where the number 0/0 is defined.

Say we have two functions, f(x) and g(x). If you take their quotient, f(x)/g(x), you get another function. Let's call this h(x).

You can also take limits of functions. For example, the limit of a function f(x) as x goes to 2 is the value that the function gets closest to as it takes on x's that approach 2. We would write this limit as:

 lim{x->2} f(x) 

This is a pretty intuitive notion. Just draw a graph of your function, and move your pencil along it. As the x values approach 2, see where the function goes.

Now for our example. Let:

 f(x) = 2x - 2
 g(x) = x - 1

and consider their quotient:

 h(x) = f(x)/g(x)

What if we want the lim{x->1} h(x)? There are theorems that say that

 lim{x->1} h(x) = lim{x->1} f(x) / g(x) 
                = (lim{x->1} f(x)) / (lim{x->1} g(x))  
                = (lim{x->1} 2x-2) / (lim{x->1} x-1)
                =~ [2*(1) - 2] / [(1) - 1]  # informally speaking...
                = 0 / 0 
                  (!!!)

So we now have:

 lim{x->1} h(x) = 0/0

But I can employ another theorem, called l'Hopital's rule, that tells me that this limit is also equal to 2. So in this case, 0/0 = 2 (didn't I tell you it was a strange beast?)

Here's another bit of weirdness with 0. Let's say that 0/0 followed that old algebraic rule that anything divided by itself is 1. Then you can do the following proof:

We're given that:

 0/0 = 1

Now multiply both sides by any number n.

 n * (0/0) = n * 1

Simplify both sides:

 (n*0)/0 = n 
 (0/0) = n 

Again, use the assumption that 0/0 = 1:

 1 = n 

So we just proved that all other numbers n are equal to 1! So 0/0 can't be equal to 1.

walks on back to her home over at mathoverflow.com

Clair Crossupton
From l'Hopital's rule (taking first derivatives): f(x)/g(x) = f'(x)/g'(x)Therefore: (2x-2)/(x - 1) = 2/1 = 2 ...I always thought this was cool.
Tony Breyal
I'll give you a point for bringing up l'Hopital, I love l'Hopital!
El Guapo
It's called l'Hopital's rule in English? You always learn something! I always assumed in English you would say "de l'Hopital's rule"... why do you guys truncate poor Guillaume's surname ? :) http://en.wikipedia.org/wiki/Guillaume_de_l%27H%C3%B4pital
nico
@nico it is also known as Bernoulli's rule :)
Clair Crossupton
A: 

This is what I'd do:

function div(a, b) {
    if(b === 0 && a !== 0) {
        return undefined;
    }
    if(b === 0 && a === 0) {
        return Math.random;
    }
    return a/b;
}
bluesmoon