The Museum of HP Calculators

HP Forum Archive 19

[ Return to Index | Top of Index ]

More Challenges
Message #1 Posted by Chuck on 2 Feb 2009, 8:40 p.m.

Since I didn't get to play with the latest challenges a whole lot, I thought I'd make one up. Here's a little problem I gave my students today...

Consider: f(x) = Floor[1/x]/x (or the greatest integer of 1/x, divided by x).

We were talking about the derivative of such a beast, and found some interesting things. Can you find if or where f'(x) = 1, 1.5, 2, or 3. We'll need to bend the rules of differentiation a bit and consider one sided limits on a few of the values (graph it and you'll see why).

I'd be curious if one could write/run a program on an Hp to solve f'(x)=3 to an accuracy enough to "guess" the exact value. So far, even Mathematica hasn't found the solution explicitly (bisection method yes, but no Solve), but it's more of a user error than a software limitation error.

My luck, someone here will get the answer(s) in 7 minutes or less. :)

      
Re: More Challenges
Message #2 Posted by Allen on 2 Feb 2009, 9:08 p.m.,
in response to message #1 by Chuck

not sure I understand the question.. Can you give an example of the "Floor" function, since it does not behave the same way I expect.

Here's they way Excel and HP calculators interpret this problem:

F(3) = Floor(1/3)/3 = Floor(.3333...)/3= 0/3= 0
Excel: FLOOR(1/3,1)=0
RPN: 3 [1/x] FLOOR -> 0
Wolfram:Floor(1/3)=0
Am I missing something?

Edited: 2 Feb 2009, 9:08 p.m.

            
Re: More Challenges
Message #3 Posted by David Hayden on 2 Feb 2009, 9:12 p.m.,
in response to message #2 by Allen

I think it gets interesting for 0 < x < 1. As you've discovered, for all x > 1, f(x) = 0

Dave

      
Re: More Challenges
Message #4 Posted by Allen on 2 Feb 2009, 9:11 p.m.,
in response to message #1 by Chuck

perhaps I am having a hard time reading the f'(x).. This looks almost exactly like f(x) in times new roman font.

            
Re: More Challenges
Message #5 Posted by Chuck on 2 Feb 2009, 9:38 p.m.,
in response to message #4 by Allen

Agree, the font is not great. Also, the "Floor" function is Mathematica's name for the greatest integer function. Here's another go at it...

let f(x)=Int[1/x]/x

find where f'(x)=3

David is correct, it's not very interesting for x>1, but is interesting for x<1. Our interest actually lies on the interval [-1,0].

CHUCK

                  
Re: More Challenges
Message #6 Posted by David Hayden on 2 Feb 2009, 11:09 p.m.,
in response to message #5 by Chuck

Okay, my calculus is really rusty, but here's what I came up with. There's a good chance that I've gotten something horribly wrong, in which case, corrections will be cheerfully accepted.

To keep my head from hurting, I recast the problem:

Let u(x) = 1/x
Let g(u) = floor(u)*u
Then f(x) = floor(1/x)/x is the same as g(u(x))

If N is a negative integer then For u = ( N , N+1 ], floor(u) is the constant N+1 and g(u) = (N+1)*u.

Inside one of these intervals, the derivative of f(x) is: f'(x) = g'(u) * u'(x) = (N+1) * -1/x^2 = -(N+1) / x^2 = -(N+1) * u^2

Now we can find where f'(x)=3:

3 = -(N+1) * u^2 u = sqrt(-3/(N+1)) or -sqrt(-3/(N+1))

Since we already said that N is a negative integer and u is in the interval (N, N+1], that means u is a negative number also, so we can get rid of the positive solution and we're left with: u = -sqrt(-3/(N+1))

Now lets try some solutions. N=-1 won't work because -3/(N+1) causes division by zero.

How about N=-2? u = -sqrt(-3/(-1)) = -sqrt(3) = -1.732050...

Checking our assumption: N <? u <=? N+1 -2 < -1.732050... <= -1 That works.

Last but not least, we solve for x:

u = 1/x -sqrt(3) = 1/x x = -1/sqrt(3)

                        
Re: More Challenges
Message #7 Posted by Chuck on 3 Feb 2009, 12:57 a.m.,
in response to message #6 by David Hayden

Aha. Very close, but off by a small factor. I think there may be a slight error with the floor function on negative intervals with how you defined g. However, your method got me the answer analytically, or at least agrees with what I found earlier.

CHUCK

                              
Re: More Challenges
Message #8 Posted by David Hayden on 3 Feb 2009, 8:49 a.m.,
in response to message #7 by Chuck

Thanks, Chuck. I suspect I've got the definition of floor() wrong. If floor(x) is "the largest integer that's less than x" rather than "the integer formed by lopping off the fractional part" then I get:

If N is a negative integer then For u = [ N , N+1 ), floor(u) is N and g(u) = N*u.
So f'(x) = -N*u^2
And if f'(x)=3 then u = -sqrt(-3/N)
So for N=-1, we get u = -sqrt(3) which is outside the interval [-1,0).  But for N=-2, we get u=-sqrt(3/2) which is within the interval [-2,-1].

So with u=1/x, that means the final answer is x=-1/sqrt(3/2)


[ Return to Index | Top of Index ]

Go back to the main exhibit hall