Win a copy of Java Challengers this week in the Java in General forum!

since Apr 04, 2005

Cows and Likes

Cows

Total received

0

In last 30 days

0

Total given

0

Likes

Total received

0

Received in last 30 days

0

Total given

0

Given in last 30 days

0

Forums and Threads

Scavenger Hunt

Ranch Hand Scavenger Hunt

Greenhorn Scavenger Hunt

thanks. I really don't know physics or electronics very well. i just went to a physics web page and grabbed a formula that would (IMHO) help substantiate my point.

I thought so. Not that I know much about physics either. I'm starting to feel old now. It wasn't that long ago that I studied it at college. Maybe it's the Alzeimer's getting the better of me.

16 years ago

Is 2y = 2x equal to y = x or not? I rather feel that it is. That's the beauty of algebra. We can simplify it but it is still equal to the original expression. I have to say that when we have to resort to saying these two lines are exactly equal except for the non-existant hole which we have to add to satisfy out generally accepted and time-honoured traditonal view of division by 0 it doesn't convince me very much. All things being equal would or would not my proposed implementation of division by 0 produce a more consistent rendering of the two graphs? I think we all know that the answer is yes and there is no practical usage of inserting the non-existant hole of 0 dimensions other than to convince our unquestioning students that our current definition of division by 0 is in fact the correct one.

Just out of interest if the graph represented what we should pay employee y for efforts x how much should pay employee y when he puts in effort x where the hole exists? Should we send him home after a months hard work saying "sorry we're not paying you this month because our graph was derived from the more complex equation which doesn't allow for division by 0. Had we used the simple and otherwise equivalent linear version of the graph your family could have eaten this month and you could have paid the mortgage but unfortunately your going to have to risk repossession this month and let that be lesson to you for over-performing. You're making the other employees look bad!!!"???

I'm sorry but although your example was good I just can't see the practical usage other than persuading teenage algebra students that there is a non-existant hole in the equivalent graph.

Just out of interest if the graph represented what we should pay employee y for efforts x how much should pay employee y when he puts in effort x where the hole exists? Should we send him home after a months hard work saying "sorry we're not paying you this month because our graph was derived from the more complex equation which doesn't allow for division by 0. Had we used the simple and otherwise equivalent linear version of the graph your family could have eaten this month and you could have paid the mortgage but unfortunately your going to have to risk repossession this month and let that be lesson to you for over-performing. You're making the other employees look bad!!!"???

I'm sorry but although your example was good I just can't see the practical usage other than persuading teenage algebra students that there is a non-existant hole in the equivalent graph.

16 years ago

erroneous use of the term "hypothesize".

Erroneous eh??? Well, if 0.333(3) is the shorthand, I'd be interested to see you produce the longhand.

16 years ago

i did not say "it is in fact a simple linear graph". what i said was, using algebra, we can convert the 'complicated' equation into a 'simpler' one, with the same solution set (i.e. for every x in the the domain, i get the same y in the range). However, since my original equation does NOT allow for me to have an x value of 5, i can't use an x value of 5 in my 'simplified' version of the equation. it's simply not allowed.

now, if i were JUST graphing y = x+2, then there would be no hole. but i am not. i am graphing that more complicated equation. So i am bound by ITS domain. HOW i go about graphing that is irrelavent to the actual solution.

One question as I have evidently not understood. Do both graphs produce the same line or not (apart from the "hole")?

16 years ago

it simply has no size - as in it has a width of 0, and a height of 0

Right, so what your so saying is, is that your graph has a hole with width and height equal to 0.

Errrm, isn't that the same as there being no hole?

16 years ago

With regard to our 0.111(1), 0.333(3) etc. I wanted to add a final comment.

The reason we propose with this notation to append an infinte number 3's to 0.333 is because no matter how many 3's we append the actual amount is always slightly greater, and the second we append a 4 the actual amount is always slightly less. Therefore when we say that 1/3 = 0.333(3) what we are actually saying is that due to an inadequacy of expression in base 10 we denote 1/3 as 0.333(3) because no matter how many 3's we append the actual amount is always slightly greater. So we hypothesize that 1/3 is equal to 0.333 with an infinite number of 3's appended. However, as has already been agreed since infinity is a number which does not exist we cannot say that 1/3 is EXACTLY equal to 0.333 with an infinite number of 3's appended as such a number cannot and does not exist.

Hence when we say that 0.333(3) (which is merely an imperfect representation of 1/3) * 3 = 0.999(9) what we are actually saying is that the result is always slightly greater than 0.999 no matter how many 9's we append. However, contrary to 1/3 we have no difficulty in exactly representing this number in base 10 as it is precisely equal to 1.

The reason we propose with this notation to append an infinte number 3's to 0.333 is because no matter how many 3's we append the actual amount is always slightly greater, and the second we append a 4 the actual amount is always slightly less. Therefore when we say that 1/3 = 0.333(3) what we are actually saying is that due to an inadequacy of expression in base 10 we denote 1/3 as 0.333(3) because no matter how many 3's we append the actual amount is always slightly greater. So we hypothesize that 1/3 is equal to 0.333 with an infinite number of 3's appended. However, as has already been agreed since infinity is a number which does not exist we cannot say that 1/3 is EXACTLY equal to 0.333 with an infinite number of 3's appended as such a number cannot and does not exist.

Hence when we say that 0.333(3) (which is merely an imperfect representation of 1/3) * 3 = 0.999(9) what we are actually saying is that the result is always slightly greater than 0.999 no matter how many 9's we append. However, contrary to 1/3 we have no difficulty in exactly representing this number in base 10 as it is precisely equal to 1.

16 years ago

Thanks guys for the easier to follow explanation of the graphs.

However, now it has become cleare to me several questions come to mind. Seeing as you explained that the equation that looks complicated is in actual fact a simple linear graph does it seem normal to you for a linear graph to have a hole in it?

Where would you place the hole in y = x + 2 or 2y = x ?

And this hole which you defined as being exactly a point in size. How big is a point in mm? Would it not be our infamous smallest number greater than 0 which we have already agreed does not exist? Would you not agree that your calculators are producing a flawed graph by inserting a hole in a linear graph?

I'm no mathematical expert but I never remember my teacher saying that linear graphs have a hole in them. Wouldn't you find it strange and inconsistent that a calculator produces a graph without a hole when given y = x + 2, yet produces a graph with a hole from a more complex input which mathematically simplifies to the same thing.

All things considered, wouldn't my proposed implementation of division by 0 give a more consistent output?

And furthermore seeing as before it was argued that since multiplication and division are inverse operations shouldn't they cancel one another out?

just as 2*5/2 cancels to produce 5 where is the problem with cancelling

for all values of x even when x happens to equal 0?

However, now it has become cleare to me several questions come to mind. Seeing as you explained that the equation that looks complicated is in actual fact a simple linear graph does it seem normal to you for a linear graph to have a hole in it?

Where would you place the hole in y = x + 2 or 2y = x ?

And this hole which you defined as being exactly a point in size. How big is a point in mm? Would it not be our infamous smallest number greater than 0 which we have already agreed does not exist? Would you not agree that your calculators are producing a flawed graph by inserting a hole in a linear graph?

I'm no mathematical expert but I never remember my teacher saying that linear graphs have a hole in them. Wouldn't you find it strange and inconsistent that a calculator produces a graph without a hole when given y = x + 2, yet produces a graph with a hole from a more complex input which mathematically simplifies to the same thing.

All things considered, wouldn't my proposed implementation of division by 0 give a more consistent output?

And furthermore seeing as before it was argued that since multiplication and division are inverse operations shouldn't they cancel one another out?

just as 2*5/2 cancels to produce 5 where is the problem with cancelling

for all values of x even when x happens to equal 0?

16 years ago

It doesn't mention it in the book because it's not relevant for the exam but it does say in the book that you have 1 ServletContext object per web-app per JVM, so the point is insinuated but not elaborated on as it won't help you pass the exam.

16 years ago

code:

x^2 - 3x -10

y = ----------------

x - 5

And as for this one, could you run that one by me again please, but slower this time? I have absolutely no idea what your point is here.

I gather that you expect there to be an unnoticabley small hole in your graph but I'm not alltogether sure I understand why you expect this behaviour.

Remember, you are speaking to an idiot who thinks you can divide by 0 and that 3*4=11, so please give a slow step by step explanation of why we should expect this behaviour.

And while your at it could you also tell me when in a program you would expect to plot a graph that fulfills such a behaviour.

16 years ago

code:

void orangesPerEmployee(int oranges, int employees){

return oranges/employees;

}

if orangesPerEmployees = 0, code will likely assume:

"Oh, there weren't any oranges for the employees! We must need more oranges"

when in fact there was 6.022 x 10^23 oranges, just no employees.

Just out of interest, what kind of a plonker would base stock ordering on how many surplus oranges were divided out to employees. Most folk I know would use the stock count and maybe past sales patterns to predict future demand.

16 years ago

Or we can listen to them to get a better understanding what they mean. Until then, I'll be asleep in the corner.

I totally agree. It seems we were all agreed that the smallest number doesn't exist all along.

So let's get back to my proposed behaviour of division by 0. As far as I'm concerned I still haven't been proven wrong. Although Jim gave a few example that almost qualified.

I'm sure if we all try harder someone can disprove my preferred implementation.

Anyway, it seems far more interesting than going round in circles when we already all agree that there is no smallest number greater than 0.

Everyone was really forthcoming when the topic was contraversial. And I had a whale of a time. So come on who thinks they can defeat my division of 0 theory. Who can demonstrate an example where the remainder should not be equal to the original quantity? And where the ** did the man who doesn't believe in 0 come from? That's sounds weird even to me!!!

Especially for you Mr. Singh:

Shall we throw errors for 1 + 0?

What about 7 - 0?

When you do the accounts at the end of the month and you haven't sold anything what will you enter in your accounts? Will you pretend you have sold 1 because you don't beleive in 0?

How many people do you know who are over 5 metres tall?

How many dolphins have you seen flying a hang glider?

If you have $1000 in the bank and you take the $1000 out how much will be left in the bank?

How much sense does your argument make?

I beleive you will find the answer to all the above questions to be a non existent figure by your own reckoning.

16 years ago

For instance: If you divide up a pie into 9 pieces, you could say each piece is "1/9" of the original. Or it might be "0.111(1)" of the originial. Or it might be "0.1 (base 9)" of the original. The fact that in base 10 the piece of pie has a repeating representation while in base 9 it has a terminating representation doesn't change the piece itself; it's still just one ninth of the pie.

Well said!

As regards the decimal representations 0.111(1), 0.222(2), 0.333(3), 0.444(4), 0.555(5), 0.666(6), 0.777(7) and 0.888(8) are valid as there is no other way of representing these figures in decimal without resorting to a fraction.

However, the same cannot be said for 0.999(9) as nobody has any difficulty in reading and understanding 1. In fact the only time we see 0.999(9) mathematically is when we do an operation similar to the following with a calculator:

And this is only due to the fact that the calculator, due its limitations, has lost that certain something that makes 1/3 ever so slightly larger than 0.333 .

But when you ask a human to do the same series of operations, instinctively he/she instantly writes 1 as the result as they remember and account for the loss of precision.

Anyway, even if we are to admit and widely accept that 0.999(9) = 1 it would only stand to uphold the evidence provided thus far that there is no smallest number greater than 0 and hence no greatest number lesser than 1.

How do you feel in this regard?

Is there a smallest number greater than 0?

If so is this the greatest number lesser than 0.1? 0.0999(9)

And this 4.999(9)? Does that equal 5?

And finally what about this? 7.1000(0)1 Is this the smallest number greater than 7.1?

16 years ago

1) I agree. Once a session has been invalidated or timed-out requests can no longer see the session. Otherwise what is the point of invalidating the session. Bogus callers would be able to hijack invalidated sessions.

16 years ago

The exam only concentrates on GET and POST seeing as in real life they are the only two methods you are likely to use. However, you may be asked questions such as which method is useful for requesting only the header and so you only need to know the nasic function of the other methods.

As regards idempotency you need to know that GET can cause no side effect (i.e is idempotent) while POST can cause side-effects (not idempotent)

Remember idempotency is good. Only with POST do you need to ensure that orders are not sent twice etc.

As regards idempotency you need to know that GET can cause no side effect (i.e is idempotent) while POST can cause side-effects (not idempotent)

Remember idempotency is good. Only with POST do you need to ensure that orders are not sent twice etc.

16 years ago

Like Jose says it wouldn't do you any harm to learn them but I wouldn't go doing any all nighters staring at pages in the hopes they go into your head. Write, write, write!!! It's just like any language, the more you practice the more it just becomes second nature and the less likely you will be caught out on the exam.

And when you develop you won't need to keep running to the API all the time.

And when you develop you won't need to keep running to the API all the time.

16 years ago