We introduced you to Tyler Anderson a month ago. This Aggie math major finished his summer internship on our Product Development team last week and we wanted to share with you what he accomplished.
Updating Glyph Scripts
One of Tyler’s first tasks this summer was to update several scripts on the Glyph Script Exchange on Github, primarily to allow those scripts to operate on entities selected prior to script execution (versus requiring selecting within the script). For example, the butterfly topology script shown below (converts a structured grid with an H-topology into a so-called butterfly topology) was updated so the block can be selected first.
This script is one of seven on the Glyph Script Exchange that Tyler updated (ButterflyMaker, ConGeometricAutoDimension, CreatOH, Domain2Ellipse, ExtrudeEdges, QuadWarp and TurningAngleCalculator). If these are your favorites you might want to download new versions soon.
Glyph Tk Interface to Growth Profiles
Tyler also contributed to a new feature coming in V18.1 R2 called Growth Profiles, a set of Glyph commands that will create meshing attributes for the T-Rex technique based on laminar or turbulent flow parameters or based on your best practices. (In other words, Growth Profiles is like a macro command that sets your wall spacing, growth rate, and growth rate acceleration.)
Tyler’s work involved building a Tk interface to the new Growth Profiles commands in Glyph. This UI will make use of Growth Profiles a little easier, especially for those folks who prefer not to program directly in Glyph. You’ll eventually find this script on the Glyph Script Exchange.
You may recall that we introduced the Glyph Server capability in December 2016 so that Glyph scripts (which are based on Tcl) can be called from virtually any scripting language including Python.
Tyler has been working on an update to the Glyph client that provides the Python interface. The updated version generates the Glyph functions “on the fly” rather than working from a preset dictionary of commands.
This updated Python client is a work in progress. We plan to share it on the Glyph Script Exchange shortly after the release of Pointwise V18.2 R1.
Approximating Pi with Needles
Tyler could not resist the temptation to teach us engineers something about mathematics so he implemented Buffon’s Needle Experiment in Pointwise with a Glyph script written in Python. This experiment involves randomly dropping needles of length l onto a sheet with stripes of width t.
It turns out that a good approximation of pi can be computed as (2l)/(tP) where P is the ratio of the number of pins crossing a stripe to the total number of pins dropped.
Tyler left us with this bit of math trivia: 355/113 is the best approximation of pi where the numerator and demoninator have less than 5 digits.
Another Successful Summer
Tyler’s senior year at Texas A&M begins soon and he’ll be graduating in May with a B.S. in Applied Mathematics. He plans to pursue graduate study in math after that.
Let’s end with Tyler’s own words.
“My internship at Pointwise was phenomenal. I was given challenging projects and I was surrounded by people who were passionate about helping me grow and sharing their knowledge with me.”
Pingback: This Week in CFD | Another Fine Mesh