# Cup-mixing temperature (Average temperature over volume and velocity)

**URL:** https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897
**Category:** ParaView Support
**Created:** [July 20, 2020, 8:02am UTC](https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897 "2020-07-20T08:02:12Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Woutercc](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/w/3bc359/32.png) [@Woutercc](https://discourse.paraview.org/u/Woutercc)
#### Post date: [July 20, 2020, 8:02am UTC](https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897/1 "2020-07-20T08:02:12Z")

</div>

Dear Topicmembers,

I am working on a flow problem where I like to collect the Cup-mixing temperature of a slice and a clip.  
This cup-mixing temperature is the average temperature of a slice or clip over the volume of the particles and velocity as can be seen in this formula:

![image](https://discourse.paraview.org/uploads/default/original/2X/b/b669774fe5477e8e2f9f8a50806e03eb92bf186e.png)

where U\_x is the the magnitude of the velocity, V is the volume of the element and T the Temperature.

How can I collect this from paraview for a slide and clip ?

Wouter

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [July 20, 2020, 8:09am UTC](https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897/2 "2020-07-20T08:09:02Z")

</div>

Does your dataset contains the velocity, the volume et and temperature ?

---

<div class="post-metadata">

### Author: ![Woutercc](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/w/3bc359/32.png) [@Woutercc](https://discourse.paraview.org/u/Woutercc)
#### Post date: [July 20, 2020, 8:17am UTC](https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897/3 "2020-07-20T08:17:30Z")

</div>

Yes my database contains the velicity and temperature and It is build out of mesh were I know the position of the nodes. Ik is a database formed by OpenFOAM.

---

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [July 20, 2020, 8:31am UTC](https://discourse.paraview.org/t/cup-mixing-temperature-average-temperature-over-volume-and-velocity/4897/4 "2020-07-20T08:31:10Z")

</div>

Then you should give it a go using the programmable filter to implement the computation in Python.

You may need to use MeshQuality to compute the volume of the cells first.
