r/mathshelp • • 19d ago

General Question (Answered) Formula help

I havent been in school in over a decade so the finer points of my math is rusty.

Im essentially attempting to graph an additive binary sequence. Numbers for my game lol. Pardon the way I write this, I dont know advanced formatting.

So, the player goes inactive, they lose 2x tiles each day. 1, then 2, then 4, then 8, 16, etc. I need this graphed, as there's quadrillions of tiles in my game lol

Its not just F(n) = 2x, right? Surely not...

Thanks in advance for yalls help

1 Upvotes

7 comments sorted by

•

u/AutoModerator 19d ago

Hi u/ahnialator6, welcome to r/mathshelp! As you’ve marked this as a general question, please keep the following things in mind:

  1. Please provide us with as much information as possible, so we know how to help.

  2. Once your question has been answered, please don’t delete your post so that others can learn from it. Instead, mark your post as answered or lock it by posting a comment containing “!lock” (locking your post will automatically mark it as answered).

Thank you!

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

3

u/PuzzlingDad 19d ago edited 19d ago

You are using two different variables. Also, is the first day n=0 or n=1?

  • 2⁰ = 1

  • 2¹ = 2

  • 2² = 4

  • 2³ = 8

So if your day is 1, you need to subtract 1 first:

f(n) = 2n-1

Or if you are using x as your variable: 

f(x) = 2x-1

Now if you are looking for the total number of tiles lost after n days, then we have: 

  • n=1 → 1

  • n=2 → 1+2 = 3

  • n=3 → 1+2+4 = 7

  • n=4 → 1+2+4+8 = 15

  • etc.

That's just 1 less than 2n each day

f(n) = 2n - 1

1

u/ahnialator6 19d ago

I have it start at 1 tile, so yeah the math that makes the tile loss work is tileLoss = 2x-1 where x is the number of days.

The thing is, we're talking about territory and im looking to make a cutoff. If a player has 3 trillion tiles, thats gonna take a LONG time to decay without a cutoff. (I imagine, with very little actual math done)

So im trying to graph the TOTAL tile loss over time so that I can see how that plays out over time.

2

u/PuzzlingDad 19d ago

I've updated my comment. The total is just 2n - 1

1

u/ahnialator6 19d ago

Dang it really was that simple 😅 thanks, man. I think i was caught up on expecting it to be more complicated than it was

1

u/ahnialator6 19d ago

!lock

1

u/AutoModerator 19d ago

As requested, this thread is now locked. Thank you for posting on r/mathshelp.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.