Metadata and Source Information

When you create Mathcad worksheets that you plan to reuse or pass on to colleagues, you may also wish to capture information associated with your work. Mathcad allows you to record metadata at either the worksheet or equation level.

Worksheet Metadata

When you save your worksheet, Mathcad includes metadata in the file that briefly describes the worksheet. Some of this information is automatically generated by Mathcad or obtained from the operating system; other information, such as a brief description and relevant keywords, are provided by you. This information, displayed in the File Properties dialog, allows you to track the worksheet as it makes its way through your organization.

To add worksheet metadata, open the File Properties dialog by clicking Properties on the File menu. You can add the following metadata on the Summary tab.

Summary Tab

The Summary tab allows you to access - and in some cases control - a standardized set of file metadata useful for archiving worksheets in a document storage and control system. By saving worksheets in one of Mathcad's XML-based formats (XMCD and XMCDZ-compressed XML), you can use XML-friendly tools to search and report on worksheets without opening them in Mathcad.

You can edit five of the metadata fields on the Summary tab:

In addition, this tab displays uneditable metadata of two types:

Custom Tab

The Custom tab allows you to enter non-standardized metadata for your worksheets. For example, you may want to associate a worksheet with a particular project, or note whether or not it has been approved for general usage. You can select the name of the metadata from a drop-down list (or enter your own), specify the type of information the metadata will contain (text, date, general number, or yes/no), and then enter the specific value. All custom metadata associated with the file is displayed in the table at the bottom of the dialog.

Region Metadata

In addition to attaching metadata to a file, you can provide it at the math expression or math subexpression level. Mathcad allows you to annotate the source of variables or formulas, note methodologies used when defining your calculations, and add other comments.

Region metadata can be added and viewed through one of two mechanisms:

  1. Select all or part of a math expression, right-click on the selected terms, and choose Annotate Selection. In the resulting dialog, you can note information about the selection. Mathcad applies the metadata only to what you selected; you can annotate anything from a particular number or variable to the entire expression, and each region can contain multiple annotations.

    When annotating a subexpression, such as 1/2·b·h, in this manner, not all of the selectable combinations can be annotated. If Annotate Selection is unavailable, use parentheses to group the subexpression, such as 1/2·(b·h), and then annotate the selection.

  2. The Custom tab of the Properties dialog. Here, you can apply the same type of metadata as on the same tab of the File Properties dialog. This type of metadata is applied to the entire region, regardless of the portion you select.

Copying and Pasting Metadata - Provenance

When you tag a region with metadata, then copy and paste the region, Mathcad copies and pastes the associated metadata. When you copy and paste math regions or subexpressions from one worksheet into another, Mathcad automatically creates metadata about the originating file. File-tracing metadata of this kind is called provenance, and is found on the Provenance tab of the Annotation dialog.

Right-click on the annotated portion of the copied expression and choose View > Edit Annotation; notice the dialog now has a new Provenance tab. This tab displays the worksheet from which the region or expression was copied, the worksheet in which the region originated, and the revision number of each at the time a copy was made. The Provenance tab also displays the worksheet-level comment of the originating worksheet. If you edit the expression, the annotations disappear, as the expression is no longer the original traceable version.

If you copy and paste multiple expressions to a new worksheet, they each carry provenance annotations, just as if you had copied them one at a time.

Notes:

Metadata and Provenance