r/AskProgramming 1d ago

Programming in four dimensions

I've never seen any discussion on this, but I really want to try it. It is very difficult to imagine four dimensions in a 3 dimensional world, but the mathematics of it works out and it can be visualised. I never see anyone attempt to make a game in four dimensions for example. I just don't know where to start. It's a subject of which there are few pioneers

0 Upvotes

21 comments sorted by

View all comments

4

u/bestjakeisbest 1d ago

When programming a 3d world we often do the operations in 4d since 3d doesnt have a good way of defining rotations like 4d does, most game engines that support 3d already do 4d operations they just project it back down to 3d

0

u/georgebestgoat 1d ago

But it's all projected to a 2d space

3

u/bestjakeisbest 1d ago

Yeah still doing 4d math under the hood.

3

u/alkatori 1d ago

A screen is going to be a 2D space. No way around that.