Questions tagged [math]
Programming questions that are significantly affected or best defined by the underlying mathematics of the problem.
286 questions
0 votes
2 answers
429 views
How to translate points on a path relative to two other points?
I'm trying to make a curved line move relative to the movement of a straight line. I'm thinking that I want the points on the curved line to keep their relative positions to the two points on the ...
17 votes
11 answers
18k views
Is it possible to build a system to generate UUIDs where every UUID is guaranteed unique?
Is it possible to design a distributed system to generate unique ids where there is a requirement that every generated id is guaranteed to be unique with no possibility of collision? I didn't think ...
8 votes
7 answers
9k views
What is the size of the number 65535 in bytes? [closed]
As I got to know there are 256 possible combinations to get for 1 byte. If I understand it correctly, it should mean that you can display any number out of numbers 0-255 and this very number would use ...
2 votes
2 answers
156 views
Design a function that indicates significant deviations in response times
I'd need some feedback on how to approach the design of a function that highlights parts of a time series chart. The chart shows the response time of an application, in particular the 90th percentile, ...
2 votes
6 answers
667 views
What is the viability of engineering an integral type with values ranging from -1 to 254? Do types like this even exist?
In software engineering, often developers will utilize three different states of a signed integer, as a trilean: This tends to be quite typical: -1 - Represents something akin to a null pointer, as in ...
-1 votes
5 answers
2k views
Why is What Every Computer Scientist Should Know About Floating-point Arithmetic considered mandatory reading? [closed]
What Every Computer Scientist Should Know About Floating-point Arithmetic is widely considered absolutely mandatory reading for every programmer. Why is this the case? What aspects of the article make ...
2 votes
0 answers
229 views
What algorithm can I use to spread a workload between two processor with fixed resources?
I need to write an algorithm to allocate x number of tasks to 2 processors per day. I know the following: Exact amount of time it will take to complete each task The exact amount of time available ...
-1 votes
5 answers
2k views
Why is converting 0-indexed code to 1-indexed code non-trivial?
The disadvantages of 1-indexing are well-known. However, our hand is sometimes forced by our choice of language and we have to convert algorithms that were intended for a 0-indexed language to being 1-...