View Single Post
  #4  
Old 11-12-2018, 10:45 AM
Stonius's Avatar
Stonius (Markus)
Registered User

Stonius is offline
 
Join Date: Mar 2015
Location: Melbourne
Posts: 1,495
Sorry. I was worried that might happen.

Here it is again, unprotected - I was trying to make it so it would be idiot proof. Turns out *I'm the idiot :-D

Essentially, we have three data points given by ZWO in the form of their recommended settings;

ZWO Presets
Gain Offset
0 10
139 21
300 50

In statistics, there is a thing called regression where you try and reduce experimental data to an equation that correlates the x and y axes to each other mathematically. Essentially you are modelling the camera's response so you can determine the intermediate values.

There are various ways of correlating the two axes. The simplest is a linear regression. Punch in a y value and your x value will equal whatever your y value was, multiplied by some other value to determine the steepness of the slope (b) and if an offset is required second value is added to move that slope up or down the graph (a). Essentially, y=bx (or y=a+bx if you want an offset).

I think that's right. Fairly new to all this myself.

So that's the *simplest version* that correlates data that lies on a straight line. But the data here is *not linear, it has a curve. You can see how well the data fits the curve you've used by the 'correlation coefficient' (r). The closer to '1' this is the better your data fits that curve.

There are all sorts of complicated ways of determining curves, but I'm lazy so I just used the data provided by ZWO, graphed it in google docs and played with the curve shape until I found a regression type that had a good fit. You can get google docs to spit out the equation that it used, but it only goes to 2 decimal places, so it isn't really accurate. That's why I used this site which gives *lots of decimal places (in this case, thirteen).

It also (in small type just under the Graph) gives you the equation you need to use to model the data mathematically.

So for me, it looked like quadratic regression gave the best fit. I used the quadratic regression calculator and got the following formula;

y=A+Bx+Cx^2

where;
A=10
B=0.0323458004
C=0.0003366251099

The correlation (r) was 1 (exact fit).

If you plug those values into the equation and give 'y' a value of 0,139 or 300 you will get the exact integers of the gain settings given by ZWO, namely; 10, 21 and 50.

But say you want to use Gain 76. Offset should be 14.4, so you'd probably go with 15 just to be on the safe side.

I don't know how useful it is. As far as I can tell, it will only free up at most about 1% of possible ADU values. Happy to be corrected on that, I could be wrong.

Using the same technique it is possible to model any correlation and determine intermediate values.

Hope that helps people.

Best,

Markus
Attached Files
File Type: zip ASI1600 Offset Calculator.zip (2.1 KB, 95 views)
Reply With Quote