> For the complete documentation index, see [llms.txt](https://applied-physics.gitbook.io/warp-factory/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://applied-physics.gitbook.io/warp-factory/modules/solver-module/verifytensor.md).

# verifyTensor

## Description

Checks the data structure of the metric and stress-energy tensor objects to ensure the required data is provided. See [Object Types](/warp-factory/overview/object-types.md) for specifics on the required struct fields.

## Method

Checks all required fields by object type.

{% hint style="info" %}
This function is used throughout Warp Factory to ensure that data is present. The user can decide to use this to check their own metrics, but errors will be provided automatically in critical functions, such as in the frame transformations or in the solver.
{% endhint %}

## Syntax

`[`<mark style="color:green;">`verified`</mark>`] = verifyTensor(`<mark style="color:blue;">`inputTensor`</mark>`,`` `<mark style="color:orange;">`suppressMsgs`</mark>`)`

### Input Arguments

{% hint style="info" %} <mark style="color:blue;">blue</mark> are required inputs.

<mark style="color:orange;">orange</mark> are optional inputs with native default values.
{% endhint %}

<table><thead><tr><th width="232">Inputs</th><th width="94">Format</th><th width="92">Type</th><th>Description</th></tr></thead><tbody><tr><td><mark style="color:blue;"><code>inputTensor</code></mark> </td><td>struct</td><td>object</td><td>Input tensor object. </td></tr><tr><td><mark style="color:orange;"><code>suppressMsgs</code></mark> </td><td>1x1 array</td><td>integer</td><td>Selects if error messages will be displayed. <strong>The default value is 0, which means true.</strong></td></tr></tbody></table>

### Output Arguments

<table><thead><tr><th width="192">Outputs</th><th width="94.33333333333331">Format</th><th width="96">Type</th><th>Description</th></tr></thead><tbody><tr><td><mark style="color:green;"><code>verified</code></mark></td><td>1x1 array</td><td>logical</td><td>Returns a 1 if the tensor is verified and 0 if not.</td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://applied-physics.gitbook.io/warp-factory/modules/solver-module/verifytensor.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
