Category Archives: Arrays

Writing Arrays to the worksheet – VBA function

Previous posts have looked at the VBA code for efficiently writing a VBA array to the spreadsheet as quickly as possible, most recently here. I have now put this code in a function that can be conveniently called from any … Continue reading

Posted in Arrays, Excel, VBA | Tagged , , , , | 17 Comments

VBA code generation on the spreadsheet

A previous post looked at using VBA to generate more VBA code.  This post looks at automatic code generation on the spreadsheet, which may be transferred into the a VBA project using the techniques discussed in the earlier post, or simply … Continue reading

Posted in Arrays, Excel, Finite Element Analysis, Newton, UDFs, VBA | Tagged , , , , , | Leave a comment

Retrieving unique values from a range or array …

… using the Scripting Dictionary object. in a previous post I looked at using the dictionary object to count connected elements in a finite element model.  This post looks at a more general (and simpler) usage to return unique values from … Continue reading

Posted in Arrays, Excel, UDFs, VBA | Tagged , , , , | 20 Comments

Comparing floating point numbers

Some of the issues raised in this post: https://newtonexcelbach.wordpress.com/2011/12/20/when-does-35-not-equal-35/ arose when writing the functions for the previous post on combining arrays.  In particular, when values from the two arrays are “equal” the function should create one entry in the combined … Continue reading

Posted in Arrays, Excel, UDFs, VBA | Tagged , , , , , | 4 Comments

Combining arrays

Part of the Macaulay spreasheet presented in recent posts required the formation of a list of points along a beam where the functions needed to be evaluated.  These are: The support points, the changes of cross section, and the output … Continue reading

Posted in Arrays, Excel, UDFs, VBA | Tagged , , , | 7 Comments