Ask Your Question
1

What is the quickest way to execute sine, cosine, and square root in C++ without focusing too much on accuracy?

asked 2022-08-10 11:00:00 +0000

nofretete gravatar image

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2022-04-18 05:00:00 +0000

ladyg gravatar image

The quickest way to execute sine, cosine, and square root in C++ without too much focus on accuracy is to use the "cmath" library's functions "sin", "cos", and "sqrt". These functions are built into C++ and are optimized to run quickly. However, it should be noted that sacrificing accuracy can lead to errors in calculations, so it is important to weigh the trade-offs between speed and precision.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss

Add Answer


Question Tools

Stats

Asked: 2022-08-10 11:00:00 +0000

Seen: 7 times

Last updated: Apr 18 '22