 My Math Forum Trying to create formula for dividing and summing numbers
 User Name Remember Me? Password

 Elementary Math Fractions, Percentages, Word Problems, Equations, Inequations, Factorization, Expansion

 June 11th, 2016, 03:20 AM #1 Newbie   Joined: Jun 2016 From: Europe Posts: 3 Thanks: 0 Trying to create formula for dividing and summing numbers Hello all, I am trying to create a formula considering having following variables. I would appreciate if you could help me understand this. For an example: I have a number 243 and I have a dividing factor of 3 and I have end point factor which is 1 in this case. I would need: 243 3 81 3 27 3 9 3 3 3 1 3 And in the end sum all numbers n1+n2+n3+n4, which in this case is 364 or if I have a number 2048, diving factor of 4 and end point 2. 2048 4 512 4 128 4 32 4 8 4 2 4 At the end sum result is 2730. Like I said: I have a number, dividing factor and end number. Now I would really like if you could explain me how to get a formula for this. I would really appreciate it. Last edited by skipjack; June 11th, 2016 at 04:09 AM. Reason: diving -> dividing June 11th, 2016, 04:00 AM #2 Math Team   Joined: Jan 2015 From: Alabama Posts: 3,264 Thanks: 902 \First, I am pretty sure you mean "dividing" rather than "diving". So have a dividend Y and a divisor X and you divide X into Y repeatedly until it will no longer divide evenly. We can factor $\displaystyle Y= X^nZ$ where Z includes all factors of Y other than X. Each quotient is $\displaystyle \frac{Y}{X}= \frac{X^Z}{X}= X^{n-1}Z$, $\displaystyle \frac{Y}{X^2}= \frac{X^{n-1}Z}{X}$, etc. until we reach $\displaystyle \frac{X^nZ}{X^n}= Z$. We then add $\displaystyle \frac{X^nZ}{X}+ \frac{X^{n-1}Z}{X}+ \cdot\cdot\cdot+ Z= X^{n-1}+ X^{n-2}Z+ \cdot\cdot\cdot+ Z= (1+ X+ \cdot\cdot\cdot+ X^{n})Z$. That sum is a "finite geometric sum" which can be shown to be equal to $\displaystyle \frac{1- X^{n+1}}{1- X}$. So your formula is $\displaystyle Z\left(\frac{1- X^{n+1}}{1- X}\right)$. In the case of Y= 243, X= 3, $\displaystyle Y= 3^5$ so n= 5 and Z= 1. The formula above give $\displaystyle 1\left(\frac{1- 3^6}{1- 3}\right)= \frac{1- 729}{1- 3}= \frac{-728}{-2}= 364$. Similarly, if Y= 2048 and X= 4, $\displaystyle Y= 4^5(2)$ so n= 5 and Z= 2. The formula above gives $\displaystyle 2\left(\frac{1- 4^6}{1- 4}\right)= 2\left(\frac{1- 4096)}{-3}\right)= 2\frac{4095}{3}= 2730$. Thanks from oleoleole Last edited by skipjack; June 11th, 2016 at 04:06 AM. June 11th, 2016, 04:12 AM #3 Global Moderator   Joined: Dec 2006 Posts: 20,919 Thanks: 2203 If the factor is r and the first and last numbers are a and b, multiply the sum by (r - 1) and notice how most terms cancel. It follows that the formula for the sum is (ar - b)/(r - 1). Thanks from oleoleole June 11th, 2016, 09:31 AM #4 Newbie   Joined: Jun 2016 From: Europe Posts: 3 Thanks: 0 Countryboy and SkipJack. Thank you very much, I have tested both of your formulas. They work excelent. Great minds. Thank you. Tags create, dividing, diving, formula, numbers, suming, summing Thread Tools Show Printable Version Email this Page Display Modes Linear Mode Switch to Hybrid Mode Switch to Threaded Mode Similar Threads Thread Thread Starter Forum Replies Last Post valet Advanced Statistics 0 October 28th, 2014 02:02 PM Mr Davis 97 Pre-Calculus 11 August 17th, 2014 09:05 AM nogar Elementary Math 1 March 14th, 2014 03:39 PM demec Real Analysis 2 November 29th, 2009 10:59 AM godilya Number Theory 5 September 5th, 2009 12:50 PM

 Contact - Home - Forums - Cryptocurrency Forum - Top

Copyright © 2019 My Math Forum. All rights reserved.      