How Do You Calculate the Reflection of Numbers on a Board of Any Size?

  • Context: Undergrad 
  • Thread starter Thread starter xeon123
  • Start date Start date
  • Tags Tags
    Numbers Reflection
Click For Summary

Discussion Overview

The discussion revolves around finding general functions to calculate the reflection of numbers on a board with multiple rows and positions. Participants explore two specific cases: one involving direct opposition on the board and another involving a displacement of numbers. The scope includes mathematical reasoning and exploratory problem-solving.

Discussion Character

  • Exploratory
  • Mathematical reasoning

Main Points Raised

  • One participant describes a board with 2 rows and 4 positions, seeking a general function to determine the number that is in the opposite position based on given examples.
  • Another participant proposes a specific function for the first case, but notes a limitation regarding an exception needed for certain inputs.
  • A different approach is suggested that involves subtracting from a constant to find the reflected number for both rows, which can be extended to any row and column size.
  • There is a request for a general equation that applies to all cases, but one participant expresses doubt about the feasibility of such a solution.

Areas of Agreement / Disagreement

Participants do not reach a consensus on a single general equation for the reflection of numbers, and multiple approaches are presented without agreement on which is correct or most effective.

Contextual Notes

Participants express uncertainty regarding the generalizability of their proposed functions and the need for exceptions in certain cases. The discussion reflects various interpretations of the problem without resolving the mathematical complexities involved.

Who May Find This Useful

Individuals interested in mathematical problem-solving, particularly in combinatorial or algorithmic contexts, may find this discussion relevant.

xeon123
Messages
90
Reaction score
0
Hi,

I've this board, like shown in attachment, that has 2 rows. Each rows have 4 places. I'm trying to find a general function that gives me the reflection of the numbers.

I've 2 questions, so I put each question in a item.

a) Like shown in case a) of the attachment, If I write the number 1, my function must return the number 4. If I write the number 2, the function must return the number 3. If I write the number 5, must return the number 8, and if I write the number 7, it must return the number 6. And the opposite. If I write the number 4, I'll the number 1, etc...

As you can see, I've divided the card in half, and I'm trying to get the number that is on the opposition position of the card. I'm looking for a general equation, that answers me this for any row of any size. In this example, I've use a row with 4 position, but it could have been 7, 10, 15, etc...

Anyone can help me?

b) On the case b) it's a little different. I'm doing a kind of displacement. If I write the number 1, I'll get the number 3. If I write the number 2, I get the number 4, and the opposite. I'm also looking for a general function that returns me the correspondent value for any size of the row.

Any help?

Thanks,
 
Mathematics news on Phys.org
Here is the attachment.
 

Attachments

Here's your function for (a): {(1, 4), (2, 3), (4, 1), (3, 2), (5, 8), (6, 7), (8, 5), (7, 6)}.
 
I was looking for an equation, and not a function full of constants.

Answer for a):
I think the answer for a) is

z=rowsize
f(x)=[itex]\underline{x/z}*z+(x\%z+3)\%z[/itex]

The [itex]\underline{}[/itex] means floor.

The only problem with this equation is that, when (x%z+3)%z == 0, it gives x-1. For this case I've to create an exception.

Ideally, I would like to find a general equation for all the cases, but it's not possible.

Still missing answer for b).
 
Last edited:
The answer in the first row is 5-the input number:

Put in 1, get out 5-1=4
Put in 2, get out 5-2=3

For the second row its the same but the input numbers are 4 higher

Put in 5, minus 4=1, 5-1=4, plus 4=8
Put in 6, minus 4=2, 5-2=3, plus 4=7

This can be extended to any length row and column.
 
Thanks superg33k , your answer is better.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 11 ·
Replies
11
Views
2K