06-10-2013 06:12 PM
I will appologize in advance for posting this the LabVIEW "top level" forum. I am sure this is much more of a specific issue, but a more specific board was not apparent to me.
I am trying to use LabVIEW to recreate an algorithm for calculating mutual inductance between two paraxial coils separated by some distance and it requires the use of Complete Elliptic Integrals of the 1st and 2nd kind. Here is a link to the scholarly article: http://www.jpier.org/PIER/pier91/18.09021907.pdf
I instantiated the algorithm in MathCAD and it takes an extremely long time to compute an answer. I thought it might be interesting to see how labVIEW would fare and created a VI that instantiates the same algorithm. Unfortunately, the LabVIEW VI and MathCAD do not agree (off by 50% or more).
When I started debugging my VI, I found that the NI_Gmath.lvlib:Complete Elliptic Integral K.vi does not produce the same values of my MathCAD results for the complete elliptic integrals of the first and second kind. My MathCAD algorithm matches the results observed in the paper, and the values of the elliptic integrals in MathCAD match the several online calculators of elliptic integrals I have found while LabVIEW does not.
Is anyone familiar with this issue?
06-10-2013 06:19 PM
Sorry - here is one Elliptic Integral calculator online which is at least accurate out to the 8th decimal (or argees wityh MathCAD to the 8th decimal).
http://chemandy.com/calculators/elliptical-integrals-of-the-first-kind-calculator.htm
06-11-2013 04:17 PM
Hi DanAllis,
I'm really not very familiar with the Elliptical Integral so we may need some time to research this further. In the mean time, can you provide us with a little more information?
What version of LabVIEW are you running?
What did you use for inputs to the function?
What did you get for results and what did MathCAD and the internet calculators give for results?
Thanks,
06-12-2013 09:16 AM
Sorry - I meant to attach files previously but didn't.
Complete Elliptic Integral Test.vi is a test VI that uses the Elliptic Integral in the same fashion as my specific applicaiton.
Complete Elliptic Integral Test MathCAD.xmcd is a MathCAD file which computes 100 values of each using an Elliptic Modulus value ranging from 0 to 0.99
I am running LabVIEW Professional Development System 2010
The inputs to the function are Double precision values of the elliptic modulus ranging from 0 to (N-1)/N where N = "Integral Count"
I provided a link to an onliune calculator earlier in this thread and the MathCad file provides the MathCAD results. I have also attached a PDF file and an Excel file of the results of the MathCAD integrals in case you do not have MathCAD.
06-12-2013 09:16 AM
Turns out I cannot post the MathCAD native file.
06-12-2013 10:52 AM
If you compare definitions you will see that K(k)_MathCAD = K(k^2)_LV. A common confusion in the definition.
06-12-2013 11:17 AM
Whoops. Bone-head mistake on my part.
Thank you for noticing Darin, or should I say Stig?
Much appreciated.