Until now the focus of Word+Equate has been based around the Equation Designer. Tables in Word can also be used for calculations.

Creating a Word-Equate Table

A Word-Equate table is a normal Word table with particular text in the “Alt Text” property. The Alt Text property is accessed by accessing the right-click menu and selecting “Table Properties”.

The first part of the text, before the colon, is the table name. It can be thought of as the variable name for the table. You can edit this table name to any legal variable name.

To simplest way to convert an existing table to a Word-Equate table is to use the Convert Table option in the Tables on the Calculations tab.

The table is assumed to have row and column headers. If your table doesn’t have them you need to create a blank header row or column. Values in the header row or column are used as indexes when accessing data in the table.

Assessing Table Data

Consider the following table. Its name is Demo1.

Data in the table can be extracted into arrays. “Demo1” is the name of the table. “Row3” is the title of the row, so data from this row is fetched. Square brackets “[]” are used to indicate Row3 represents a value in the header column.

Data can also be fetched from a column.

Using a column and row reference, a single value can be fetched.

Operations can then be performed on the fetched data.

Alternatively data can be referenced by index. Columns use sequential letters and rows use sequential numbers, like Excel. Index references are enclosed in braces “{}”.


Table Interpolation

It is frequently necessary to interpolate data within a table to be used in a calculation. The row and column header data specify particular values for the data in the table. Often the required value relates to a point between the header values and linear interpolation is typically used. Word+Equate automatically interpolates within a table provided header values are monotonically increasing or decreasing numeric values.

In the table Demo2, the column headers are increasing numeric values.

By specifying a column value between these values, the value is linearly interpolated along the nominated row.


Table values can contain quantities with units

Quantities fetched from a table operate like and other quantity.

The table WBData contains properties associated with a number of steel sections. In this table the units are defined in parentheses “()” in the column header. A unit specified in the column header applies to all values in that column.

The area of section “800WB168” is fetched with the following equation.

The weight is fetched and converted to the current default unit.

All data for a section can be fetched with the following equation.

The fetched data is stored in an array of quantities. Each item has an index derived from the column header. Individual values can then fetched by name.

This then allows concise calculations to be specified.

Column Operations

It is possible to define a table column to have values based on data in other columns. For example, one column can be defined as an expression of other column values.

Column C is defined to be the sum of columns A and B. If values in columns A or B are altered, the values in column C are automatically updated.

Unlike Excel, the basis of values in column C is clearly visible. The calculation in the header applies to all rows and can be easily verified. In Excel, the equation is defined, but hidden in the visible output, separately in each cell. The basis of calculations are not visible on printed out, and even with access to the spreadsheet it is time consuming to check every cell.

Column D is defined using the in-built “Accum” function that tallies previous values in the array defined as column A.

The following table, T5, shows the use of quantities in table calculations. Columns Col1 and Col2 have units defined in the column headers. The equation defining Col3 is in the header. The values in column Col3 have units. Since no unit is specified in the header of column Col3, the units appear in the individual values. In column Col4, the unit is specified in the column header, so does not appear in the data. Note that in Col4 the units are in additional parentheses.

This behaviour appears normal to anyone reviewing the table.

The data contained in columns Col3 and Col4 is identical but displayed differently.

Defining Column Operations

Defining the column operation within the table header works well for small equations but when the complexity of the equation grows it can subtract from the presentation and become harder to understand what is going on. Therefore Word Equate allows for the user to define a column operation outside of the table.

Column operations are defined outside the table using the equation designer just as any other equation would be. The variable name given to the equation must match the name of the desired column header. The operation is then applied to the column by appending a colon after the column header name as shown below.

The variables “Area” and “Capacity”, are defined as a simple text strings, as the equations can be evaluated at that time. When the table is evaluated, the variables can be evaluated (from other column tables), allowing the equation result to be evaluated.

Displaying Data in a table format

When displaying data as an array it can become very unclear what each value is referring to. By using tables, however, the user can provide a better way of displaying information. In Word Equate this is achieved by defining the table as an output by including an equal symbol in the top left cell. Naming a row in that table with the same name as a previously defined array will display its values in the table:

In the above example Vsit is an array of wind velocities in a particular direction. When the data is displayed as an array it can be unclear what each value is referring to.

The same data displayed in a user customised table format provides a more clear and informative way to display the information.

Advanced Table Lookups

There is the functionality within Word Equate which allows the user to retrieve table data based on a Boolean operation or wild card search applied to each value within a row/column. The following examples are based on the table displayed below.


Boolean Table lookups

Boolean checks can be made on values in either a column or a row, when the result of the boolean operation is true the index is stored allowing the user to extract a subset of values in the same or corresponding column/row. For numbers and quantities you can perform equal, not equal, greater and less than comparisons. For text comparison only equal and not equal Boolean operations are valid.

The syntax for an advanced table lookup is:

·         Column - TableName[‘Column/s to extract data from’, ‘Column to apply operation to’ ‘boolean operator’ ‘Comparison value’]. 

·         Row - TableName[‘row to apply operation to’ ‘boolean operator’ ‘comparison value’, ‘row/s to extract data from’].

Note: To extract data from multiple columns/rows the semi colon character ‘;’ is used between each column/row name respectively.


Retrieve all the row values in Col1 where the row values in col2 are greater then 3:

Retrieve all the row values in Col1 where the row values in col2 are equal to 2:

Return the row value in Col1 and Col2 when Col4 is max:

Return the column value in Row1 when the value in Row2 is greater or equal to 2.

Wild Card Lookups

Wild cards allow the user to retrieve information based on a text comparison of table data. This can be triggered by using a "wavy equals" symbol (shortcut: ‘\approx’ in the equation designer) in place of a Boolean operation as described above. With a wild card search certain characters can be included before or after the input text to change how the text is compared:

?’ - will match zero or one characters

*’ - will match zero or more characters

+’ - will match one or more characters

Examples: Matching letters

Examples: Match Numbers