Jump to content

Dimensional representation


Veracohr

Recommended Posts

Anyone know if it's possible to visually represent more than 3 dimensions in a 2-dimensional medium like an image? We can represent 0-3 dimensions, but is it possible to represent 4 dimensions? I don't know anything about philosophy of dimensions, but we can represent 3 dimensions in a 2-dimensional medium (with some imagination). Is it possible to represent 4 dimensions?

Link to comment
Share on other sites

If you're not bothered about perspective then drawing a hypercube in 2D is very easy; just draw two cubes with lines between the vertices, like so:

 

wCPiSb9.png

Link to comment
Share on other sites

Hmmm.

I don't know too much about the mathematics stuff and all that, but once I delivered an explanation of this to somebody and he found it good, so maybe it helps.

 

I would say, theoretically a 4th dimension would be a single line on which each dot (you know, dots on a line, infinitely small ones etc.) would represent a 3 dimensional image. Just like the "timeline" that Procyon mentioned.

A moving object in space would therefore be a series of these 3 dimensional images on that line where the object is pictured slightly different in each of those, just like if it were a movie -- note that to achieve perfection you'd have to draw the differences infinitely small, but you can't do that -- then, after all, even the human perception has a "refresh rate", so it's not even unnatural.

 

You could then do that with 5 dimensions and more too (in 5 dimensions it would not be a single line but a pane, where each spot in the pane represents a 3 dimenisonal image)...

Link to comment
Share on other sites

Isn't our current conception of 4 dimensions the visualization of an object of 3 dimensions traveling thru time - the 4th one - ?

No, that's just one example of how 4-dimensional spaces are used in physics. In general a fourth dimension doesn't have to be time, it could be anything.

Link to comment
Share on other sites

aren't those representations of hypercubes only projections?

 

depending on the data you could surely graph something four-dimensional in 3d using colours instead of a fourth axis. but this doesn't work for things like for instance the hypercube.

Link to comment
Share on other sites

Already representing a 3-dimensional object on a 2D surface involves projection, or "faking it". For example, multiple points at different depths may overlap in exactly the same 2D position. This may be problematic or amusing. See classics like Ames room or Satire on False Perspective. If you ignore the scaling from distance and use some kind of axonometric projection, effectively you're choosing two directions on the surface that represent two spatial dimensions. That's fine, invertible and unambiguous. What about the third one? Just pick another direction (typically diagonal) and represent depth along that direction. In a simple case, you plot a cube by drawing a square and then extending it diagonally.

 

Now, if you manage to figure that out, it becomes almost trivial to add more dimensions. Just pick yet another direction on the surface and declare that depth in the fourth dimension is towards that. Technically speaking it's just as accurate as using some direction to fake 3D. Unfortunately, we're not used to seeing or understanding 4-dimensional objects. That's why it becomes extremely difficult to follow. Also, you'll have even more information packed into a 2-dimensional image with even more ambiguity from overlapping points etc.

 

Interestingly, >3 dimensions are very simple if you just forget about the spatial interpretation. One of my teachers gave an amusing example of representing simple recipes in a 4-dimensional space consisting of flour, milk, sugar and eggs or something. If you have pure flour, it's along one of the main "axes". If you need all of them, it's in a point in a 4-dimensional space where all components are nonzero. If you want to bake two different things, your shopping list is a sum of two 4-dimensional vectors. Even fancier concepts of linear algebra can be illustrated with that, such as "angle" between two recipes. We're working on concepts like that all the time. They just don't have an intuitive visualisation beyond three dimensions.

Link to comment
Share on other sites

They just don't have an intuitive visualisation beyond three dimensions.

There's a joke about string theory that goes something like this: someone asks a mathematician working in superstring theory how he visualises an 11-dimensional spacetime. He replies "It's easy. I just picture a spacetime with an arbitrary number n of dimensions, then let n = 11."

Link to comment
Share on other sites

For a bit of fun, here's a Python script that draws a rotating hypercube projected onto two dimensions. If you have Python 3.x installed on your computer then copy and paste the following into a file, save it as 'hypercube.py' and then double click on the file to run it:

 

import tkinter as tk
from time import sleep
from math import sin, cos
from random import random

colours = ['#ff0000', '#ff2f00', '#ff5f00', '#ff8f00',
           '#ffbf00', '#ffef00', '#dfff00', '#afff00',
           '#7fff00', '#4fff00', '#1fff00', '#00ff0f',
           '#00ff3f', '#00ff6f', '#00ff9f', '#00ffcf',
           '#00ffff', '#00cfff', '#009fff', '#006fff',
           '#003fff', '#000fff', '#1f00ff', '#4f00ff',
           '#7f00ff', '#af00ff', '#df00ff', '#ff00ef',
           '#ff00bf', '#ff008f', '#ff005f', '#ff002f']


class vertex:
    
    __slots__ = 'coord', 'front'
    
    def __init__(self, coord):
        self.coord = list(coord)
        self.front = coord[3] < 0
    
    def __getitem__(self, n):
        return self.coord[n]
    
    def dsquared(self, other):
        return sum((self[i] - other[i])**2 for i in range(4))

class hypercube:
    
    __slots__ = ('vertices', 'edges', 'omegas', 'vars',
                 'window', 'canvas', 'paused', 'theme')
    
    def __init__(self):
        self.theme = False
        self.paused = False
        
        coords = [[]]
        for i in range(4):
            coords = [c + [x] for c in coords for x in (-.5, .5)]
        self.vertices = [vertex(c) for c in coords]
        assert len(self.vertices) == 16
        
        self.omegas = {}
        for i in range(4):
            for j in range(i):
                self.omegas[(j, i)] = int((random() - .5)*8)/256
        assert len(self.omegas) == 6
        
        self.window = tk.Tk()
        self.window.title('Hypercube')
        self.window.configure(bg = 'black')
        self.canvas = tk.Canvas(self.window, bg = 'black', width
                    = 500, height = 500, highlightthickness = 0)
        self.canvas.grid(row = 0, column = 0, columnspan = 5)
        
        self.edges = {}
        for i, v in enumerate(self.vertices):
            for w in self.vertices[: i]:
                if w.dsquared(v) == 1:
                    if v.front and w.front:
                        colour = 'red'
                    elif not (v.front or w.front):
                        colour = 'blue'
                    else:
                        colour = 'green'
                    self.edges[(w, v)] = self.canvas.create_line(0, 0,
                                         0, 0, fill = colour, width = 4)
        assert len(self.edges) == 32
        
        self.vars = {}
        for n, (ji, o) in enumerate(self.omegas.items()):
            self.vars[ji] = tk.StringVar(self.window, value = '%4i' % (o*256))
            buttonm = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
            text = '<<', command = lambda ji = ji: self.setomega(ji, -1))
            buttonp = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
            text = '>>', command = lambda ji = ji: self.setomega(ji, +1))
            button0 = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
            text = '0', command = lambda ji = ji: self.stopomega(ji))
            label = tk.Label(self.window, fg = 'green', bg = 'black',
                             textvariable = self.vars[ji])
            buttonm.grid(row = n + 1, column = 1, sticky = 'ew')
            button0.grid(row = n + 1, column = 2, sticky = 'ew')
            buttonp.grid(row = n + 1, column = 3, sticky = 'ew')
            label.grid(row = n + 1, column = 4, sticky = 'ew')
        buttonp = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
                            text = 'Pause', command = self.pause)
        buttonr = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
                            text = 'Reset', command = self.reset)
        buttonc = tk.Button(self.window, bg = '#0f0f0f', fg = 'green',
                            text = 'Colours', command = self.themeset)
        buttonp.grid(row = 7, column = 1, sticky = 'ew')
        buttonr.grid(row = 7, column = 2, sticky = 'ew')
        buttonc.grid(row = 7, column = 3, sticky = 'ew')
        
        self.redraw()
        while True:
            try:
                sleep(.01)
                self.rotate()
                self.redraw()
            except tk.TclError:
                break
    
    def setomega(self, ji, v):
        self.omegas[ji] += v/256
        self.vars[ji].set('%4i' % (self.omegas[ji]*256))
    def stopomega(self, ji):
        self.omegas[ji] = 0
        self.vars[ji].set('%4i' % 0)
    def reset(self):
        coords = [[]]
        for i in range(4):
            coords = [c + [x] for c in coords for x in (-.5, .5)]
        for i, c in enumerate(coords):
            self.vertices[i].coord = list(c)
    
    def pause(self):
        if self.paused:
            self.omegas.update(self.paused)
            self.paused = False
        else:
            self.paused = dict(self.omegas)
            for ji in self.omegas:
                self.omegas[ji] = 0
    def themeset(self):
        self.theme = not self.theme
        if self.theme:
            for n, e in enumerate(self.edges.values()):
                self.canvas.itemconfig(e, fill = colours[n])
        else:
            for (w, v), e in self.edges.items():
                if v.front and w.front:
                    colour = 'red'
                elif not (v.front or w.front):
                    colour = 'blue'
                else:
                    colour = 'green'
                self.canvas.itemconfig(e, fill = colour)
        self.canvas.update()
    
    def redraw(self):
        for (w, v), e in self.edges.items():
            self.canvas.coords(e, w[0]*150 + 250, w[1]*150 + 250,
                               v[0]*150 + 250, v[1]*150 + 250)
        self.canvas.update()
    
    def rotate(self):
        for (j, i), o in self.omegas.items():
            matrix = [[int(i == j) for j in range(4)] for i in range(4)]
            matrix[i][i] = matrix[j][j] = cos(o)
            matrix[i][j] = +sin(o)
            matrix[j][i] = -sin(o)
            for v in self.vertices:
                v.coord = [sum(matrix[a][b]*v.coord[b]
                for b in range(4)) for a in range(4)]


if __name__ == '__main__':
    hypercube()
e: If it works, it should look like this:

 

kWbUpQj.png

Link to comment
Share on other sites

  • 2 months later...

By the way, this thread left me feeling like an idiot. For a moment I had this vague idea of making a concept album in which the songs were titled not verbally, but with images representing different orders of dimension. But since I can't even conceptualize a 4-dimensional object represented in 2 dimensions, I can't hope to go further than that. I guess I'll have to be content with being Cletus the Slack-Jawed Yokel.

Link to comment
Share on other sites

By the way, this thread left me feeling like an idiot. For a moment I had this vague idea of making a concept album in which the songs were titled not verbally, but with images representing different orders of dimension. But since I can't even conceptualize a 4-dimensional object represented in 2 dimensions, I can't hope to go further than that.

What part don't you understand? Maybe I can try to explain it better.

Link to comment
Share on other sites

What part don't you understand? Maybe I can try to explain it better.

Well it's not so much a problem understanding, it's a problem seeing this:

 

wCPiSb9.png

 

as a 4-dimensional object.

 

If you're not bothered about perspective

 

And this. It's the perspective I have a hard time with, and we were just talking about 4-dimensional objects here. I've always had a hard time with perspective-based images; like those ones with an image hidden in a pattern, I could never see those.

Link to comment
Share on other sites

Well it's not so much a problem understanding, it's a problem seeing this:

 

wCPiSb9.png

 

as a 4-dimensional object.

Well, you know how to see this as a 3-dimensional object, right?

 

1197102410779121298mcol_necker_cube.svg.

 

One way to think of it is like this: a square is a two-dimensional figure, in that it extends in two directions (e.g. it has width and length). Now suppose you have a large number of equally-sized squares of paper. If you put those pieces of paper into a pile they can make a cube; that has an additional dimension, namely height. In the image above you see two squares with diagonal lines between them, depicting a cube. If the cube is our pile of square paper, one square might depict the top piece of paper and the other the bottom piece, and the four diagonal lines would then depict the four vertical corners of the pile.

 

Now, just as you can think of a cube as a large number (actually infinitely many) of horizontal squares at different heights, you can think of a hypercube as infinitely many cubes separated by a new dimension. It might help to think of this new dimension as time. So all of our cubes are in the same place, but they are at different times. Just like there was a top square and a bottom square in our pile of squares that made a cube, there's a first cube and a last cube in our bundle of cubes that makes a hypercube. The hypercube image I made earlier just generalises the cube image above: I drew the first cube, and the last cube, and then I joined their vertices with lines representing the edges that are aligned with the time dimension.

 

Does that help?

Link to comment
Share on other sites

While I know you're drunk, given your posts in the drunk thread, that's actually an interesting question: why does our universe have the number of dimensions it does? At least, the 4 we can readily observe.

This is a question that physicists ponder. If superstring theory is correct, for example, then the universe should actually have ten dimensions rather than the four we see. This doesn't necessarily mean that superstring theory is wrong; rather, it is possible that there are extra dimensions that are "curled up" so as to be too small to see (similarly to how a narrow straw has a two-dimensional surface but looks like a one-dimensional line from a distance). The question then becomes why four of those dimensions should be much larger than the others. There may turn out to be an explanation for that, for example from the anthropic principle (there might be many universes, but those with four large dimensions might be much more likely to allow the evolution of intelligent beings for some reason, so any such intelligent beings would expect to find themselves in one of the four-large-dimensional universes). I don't know what the current thinking is on that, having been out of the field for a few years.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...