Integration Visualizer

A work-in-progress HDA designed to represent integrals, provide a solution, and highlight the area the integral is calculated with.

The tool uses Scipy’s Integration sub-package and Houdini’s Geometry Python class to prepare the input text, solve the equation, and then manipulate the geometry.

Currently, this system works for single integrals. Going forward I would like to incorporate tools for double and triple integrations, and a cleaner HDA packaging.

Most of the work was done in the Python node ‘integration_and_position’.

The ‘range_and_function’ Detail Wrangle sets up detail attributes for Python to read and write to.

The first step is done with the typedMath dictionary and the stringToMath function, where the function inputted in the detail wrangle is converted to a readable Python code.

Next, the Detail Attributes are made into variables, and the converted function string is made into a lamda function.

After this, the integration is done with the lamda function and limit variables.

Finally, the points are spread out along the range determined by the limits and positioned according to the input function. The integration is also written to a detail attribute so it can be read later by the Font node.