How to do linear fit to some points in Openfoam?
Hi All
At each calculating time step, I obtain the positions for some particular points in OpenFoam. For example, these points have velocity larger than 100 m/s. Their positions change with run-time. The format of the postions of these points are as follows: point 1 (x1, y1) point 2 (x2, y2) point 3 (x3, y3) point 4 (x4, y4) ..... I need to do a linear fit to all of these points and get the slope of the fitting line. Is there any existing function or library in OpenFOAM I can directly use? Many thanks! |
Anyone knows how to do it? Thanks.
|
|
All times are GMT -4. The time now is 19:06. |