Undergrad Converting 2 COD (x,y) into 1 Hilbert curve COD?

  • Thread starter Thread starter greswd
  • Start date Start date
  • Tags Tags
    Curve Hilbert
Click For Summary
The discussion centers on converting two coordinates (x, y) on a unit square into a single Hilbert curve coordinate, which represents the percentile along the curve. Participants explore methods for this conversion, considering the use of recursive functions and patterns based on the order of the Hilbert curve. There is a focus on finding a function that relates x and y to a fraction for the Hilbert curve, starting with lower orders and examining the implications as n approaches infinity. The conversation highlights the complexity of deriving a specific formula for the conversion, emphasizing the challenge of establishing a unique solution for the relationship between L (the length along the curve) and the coordinates. Overall, the thread reflects a collaborative effort to understand and solve a mathematically intricate problem.
greswd
Messages
764
Reaction score
20
COD stands for co-ordinate.

As the title says, you have two co-ordinates of a point, x and y, on a unit square.

What's the formula for converting these two co-ordinates into a single Hilbert curve co-ordinate?

Which represents the percentile along the length of the Hilbert Curve that point is on.
 
Physics news on Phys.org
Inspired by this video

 
greswd said:
What's the formula for converting
Would this be converting 2D to 1D ?

I'm inlcined to think along lines like: write x and y as real numbers. Create a z as follows: first digit is first digit of x, second digit is first digit of y -- third digit is second of x, fourth second of y, etc. etc.

Ever hear of the Hilbert hotel ?
 
Isn't this just the arc length parametrization of the Hilbert curve? Not that it is simple but it seems like a useful way of framing it.
 
Ah, I completely misread this thing o:) -- totally off.
Thanks @WWGD

So @greswd , you want a function of ##\ x, y\ ## and ##n## that returns a fraction for a Hilbert curve of order ##n## starting at the lower left ?

Start with ##n = 1##, then ##2## etc and see if you can find a pattern :rolleyes:
 
  • Like
Likes WWGD
Found some time to watch the video -- cute !
I understand you want the limit for ##n\uparrow \infty## (the ones with finite ##n## are pseudo Hilbert curves). Advice is the same.

Found one value already: ##f(1/2, 1/2) = 1/2 ## :wink:
 
  • Like
Likes greswd
Susspect the time 4:00 -- 5:00 min in the video is important: suppose you work with base 4 numbers and work out the diagonal flip of first and last quadrant ...then make it recursive ..

Just a wake-up thought ...

Intriguing !
 
WWGD said:
Isn't this just the arc length parametrization of the Hilbert curve? Not that it is simple but it seems like a useful way of framing it.
If arc length parametrization is what the video is doing, then yes
 
BvU said:
Ah, I completely misread this thing o:) -- totally off.
Thanks @WWGD

So @greswd , you want a function of ##\ x, y\ ## and ##n## that returns a fraction for a Hilbert curve of order ##n## starting at the lower left ?

Start with ##n = 1##, then ##2## etc and see if you can find a pattern :rolleyes:
thanks, do you know the function for x and y in terms of the fraction and n?
 
Last edited:
  • #10
No idea yet -- first trying to get a good and complete problem statement :wink: in my chaotic mind .

Anyway, PF isn't about doing the work for you, it's about helping you to do the work :biggrin:
(however much we'd like to grab it and do it ourselves o0) )

If I ever have the time, I think I'd start reading this
The heatmap here is nice too

But you already googled those, right :rolleyes: ?
 
  • #11
BvU said:
No idea yet -- first trying to get a good and complete problem statement :wink: in my chaotic mind .

Anyway, PF isn't about doing the work for you, it's about helping you to do the work :biggrin:
(however much we'd like to grab it and do it ourselves o0) )

If I ever have the time, I think I'd start reading this
The heatmap here is nice too

But you already googled those, right :rolleyes: ?

yeah I have haha. The problem is "infinitely" difficult. :-p

Consider the ratio along the length of the HC, L.
From L, you can get a value for X and a value for Y.

So, you get a function for X in terms of L and the same for Y. Next, the inverse functions, L in terms of X and L in terms of Y.
There are an infinite number of inverse functions.

You get two sets of infinite equations, one from X and one from Y.

There can only be one specific value of L which can be the solution to the equations in both infinite sets. And it is the solution to only one equation in each set.

This is way beyond me lol. I just want to know the formula for L in terms of X and Y.
 

Similar threads

  • · Replies 14 ·
Replies
14
Views
3K
  • · Replies 61 ·
3
Replies
61
Views
5K
  • · Replies 18 ·
Replies
18
Views
2K
  • · Replies 14 ·
Replies
14
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K