# Use of floor and ceiling functions in physics problems

1. Jul 24, 2016

### Agustin

2. Jul 24, 2016

### haruspex

3. Jul 24, 2016

### Agustin

I want to know if my reasoning is right. Wether I made mistakes or not.

4. Jul 24, 2016

### haruspex

Unfortunately it is very hard to read on my iPad because some of the special symbols are coming out as strings of question marks.
There appear to be sign errors in the early equations, but these might just be your transcription into the post.
Overall, I would say it is unnecessarily elaborate. You can write down straight away that the total distance traversed over the frictional area is $d=\frac {k\Delta x^2}{2F}$. Next, we can discard from d whole multiples of 2L, giving $d-2L\lfloor \frac d{2L}\rfloor$.

I'll take a look on a real computer later to see if the symbols become readable.

5. Jul 25, 2016

### Agustin

That equation does not work for odd numbers. The problem asks the distance it stops relative to the point B. For example if d=7,25l the block will end up at 0.75l away from B, if we plug in those values in the equation youve given:
d-2l⌊d/2l⌋=7.25l-2l⌊7.25l/2l⌋=7.25l-2l⌊3.625⌋=7.25l-6l=1.25l

Last edited: Jul 25, 2016
6. Jul 25, 2016

### jbriggs444

Haruspex is using a different convention for the meaning of "d" than you are. He defines it as...
and then takes the remainder modulo 2L.

Translating that result to give the asked-for answer is a rather trivial exercise.

7. Jul 25, 2016

### Agustin

Maybe it is trivial, but Im not looking for a trivial solution, but the general solution. That equation does not immediately give you the distance asked for, therefore it is a solution yet it isnt the complete solution. The formula I present on the document immediately gives the distance asked for wich is the point of the problem. And not just a simple formula.

8. Jul 25, 2016

### jbriggs444

You do understand that the rules of this forum preclude the handing out of complete solutions?

9. Jul 25, 2016

### Agustin

If I could post on any other forum I would, however I can´t so I have no choice but to post here. Am I to blame for that?

10. Jul 25, 2016

### haruspex

Thanks for jumping in, j. Yes, I was just illustrating how the first steps could be done much more simply and was leaving it to Agustin to take it from there.
Meanwhile, I could not verify Agustin's original treatment without finding a way to view it properly, and that has not happened yet.
If I understand jbriggs' response, he was saying that obtaining the general solution from the point I got to was a trivial exercise. (But I would not have said it was that trivial )

11. Jul 26, 2016

### haruspex

OK, I have now viewed the OP in a legible format and find that the final equation is incorrect.
Consider e.g. n=1. This produces L/2 instead of L. Similarly any odd integer value of n.
Likewise, an even integer gives L/2 instead of 0.

12. Jul 27, 2016

### Agustin

Youre right. I forgot to check that part, that means my proof of the particular case on page 6 is wrong. Ill check it and try working out a general formula that works. I greatly appreciate your time.

13. Jul 27, 2016

### Agustin

Ive already checked it, I think the formula is valid.

14. Jul 27, 2016

### haruspex

Then how do you explain that it gives the wrong answers for integer values of n?

15. Jul 27, 2016

### Agustin

It does? It seems to work just fine for me, when n=1
dA=(l/2)(1+(-1) ^⌊n⌋(2(n-⌊n⌋)-1)=(l/2)(1-(2(1-1)-1))=(l/2)(1-(-1))=(l/2)(2)=l
If n=2
dA=(l/2)(1+(-1) ^⌊n⌋(2(n-⌊n⌋)-1)=(l/2)(1+(-1) ^2(2(2-2)-1)=(l/2)(1+(-1))=0

16. Jul 27, 2016

### haruspex

You did not say that you had changed the equation. It looks right now.

17. Jul 27, 2016

### Agustin

Sorry. Yes Im very excited that it works. Doesnt it seem interesting how much planning can some simple math do? It thrills me