wdprice3 BinaryBuffonary 45912 Posts user info edit post |
I have 3 columns and hundreds of rows. In Col A, a value is calculated based on some outside information. Col B is calculated using the value in Col C. Col C is a value. I need to iterate the value in Col C until Col B = Col A. Then I need to do this for each row of a specific type of data (in other words, not every row has these calcs).
It's easy enough to record a macro and use solver, but in the end, I need that code to be applicable to hundreds of rows, not just the ones in the recorded macro. Solver by itself won't work due to the "problem" being too large.
i = 0 A B C 2 1 4 - (calc doesn't apply to row) 4 3 1
i = 1 A B C 2 2 5 - (calc doesn't apply to row) 4 4 3
and no, I don't really know VBA.
[Edited on May 17, 2017 at 6:16 PM. Reason : .] 5/17/2017 6:15:40 PM |
darkone (\/) (;,,,;) (\/) 11610 Posts user info edit post |
post the column b formula 5/17/2017 6:35:39 PM |
wdprice3 BinaryBuffonary 45912 Posts user info edit post |
((J13+K13*Y13)*Y13)*(((J13+K13*Y13)*Y13)/(J13+2*Y13*SQRT(1+K13^2)))^(2/3))
In this, Col Y would be Col C from the OP. The other Cols listed in the EQ are outside data. 5/17/2017 6:39:11 PM |
FroshKiller All American 51911 Posts user info edit post |
I feel like you are not asking this well. 5/17/2017 7:51:07 PM |
wwwebsurfer All American 10217 Posts user info edit post |
For a small set of C's you could put them in a row, then generate a matrix of B values, then search that row for the answer you seek in a final column via lookup.
Otherwise output this ish to a CSV file and munch it with PERL.
Or post some real sample data 5/17/2017 10:12:12 PM |
darkone (\/) (;,,,;) (\/) 11610 Posts user info edit post |
It's a horrendous equation, but solve for C (or Y in your case). 5/19/2017 12:21:51 PM |