+ Reply to Thread
Results 1 to 4 of 4

Excel Equation Solving...? Critical

Hybrid View

  1. #1
    Registered User
    Join Date
    11-23-2006
    Posts
    2

    Question Excel Equation Solving...? Critical

    =IF(G8>=2000,S47,G8/2000*S47)+(((N6+R6)/2)*((IF(G26="RCG",0.05,0)+IF(G28="RCG",0.025,0)))+((V42*0.1)*(G8*1000)))

    Assuming:

    G8 = 4000
    S47 = 2453
    N6 = 39000
    R6 = 85800
    G26 = RCG
    G28 = RCG
    V42 = 0.62%

    Answer should be = 9629

    PLZ anybody solve it step by step.

  2. #2
    Registered User
    Join Date
    11-16-2006
    Posts
    80
    Quote Originally Posted by eyewinkler
    =IF(G8>=2000,S47,G8/2000*S47)+(((N6+R6)/2)*((IF(G26="RCG",0.05,0)+IF(G28="RCG",0.025,0)))+((V42*0.1)*(G8*1000)))

    Assuming:

    G8 = 4000
    S47 = 2453
    N6 = 39000
    R6 = 85800
    G26 = RCG
    G28 = RCG
    V42 = 0.62%

    Answer should be = 9629

    PLZ anybody solve it step by step.
    Hi,

    I have tried it a couple of times in excel and I kept gettting the value:

    255133

    I broke it down into different cells e.g

    A2=IF(G8>=2000,S47,G8/2000*S47)
    A3=(N6+R6)/2
    A4=IF(G26="RCG",0.05,0)
    A5=IF(G28="RCG",0.025,0)
    A6=V42*0.1
    A7=G8*1000

    A1=A2+((A3)*((A4+A5))+((A6)*(A7)))

    Same value:
    255133

    So I thought I would give it a go in VBA:

    Sub Macro1()
    
        'I tried to break it down into different variables
        '=IF(G8>=2000,S47,G8/2000*S47)+(((N6+R6)/2)*((IF(G26="RCG",0.05,0)+IF(G28="RCG",0.025,0)))+ ((V42*0.1)*(G8*1000)))
        '=           value1           +(( value2  )*((       value3       +         value4      ))+ (( value5)*( value6)))
        
        Dim G8_var, S47_var, N6_var, R6_varm, value1, value2, value6 As Long
        Dim V42_var, value3, value4, value5 As Double
        Dim G26_var, G28_var As String
        Dim finalValue ' dont know what type it will be yet
    
        G8_var = 4000
        S47_var = 2453
        N6_var = 39000
        R6_var = 85800
        G26_var = "RCG"
        G28_var = "RCG"
        V42_var = 0.62
        
        If G8_var >= 2000 Then ' value1 will = 2453
            value1 = 2453
        Else
            value1 = (4000 / 2000) * 2453
        End If
        
        value2 = (N6_var + R6_var) / 2 ' value2 will = 62400
        
        If G26_var = "RCG" Then ' value3 will = 0.05
            value3 = 0.05
        Else
            value3 = 0
        End If
        
        If G28_var = "RCG" Then ' value4 will = 0.025
            value4 = 0.025
        Else
            value4 = 0
        End If
        
        value5 = V42_var * 0.1  ' value5 will = 0.025
        
        value6 = G8_var * 1000  ' value6 will = 4000000
        
        finalValue = value1 + ((value2) * ((value3 + value4)) + ((value5) * (value6)))
        
        Sheets("Sheet1").Range("A1").Value = finalValue
    End Sub
    Guess what I came up with the same value:
    255133

    Tell me this,

    How do you know the answer of the equation?

  3. #3
    Registered User
    Join Date
    11-23-2006
    Posts
    2

    Arrow Excell Problem. Plz anybody solve it step by step. I am stuck...?

    dont break it down
    i did the same formula in the excell
    check it out
    i upload excel file
    Attached Files Attached Files
    Last edited by eyewinkler; 11-23-2006 at 07:54 AM.

  4. #4
    Registered User
    Join Date
    11-16-2006
    Posts
    80
    Quote Originally Posted by eyewinkler
    dont break it down
    i did the same formula in the excell
    check it out
    i upload excel file
    I see what I done.

    I had V42 a 0.62 instead of 0.062.

    I dont actually understand what you are asking by "solve it step by step"

    confused!
    mccreaso

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1