# I hate math

**URL:** <https://forum.kirupa.com/t/i-hate-math/224839>\
**Category:** Uncategorized\
**Created:** [May 6, 2007, 3:44am UTC](https://forum.kirupa.com/t/i-hate-math/224839 "2007-05-06T03:44:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![lorren\_biffin](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/lorren_biffin/32/2726_2.png) [@lorren\_biffin](https://forum.kirupa.com/u/lorren_biffin)\
**Post date:** [May 6, 2007, 3:44am UTC](https://forum.kirupa.com/t/i-hate-math/224839/1 "2007-05-06T03:44:41Z")

</div>

Well, not really…I’ve just never been good at it.

I’m working with this class to spit out the duration of an mp3 file:

[http://www.sourcerally.net/Scripts/20-PHP-MP3-Class](http://www.sourcerally.net/Scripts/20-PHP-MP3-Class)

As you can see I’ve already posted my question there, but you guys rock so I figured I’d give y’all a shot too.

The class returns the “exact time” of an mp3’s duration. What I need to do is convert the “exact time” into minutes.

The correct length of the song I’m working with is 3:47. The “exact time” being returned is 227.4481875.

I thought that I would just have to divide that by 60…but when I do, this is what I get: 3.790803125.

So then I thought, hey “What if I divide the exact number by the correct duration of the song?” No go. It returns 65.5470281. If I try that with any other song, I get a different number ranging(so far) from 63.xxxxxx to 68.xxxxxxx.

Anybody think they can help me? Thanks in advance for all who reply. 🙂
