# Initial condition

*Specifies the initial state for the solid heat equation solver.*

---

## Available Options

| *Option*      | *Description*                                              |
|---------------|-----------------------------------------------------------|
| **Constants** | Key-value pairs for reusable expressions/constants. |
| **Temperature** | Initial temperature value or expression.  |

```{seealso}
For the C-style expression syntax used in initial-condition fields, see the {doc}`/user_guide/UnitsAndExpressions/ExpressionsLegacy` user guide.
```

---

## Detailed Descriptions

### Constants

*Optional dictionary of key-value pairs to define constants or reusable expressions for the initial condition.*

- **Default:** None  
> **Notes:**
> - Keys are used as variables in expressions (e.g., `T0`).
> - Values are string expressions or numbers.
> - Useful for parameterizing initial conditions.

### Temperature

*Specifies the initial temperature throughout the solid domain. Can be a constant or an expression.*

- **Required**
- **Example:** `300` or `T0`  
> **Notes:**
> - If an expression is used, it may reference constants defined above.
> - The value is always non-dimensional and carries no units: it is the temperature divided by the freestream temperature $T_\infty$.

---

<details>
<summary><h3 style="display:inline-block"> 🐍 Python Example Usage</h3></summary>

```{seealso}
Python API reference: {py:class}`~flow360.HeatEquationInitialCondition`.
```

Below is a Python code example showing how to define an initial condition for the solid heat equation:

```python
# Example (for reference only, not included in GUI documentation)
initial_condition = fl.HeatEquationInitialCondition(
    temperature="300"
)
# With constants:
initial_condition = fl.HeatEquationInitialCondition(
    constants={"T0": "300"},
    temperature="T0"
)
```

</details>
