I was wondering if there is any way to take the sine or cosine of every element in a matrix?

Thanks!

1 | initial version |

I was wondering if there is any way to take the sine or cosine of every element in a matrix?

Thanks!

2 | No.2 Revision |

I was wondering if there is any way to take the sine or cosine of every element in a matrix?

Thanks!

EDIT: For future reference, I did the Taylor expansion of Sine. For pretty good accuracy, I only had calculate up to the fourth term. However, keep note that if you are trying to estimate sin(pi) or sin(-pi) you have to calculate additional terms (probably 8 total terms).

This link will be useful for those who want to do this: http://en.wikipedia.org/wiki/Taylor_series#Approximation_and_convergence

3 | No.3 Revision |

I was wondering if there is any way to take the sine or cosine of every element in a matrix?

Thanks!

EDIT: For future reference, I did the Taylor expansion of Sine. For pretty good accuracy, I only had to calculate up to the fourth term. However, keep note that if you are trying to estimate sin(pi) or sin(-pi) you have to calculate additional terms (probably 8 total terms).

This link will be useful for those who want to do this: http://en.wikipedia.org/wiki/Taylor_series#Approximation_and_convergence

4 | retagged |

I was wondering if there is any way to take the sine or cosine of every element in a matrix?

Thanks!

EDIT: For future reference, I did the Taylor expansion of Sine. For pretty good accuracy, I only had to calculate up to the fourth term. However, keep note that if you are trying to estimate sin(pi) or sin(-pi) you have to calculate additional terms (probably 8 total terms).

This link will be useful for those who want to do this: http://en.wikipedia.org/wiki/Taylor_series#Approximation_and_convergence

Copyright OpenCV foundation, 2012-2018. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.