• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 446
  • Last Modified:

VB6 interpolating for a curve

Hi Folks.
Ok -  I have a machine that can trace around a polygram and produce 400 points from it. These points are represented  as a radius for each 1.11 degree round the circle.

I have another machine that requires the information presented as 1000 points or every 0.36 of a degree. Likewise the value will be the radius.

So.. What I need to do is to tkae the original 400 points and expand them out to 1000 points by (insert proces X here)  and generating the values of the missing radius's

Sorry - I don;t know much maths so I am stuck both on what the progress is called when one generates additional points on a existing curve,  and also what the formule is.

Many thanks for any help
Dave

0
marcwolf
Asked:
marcwolf
  • 2
1 Solution
 
Brook BraswellApplication Development ManagerCommented:
Are you asking how to Draw the new points using code or how to output a list of the radii that are missing ?
0
 
byundtCommented:
You might consider using a cubic spline interpolation of the missing points. Here is an Excel workbook that does the cubic spline interpolation using a VBA function. Porting to VB6 should be simple.
Numerical-Methods.xls
0
 
marcwolfAuthor Commented:
Hi Byundt
Many thanks for that. I think I can work it to fit my needs.
If I first create an array of 400 x 2, with the first field being the degree's and the second being the known radius.
Then create a second array of 1000 x 2, with the first field being the degree's and the seond populated with the none points taken from the first array.
Then all I should need to do is to feed in the midding value's degree;'s and I wil have it.

Many many thanks
Dave
0
 
byundtCommented:
Dave,
You shouldn't need to populate the second array with the known points. The interpolation routine ought to return those values to you automatically.

Brad
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now