Hey guys, somewhat of a noob at vba and need a little help with a small problem...
I have a series of points with x and y co-ordinates and I need to find the distance between all of the points and each other. The number of points will change and this needs to be taken into account in the vba code. I tried using an next statement with a loop, but really struggling. Also it is subject to the following formula:
gh = C0 + C * [1.5(h/a)-0.5*(h/a)^3] for h<a..
gh = C0 + C h>a
gh = o h = 0
Where gh "gamma h" is what i ultimately need to work out, after working out h, Co and C are values given, h is the distance between the points, which will need to be put in the formula and a is a given number (a distance). So a simple if statement could suffice for these equations depending on what the distance between points are...
I have entered some values into the spreadsheet to show what i am talking about, you can find the excel spreadsheet attached. I am sure it is quite simple but I cant get my head around it...I need all the gh values to be entered into a matrix kind of form, this can be seen in the attachment..
Any help at all would be greatly appreciated.
Thank you![]()
Bookmarks