Hello,
I would really appreciate if someone could help me with the example attached.
Column A lists potential regions to import from, and column B lists distances from those regions to my location (Trondheim). Column C lists the quantity produced in those regions, and in Column D I have a target of x kilos that I wish to import. In column E I have a CO2-factor that converges km*kg to kgCO2 produced. I want to import from the regions closest to me (shortest distance), and combined, the quantity from those regions should match my target of x kilos.
To do this I need a formula that 1) sorts out the lowest values in column B, 2) sums up the values of the adjacent cells (quantity) until target value for quantity is reached, and finally, 3) all cells in column B that gets counted should be multiplied with their adjacent cells and then multiplied with the CO2-factor, before they are all summed together (distance x kg x CO2-factor).
The purpose is to find the lowest number for CO2-emissions.
Thank you in advance,
Bjorn
Bookmarks