Mazdaspeed Forums

Mazdaspeed Forums (http://www.mazdaspeedforum.org/forum/forum/)
-   MSF KB - Mazdaspeed 3/6 - ECU Computer Tuning (http://www.mazdaspeedforum.org/forum/forum/f628/)
-   -   Using Excel to dial in your maf curve (meth users, perfectionists, etc.) (http://www.mazdaspeedforum.org/forum/forum/f628/using-excel-dial-your-maf-curve-meth-138129/)

rfinkle2 02-08-2013 08:26 AM

Using Excel to dial in your maf curve (meth users, perfectionists, etc.)
 
If you guys want to use excel to create a smooth, predictable maf curve and want excel to do the work for you, below has proven to work well for me.

Please see notes @ bottom of post to help in manipulating the data vertically and horizontally. (atr will only transfer and accept pasted values if orientation is correct)

You can see the below maf curve combined with meth injection needed work.
http://i1206.photobucket.com/albums/...2/writeup2.png

1) Start by identifying the open loop portion of the log you want to correct by calculated load (example car is set to use 1.25 load to transition to open loop)
http://i1206.photobucket.com/albums/...2/writeup1.png

2) create your corrective multiplier by dividing actual exhaust readings in the log over the commanded afr you are targeting (as seen on pg. 49 of 86 in the atr helpfile) ... (logged afr / desired afr) = multiplier

3) Multiply logged maf g/s by multiplier found in # 2 (note screenshot does not show logged maf values that were multiplied against the corrective multiplier to get corrected maf g/s)
http://i1206.photobucket.com/albums/...2/writeup3.png


4) Chart maf v against resulting corrected maf values in # 3
-to chart the data use the insert tab, choose scatter chart, choose the top left option (aka scatter with only markers)

5) Click on the resulting charted data and choose "add trendline" > power > display equation on chart
http://i1206.photobucket.com/albums/...2/writeup8.png

6) The excel function (black line of best fit) now becomes what is used to create your maf curve where; x = maf voltage
http://i1206.photobucket.com/albums/...2/writeup4.png

7) Copy the maf voltage portion of the curve from ATR to give you the complete set of values the ecu uses (see pasting options in notes)

8) plug and chug to find resulting maf cuve based on function given from line of best fit
http://i1206.photobucket.com/albums/...2/writeup6.png

9) use the paste special>values> transpose function to get a horizontal, pastable maf curve and paste into appropriate maf g/s per voltage placement.
http://i1206.photobucket.com/albums/...2/writeup5.png


Notes:
-In order to paste the maf voltage line from atr, you will have to use the paste special>unicode text function
http://i1206.photobucket.com/albums/.../writeup0b.png
-In order for you to have pastable horizontal data (to insert resulting maf curve back into atr), you will have to use the "paste special > values > transpose option on occasion
-You will also have to use the above function to transfer the maf voltage values vertically onto your spreadsheet
http://i1206.photobucket.com/albums/...2/writeup0.png

Rich990 02-08-2013 08:31 AM

Thanks Rob!

Lex 02-08-2013 08:52 AM

Nice curve fitting Rob.

Just be aware that on gen2 cars the WOT trims will make your car reach AFR targets unless you're off by more than 10-12%.

For safety reasons I would not scale my MAF for meth especially on a gen2 and let the ECU take care of it. If you're off by more than 10-12% then that's a lot of meth.

I assume this was from a gen1 car?

rfinkle2 02-08-2013 08:55 AM

Quote:

Originally Posted by Lex (Post 1883306)
Nice curve fitting Rob.

Just be aware that on gen2 cars the WOT trims will make your car reach AFR targets unless you're off by more than 10-12%.

For safety reasons I would not scale my MAF for meth especially on a gen2 and let the ECU take care of it. If you're off by more than 10-12% then that's a lot of meth.

I assume this was from a gen1 car?

Thanks Lex. I understand what you mean about the ability of the ecu to trim fuel in open loop.

I've used it on both generation cars with great results.

The multiplier that I'm using is still based on the ol' long division to correct the curve, I'm then allowing excel to fit the curve based on those corrected g/s values rather than plugging each individual cell manually, or multiplying small groups of cells manually.

@Lex; ... # 3 in the OP is a better way to explain.

86AmishMs3 02-08-2013 09:38 AM

Good stuff...tis what I do too

superskaterxes 02-08-2013 09:46 AM

Quote:

Originally Posted by Lex (Post 1883306)
Nice curve fitting Rob.

Just be aware that on gen2 cars the WOT trims will make your car reach AFR targets unless you're off by more than 10-12%.

For safety reasons I would not scale my MAF for meth especially on a gen2 and let the ECU take care of it. If you're off by more than 10-12% then that's a lot of meth.

I assume this was from a gen1 car?

when is cobb going to release these tables for us?

rfinkle2 02-08-2013 09:49 AM

Quote:

Originally Posted by superskaterxes (Post 1883412)
when is cobb going to release these tables for us?

Good question. I know DJ asked David about the maximum amounts of trim allowed and those tables to be exposed, but I haven't heard anything else about it.

Cataphract_40 02-08-2013 10:01 AM

What was your R squared value for that curve?

rfinkle2 02-08-2013 10:04 AM

Quote:

Originally Posted by Cataphract_40 (Post 1883443)
What was your R squared value for that curve?


Always in the 95% + region.

Very high.

Lex 02-08-2013 10:27 AM

Quote:

Originally Posted by superskaterxes (Post 1883412)
when is cobb going to release these tables for us?

Not sure if there is much in terms of development at this time. They have their hands full with the ST etc. I will inquire next time I speak with David.

ms3blackmica 02-08-2013 10:30 AM

Rob sent this idea over to me and I attest to it working VERY nicely.

Funny thing is, I was using my TI-83 for shit like this LOL


Edit: Rob should be thanked x100000000000000

TiGraySpeed6 02-08-2013 12:21 PM

Excel tricks are always cool, Thanks Rob!
Excellent job covering the steps to a process that would normally be beyond the average persons experience level with excel!

For those on newer versions, excel has an option for transposing with the other options in the right click > paste menu, along with format pasting etc...

atvfreek 02-08-2013 06:42 PM

Quote:

Originally Posted by rfinkle2 (Post 1883244)
If you guys want to use excel to create a smooth, predictable maf curve and want excel to do the work for you, below has proven to work well for me.

Please see notes @ bottom of post to help in manipulating the data vertically and horizontally. (atr will only transfer and accept pasted values if orientation is correct)

You can see the below maf curve combined with meth injection needed work.
http://i1206.photobucket.com/albums/...2/writeup2.png

1) Start by identifying the open loop portion of the log you want to correct by calculated load (example car is set to use 1.25 load to transition to open loop)
http://i1206.photobucket.com/albums/...2/writeup1.png

2) create your corrective multiplier by dividing actual exhaust readings in the log over the commanded afr you are targeting (as seen on pg. 49 of 86 in the atr helpfile) ... (logged afr / desired afr) = multiplier

3) Multiply logged maf g/s by multiplier found in # 2
http://i1206.photobucket.com/albums/...2/writeup3.png


4) Chart maf v against resulting corrected maf values in # 3
-to chart the data use the insert tab, choose scatter chart, choose the top left option (aka scatter with only markers)

5) Click on the resulting charted data and choose "add trendline" > power > display equation on chart
http://i1206.photobucket.com/albums/...2/writeup8.png

6) The excel function (black line of best fit) now becomes what is used to create your maf curve where; x = maf voltage
http://i1206.photobucket.com/albums/...2/writeup4.png

7) Copy the maf voltage portion of the curve from ATR to give you the complete set of values the ecu uses (see pasting options in notes)

8) plug and chug to find resulting maf cuve based on function given from line of best fit
http://i1206.photobucket.com/albums/...2/writeup6.png

9) use the paste special>values> transpose function to get a horizontal, pastable maf curve and paste into appropriate maf g/s per voltage placement.
http://i1206.photobucket.com/albums/...2/writeup5.png


Notes:
-In order to paste the maf voltage line from atr, you will have to use the paste special>unicode text function
http://i1206.photobucket.com/albums/.../writeup0b.png
-In order for you to have pastable horizontal data (to insert resulting maf curve back into atr), you will have to use the "paste special > values > transpose option on occasion
-You will also have to use the above function to transfer the maf voltage values vertically onto your spreadsheet
http://i1206.photobucket.com/albums/...2/writeup0.png

Good shit Rob! I like it.

rfinkle2 02-08-2013 06:52 PM

Starting to get vd logs that look this way very consistently now after running each revision through the same process. (targeting 11.83 @ this point in rpm band)

http://i1206.photobucket.com/albums/...target1183.png

ms3blackmica 02-08-2013 08:12 PM

Holy hell Rob good shit

I, in fact, am not the mad scientist..

rfinkle2 02-08-2013 08:18 PM

Quote:

Originally Posted by ms3blackmica (Post 1884598)
Holy hell Rob good shit

I, in fact, am not the mad scientist..

Your brain power eclipses mine Nishan. I just like to use excel and was tired of trying to blend maf curves.

TiGraySpeed6 02-08-2013 09:22 PM

So I'm walking one of my own logs through this, and can do everything up to, and everything after, but step 8 has me stuck on the plug & chug bit.

Are you copying both MAF volts and g/s in step 7? Or are you working against the logged g/s?

in step 8 you've got both the y value as the base. and the x as the raise to.
What's the formula being applied?

And the newly created g/s values, are you working that math against the entire open loop area, all the way to the end?

Volcom8190 02-08-2013 09:32 PM

never thought to do this, another reason to keep excel on the logging computer i guess.

ms3blackmica 02-08-2013 09:33 PM

Quote:

Originally Posted by rfinkle2 (Post 1884610)
Your brain power eclipses mine Nishan. I just like to use excel and was tired of trying to blend maf curves.

There is a sin function called a cardiod represented as R = a(1+/- sinΘ) and when plotted resembles a heart.

There ya go Rob.

A nerd's internet heart. Yup, I went there.


http://i1060.photobucket.com/albums/...psd739af40.png

Cataphract_40 02-09-2013 04:47 AM

Quote:

Originally Posted by rfinkle2 (Post 1883449)
Always in the 95% + region.

Very high.

Very nice, looked like a good fit from just eyeballing it.

Quote:

Originally Posted by ms3blackmica (Post 1884741)
There is a sin function called a cardiod represented as R = a(1+/- sinΘ) and when plotted resembles a heart.

There ya go Rob.

A nerd's internet heart. Yup, I went there.


http://i1060.photobucket.com/albums/...psd739af40.png

Partial to the Batman curve myself... :D

http://4.bp.blogspot.com/-7Tzvy8HaTw...atmanCurve.JPG

Batman Curve -- from Wolfram MathWorld

rfinkle2 02-09-2013 05:30 AM

Quote:

Originally Posted by TiGraySpeed6 (Post 1884730)
So I'm walking one of my own logs through this, and can do everything up to, and everything after, but step 8 has me stuck on the plug & chug bit.

Are you copying both MAF volts and g/s in step 7? Or are you working against the logged g/s?

Only copy the maf voltages that are close to those you chose from the log based on your closed loop max load value. In the log, that value was 2.68, but that was not an available point when I copied the maf voltages from atr, so I chose to start @ 2.66 which was a voltage value from ATR) . Continue from open the loop value you choose to the end (5v).

in step 8 you've got both the y value as the base. and the x as the raise to.
What's the formula being applied?

The formula is given from the fitted curve by excel. In the example,

y=4.0831x^3.0713

Gramspersecondyoucopyandpasteasnewcurve = 4.0831 * voltagecopied from ATR ^3.0713


And the newly created g/s values, are you working that math against the entire open loop area, all the way to the end?

I should have explained it better now that I think about it.

-The log that you have has the voltage the ecu used, your logged afr and the g/s the ecu used to create the a/f ratio.

-Use the corrective multiplier against the logged maf g/s values and chart that number against logged maf voltage.

The above 2 steps give you the data excel fits a curve onto.

-once excel spits out the equation, use only the voltage values from atr as "x" in the equation, and the resulting maf g/s values are the "y" value.


It is hard to explain this crap in text.

rfinkle2 02-09-2013 05:40 AM

@TiGraySpeed6; I see you @ the bottom of the screen. LOL.

Choose an open loop maf voltage value seen in atr and use the formula to get your maf g/s values all the way through to 5v.

TiGraySpeed6 02-09-2013 04:00 PM

3 Attachment(s)
All righty then, for the sheet below, the money shot is =J2*I2^K2


On a map targeting 11.8, the log resulted in the following log data-

http://www.mazdaspeedforum.org/forum/foru...1&d=1360450671



So, from that log, the following graph was created

http://www.mazdaspeedforum.org/forum/foru...1&d=1360450671



And using the data from that graph, and the formula =J2*I2^K2 resulted in the curve as shown. Pretty darn nifty.


http://www.mazdaspeedforum.org/forum/foru...1&d=1360450671

ms3blackmica 02-09-2013 04:15 PM

This shit is becoming awesome

TiGraySpeed6 02-09-2013 04:22 PM

1 Attachment(s)
Amazing part is that the changes actually correct up and down from the original values as needed.

pretty freaking spiffy.



http://www.mazdaspeedforum.org/forum/foru...1&d=1360452146

tbot 02-09-2013 04:35 PM

I think I'm too tired atm to understand this completely haha. Realized when I tried to scroll TiGray's MAF Table A not realizing it was a picutre...get the jist of it tho!

TiGraySpeed6 02-09-2013 09:29 PM

Does seem to smooth things out pretty easily!
I've set a template with the formulas already in place, just have to populate with data, get the correction chart and populate that data, then past the results in ATR.

From the first AFR's I posted above, it's leveled out to look like this on just the second revision (don't mind the power numbers, this map isn't pushing for big numbers):


http://stable-networks.com/ms6r/imag...4b-353-343.jpg

ms3blackmica 02-10-2013 01:29 AM

I love it.

GODspeed7 02-10-2013 01:37 AM

Is it bad that this shit is so complex that I am just skimming the thread looking for more batman pictures and heart pictures made with graphs? Lol


Tapatalk LIKE A BOSS!

TiGraySpeed6 02-10-2013 06:32 AM

It's really not tho :)

You do the same core work to get the corrected g/s numbers to start from, using the same ol' math - [Logged Actual AFR]/[Target WOT AFR] = g/s multiplier. That gets you the corrected MAF g/s points as always.

Then you plug those corrections into the Finklechart (tm) and the magic math is given back to you on a silver platter.

Then you just run the finklechart math against your MAF Voltage points and presto- updated, corrected, curved & smoothed MAF g/s numbers are provided to paste directly into your MAF tables.

It's always sucked trying to match the logged values to the actual ATR MAF Volt values, and often it's done by addressing a cell or two at a time. Finkle's Excel method does the entire OL curve at once, pinpointing the exact MAF Volt numbers.

Even better, it get's progressively better with each revision- Mine went from spazzy to smooth in two, and will, I suspect, be dead flat by 4 revisions.


It's actually both easier and faster.


And, yes, that is indeed very cool :bigok:





.

Rich990 02-10-2013 07:01 AM

This should be a sticky!

@TiGraySpeed6, it would be good if you could post up the FinkleChart workbook, maybe in the VIP section.

MSF FTMFW

TiGraySpeed6 02-10-2013 07:31 AM

the graphic I posted of the spreadsheet above pretty much covers it, and indicates the excel formula that works the final curve, at least as the columns are in that one.

I'm loath to just put up an actual template simply because I think it's important to walk through the steps exactly as Rob laid them out in the first post and understand what goes where and why.

I don't want to sound like an asshole, but honestly, this process, like any powerful tool, could just as quickly fuck up your curve if you don't use it properly. It's better to go through the process and learn each step, know what it does and why, and how it impacts the next step as you progress.

It shouldn't be just paste the input, then copy the output.

Mfinlay04 02-10-2013 07:38 AM

Gonna give this a go the next time I have a day off... My LTFT are pretty dialed in but I'm sure they could be tweaked even more

Sent from my Galaxy Nexus using Tapatalk 2

TiGraySpeed6 02-10-2013 10:21 AM

3rd revision looks like this- Tad of KR at 5700, or it would have been glass.

Damn glad it's not an EKG...... :)


http://stable-networks.com/ms6r/imag...m/flatline.jpg

CosmicArkie 02-10-2013 11:58 AM

1 Attachment(s)
Given that I'm to damned old to figger the whole Excel thing out,
I did it the old fashioned way. Always wondered why a lot of the
VD plots were like the Rocky Mountains, though.

TiGraySpeed6 02-10-2013 12:04 PM

That's a nice AFR plot there Cosmic, and a nice K04 VD all around

GODspeed7 02-10-2013 01:24 PM

@rfinkle2; I can haz flat line AFR's??? You know when my car is not being a temperamental bitch... Lol!


Tapatalk LIKE A BOSS!

rfinkle2 02-10-2013 01:26 PM

Quote:

Originally Posted by GODspeed7 (Post 1886853)
@rfinkle2; I can haz flat line AFR's??? You know when my car is not being a temperamental bitch... Lol!


Tapatalk LIKE A BOSS!

I used this process on your last revision, and as the map progresses, it should get gradually more accurate.

ms3blackmica 02-10-2013 01:26 PM

Quote:

Originally Posted by GODspeed7 (Post 1886853)
@rfinkle2; I can haz flat line AFR's??? You know when my car is not being a temperamental bitch... Lol!


Tapatalk LIKE A BOSS!

Just email him teh good stuffz :D

GODspeed7 02-10-2013 01:29 PM

Quote:

Originally Posted by ms3blackmica (Post 1886856)
Just email him teh good stuffz :D

Lol oh I have been. My car has been a dirty whore lately so we have been swapping maps for the last 48 hours. I was just busting his balls. Those AFR's are sick though!


Tapatalk LIKE A BOSS!


All times are GMT -7. The time now is 09:05 PM.

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
vB.Sponsors

©Copyright 2008 ; 2019 Cymru Internet Services LLC | FYHN™ Autosports HQ
Ad Management plugin by RedTyger

Page generated in 0.22100 seconds with 11 queries