rem - 1 year ago 102

R Question

What is the time-complexity of arithmetic operations in R? E.g. is multiplication of two 32-bit integers constant-time?

Recommended for you: Get network issues from **WhatsUp Gold**. **Not end users.**

Answer Source

If you look here you'll see that in R, integer multiplication simply calls the C integer-multiplication operator. So the only answer I can give to "what is the time complexity of integer multiplication in R?" is "the same as the time complexity of integer multiplication with whatever C compiler has been used to compile R"; the answer to *that* question will usually be "the same as the time complexity of the integer-multiplication machine instruction (e.g., `IMUL`

) on the particular chip on which you are running".

Recommended from our users: **Dynamic Network Monitoring from WhatsUp Gold from IPSwitch**. ** Free Download**