# 🧮 New Math functions

**URL:** <https://community.glideapps.com/t/new-math-functions/16761>\
**Category:** General\
**Created:** [October 5, 2020, 8:12am UTC](https://community.glideapps.com/t/new-math-functions/16761 "2020-10-05T08:12:00Z")\
**Posts on this page:** 1\
**Showing post:** 52

<div class="post-metadata">

**Author:** ![Jeff\_Hager](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/jeff_hager/32/43_2.png) [@Jeff\_Hager](https://community.glideapps.com/u/Jeff_Hager)\
**Post date:** [October 25, 2020, 11:11pm UTC](https://community.glideapps.com/t/new-math-functions/16761/52 "2020-10-25T23:11:29Z")

</div>

@Rasha I think I got it. I feel pretty good about this one. This formula will calculate the time to the next half hour. It does float between 0 and 1 seconds after the minute, but appears to stick on the exact minute of the next half hour and switching to not show seconds will give you a good view. I did watch the time switch from 5:59 to 6:00 and after that, the value changed from 6:00 to 6:30, so I feel pretty good about it.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/2X/f/ff58d73ff4a594c28a1ffe9cadf382d04c6a36b7.png)

The kicker here is that this will require a seed date. This will need to be a column with a date/time. The date and hour can be anything, but the minutes and seconds need to be on the hour, so equal to 0. For example, this is what I have as a seed date/time.  
 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/2X/8/812df64c3a55cae0f6a80715ba5feb02af842a18.png)

This is the complete math formula:

```auto
X+
(
CEILING(((X-Seed)-ROUND(X-Seed))/.0208333)
-
FLOOR(((X-Seed)-ROUND(X-Seed))/.0208333*1000)/1000
)
/48

```

Hope it works for you.

Edit: This may be better and just a hair more accurate. Basically the same either way.

```auto
X+
(
CEILING(((X-Seed)-ROUND(X-Seed))*48)
-
FLOOR(((X-Seed)-ROUND(X-Seed))*48*1000)/1000
)
/48

```

---

_[View the full topic](https://community.glideapps.com/t/new-math-functions/16761)._
