# Converted from ms per int to Hertz [closed]

I am trying to convert from ms per int to Hertz.

I have found that my system takes 0.2313ms to transfer one 32 bit interger.

Based on this answer Difference between Hz and bps

I have divided my answer by 1000 (to converted for milliseconds to seconds) then divided by 32 (to convert from int to bit) and then taking the inverse of the resulting number (to get Hertz).

The final answer that I got - 138.34kHz seems to much higher than I was expecting. Have I made a mistake or misunderstood something?

• What is an "int"? – The Photon Apr 22 '16 at 4:38
• If an int is a 32-bit integer then you are transferring 138.34 kbps. As outlined in the question you linked to, how much bandwidth it takes to transfer that depends on the coding scheme (FM might use more than 138 kHz, multilevel coding might use less). – The Photon Apr 22 '16 at 4:42
• Totally unclear what "Hz" you want. It could be the sampling rate at which you're generating integers (around 4 kHz), or the transmission bit rate (which will be 4 kHz * 32 (bits) plus something for framing overhead (start and stop bits, +2 bits per byte for RS232, for around 160kHz) or something else. – Brian Drummond Apr 22 '16 at 11:58
• Also, a system handling 32bit units being able to transfer at 160kBps or similar wasn't shocking anymore in the 80's, so I'm a bit confused by your confusion. – Asmyldof Apr 24 '16 at 7:05

## 1 Answer

Here's an engineering-ish way of estimating it:

If you did a transfer once every 1ms, that would be 1000 operations per second.

Each transfer is 32 bits at a time, so you really moved 32,000 bits per second.

0.2313 ms is close to .25 ms or a quarter of a millisecond, so multiply our previous estimate by 4: 4 * 30,000 = 120,000. Note how I used 30k in place of 32k just to make the arithmetic easier.

Your answer is close to what we estimated. The reason it seems fast is that you process 32 bits at a time. If these are being transferred in parallel (as 32-bit words), then that's one way to get a high transfer rate. If it's coming in serially, well, either the system is relatively high performance, or else you need to check your measurement to be sure it really was .23 milliseconds.