Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Simple math question

Name: Anonymous 2009-12-15 13:56

Hey /bros/, excuse me while I try to come up with the words to explain this basic math concept. I'm trying to "round" values into steps, like so:

1 2 3 4 5 6 7 8 9

might become

1 1 1 4 4 4 7 7 7

or

1 1 1 1 1 6 6 6 6

I know there's a mathematical operation that can do this. If you were to graph the values, let's say as compared to y = x,  it would look like stairs instead of a straight line. (I'm pretty sure that with the right mathematical function the "step size" could be arbitrary.) I know this must be elementary school-level math and yet nothing is coming to me. Any ideas?

Name: Anonymous 2009-12-16 13:06

>>21
Getting the average of an arbitrary function over an area
OP asks about a step function
sweet sage

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List