Summary of the invention
In order to explain the problems referred to above, the invention discloses the range computing method of a kind of n frequency coded structured light, these computing method can not only calculate the range of n frequency coded structured light, and can illustrate that the change of short period strip encoding to range is not contributed when the cycle of a strip encoding is another strip encoding cycle integral multiple; Can illustrate that the projection sequence of n frequency coded structured light does not affect range simultaneously; In addition, in prime factor decomposes, if arranged from small to large by prime factor, algorithm also has uniqueness.
The object of the present invention is achieved like this:
Range computing method for n frequency coded structured light, comprise the following steps:
S1, projection strip encoding
Project n strip encoding, the cycle of described strip encoding is respectively a
1, a
2..., a
n,
Wherein, a
1, a
2..., a
nbe positive integer;
S2, resolve into factors of prime number
According to the following formula respectively to a
1, a
2..., a
ncarry out prime factor decomposition:
…………………………
Wherein, b
1, b
2..., b
mfor from a
1, a
2..., a
nmiddle decomposition all different prime factor out;
S3, calculating range
Calculate range according to the following formula:
Wherein, t is the range of n frequency coded structured light.
The range computing method of said n frequency coded structured light, described b
1, b
2..., b
maccording to order arrangement from small to large.
Range computing method for n frequency coded structured light, comprise the following steps:
S1, projection strip encoding
Project n strip encoding, the cycle of described strip encoding is respectively a
1, a
2..., a
n,
Wherein, a
1, a
2..., a
nbe not entirely positive integer or complete be not positive integer;
S2, adjustment code period
To the cycle a of strip encoding
1, a
2..., a
nadjust, concrete grammar is:
A
1=ka
1
A
2=ka
2
…………
A
n=ka
n
In formula, A
1, A
2..., A
nfor the cycle after adjustment, be positive integer; K is for making A
1, A
2..., A
nbe the positive number of positive integer;
S3, resolve into factors of prime number
According to the following formula respectively to A
1, A
2..., A
ncarry out prime factor decomposition:
………………………………
Wherein, B
1, B
2..., B
mfor from A
1, A
2..., A
nmiddle decomposition all different prime factor out;
S4, calculating range
Calculate range according to the following formula:
Wherein, T is the range of the n frequency coded structured light after adjustment code period;
S5, adjustment range
Calculate range according to the following formula:
t=T/k
Wherein, t is the range of n frequency coded structured light.
The range computing method of said n frequency coded structured light, described B
1, B
2..., B
maccording to order arrangement from small to large.
The range computing method of said n frequency coded structured light, in step S2, k is for making A
1, A
2..., A
nbe the minimum positive number of positive integer.
Beneficial effect:
The first, this application provides the range computing method of a kind of n frequency coded structured light;
The second, the application can illustrate that the change of short period strip encoding to range is not contributed when the cycle of a strip encoding is another strip encoding cycle integral multiple;
Three, the application can illustrate that the projection sequence of n frequency coded structured light does not affect range.
Four, the application's prime factor decomposes, and prime factor arranges from small to large, and k is for making A
1, A
2..., A
nbe the minimum positive number of positive integer, whole derivation all can be made to have uniqueness.
Embodiment
Specific embodiment one
The range computing method of the n frequency coded structured light of the present embodiment, for 4 frequently, comprise the following steps:
S1, projection strip encoding
Project 4 strip encodings, the cycle of described strip encoding is respectively 4,5,6,7, and in the present embodiment, the cycle of all strip encodings is positive number;
S2, resolve into factors of prime number
Because 4 can resolve into 2 × 2,5 can not prime factor decompose, 6 can resolve into 2 × 3,7 can not prime factor decompose, all prime factors according to from small to large order arrangement after result be 2,3,5,7, now, carry out prime factor decomposition to 4,5,6,7, be specially:
4=2
2×3
0×5
0×7
0
5=2
0×3
0×5
1×7
0
6=2
1×3
1×5
0×7
0
7=2
0×3
0×5
0×7
1
S3, calculating range
Calculate range t according to the following formula:
t=2
max(2,0,1,0)×3
max(0,0,1,0)×5
max(0,1,0,0)×7
max(0,0,0,1)=2
2×3
1×5
1×7
1=420。
Specific embodiment two
The range computing method of the n frequency coded structured light of the present embodiment, still for 4 frequently, comprise the following steps:
S1, projection strip encoding
Project 4 strip encodings, the cycle of described strip encoding is respectively 3.5,4,5,6, and in the present embodiment, the cycle of all strip encodings is not positive integer entirely;
S2, adjustment code period
Adjust the cycle 3.5,4,5,6 of strip encoding, concrete grammar is:
A
1=3.5k
A
2=4k
A
3=5k
A
4=6k
In formula, A
1, A
2, A
3, A
4for the cycle after adjustment, be positive integer; K is for making A
1, A
2..., A
nbe the minimum positive number of positive integer, can k=2 be known, and have:
A
1=7
A
2=8
A
3=10
A
4=12
S3, resolve into factors of prime number
Due to 7 can not prime factor decompose, 8 can resolve into 2 × 2 × 2, and 10 can resolve into 2 × 5, and 12 can resolve into 2 × 2 × 3, all prime factors according to from small to large order arrangement after result be 2,3,5,7, now, carry out prime factor decomposition to 7,8,10,12:
7=2
0×3
0×5
0×7
1
8=2
3×3
0×5
0×7
0
10=2
1×3
0×5
1×7
0
12=2
2×3
1×5
0×7
0
S4, calculating range
Calculate range according to the following formula:
T=2
max(0,3,1,2)×3
max(0,0,0,1)×5
max(0,0,1,0)×7
max(1,0,0,0)=2
3×3
1×5
1×7
1=840
S5, adjustment range
Calculate range according to the following formula:
t=T/k=840/2=420。
Specific embodiment three
The range computing method of the n frequency coded structured light of the present embodiment, still for 4 frequently, comprise the following steps:
S1, projection strip encoding
Project 4 strip encodings, the cycle of described strip encoding is respectively 3.5,4.2,5.4,6.3, and in the present embodiment, the cycle of all strip encodings is not positive integer entirely;
S2, adjustment code period
Adjust the cycle 3.5,4.2,5.4,6.3 of strip encoding, concrete grammar is:
A
1=3.5k
A
2=4.2k
A
3=5.4k
A
4=6.3k
In formula, A
1, A
2, A
3, A
4for the cycle after adjustment, be positive integer; K is for making A
1, A
2..., A
nbe the minimum positive number of positive integer, can k=10 be known, and have:
A
1=35
A
2=42
A
3=54
A
4=63
S3, resolve into factors of prime number
Because 35 can resolve into 5 × 7,42 can resolve into 2 × 3 × 7, and 54 can resolve into 2 × 3 × 3 × 3,63 can resolve into 3 × 3 × 7, all prime factors according to from small to large order arrangement after result be 2,3,5,7, now, carry out prime factor decomposition to 35,42,54,63:
35=2
0×3
0×5
1×7
1
42=2
1×3
1×5
0×7
1
54=2
1×3
3×5
0×7
0
63=2
0×3
2×5
0×7
1
S4, calculating range
Calculate range according to the following formula:
T=2
max(0,1,1,0)×3
max(0,1,3,2)×5
max(1,0,0,0)×7
max(1,1,0,1)=2
1×3
3×5
1×7
1=1890
S5, adjustment range
Calculate range according to the following formula:
t=T/k=1890/10=189。
Specific embodiment four
The range computing method of the n frequency coded structured light of the present embodiment, comprise the following steps:
S1, projection strip encoding
Project n strip encoding, the cycle of described strip encoding is respectively a
1, a
2..., a
i..., a
j..., a
n; Wherein, a
j/ a
i∈ N
S2, adjustment code period
To the cycle a of strip encoding
1, a
2..., a
i..., a
j..., a
nadjust, concrete grammar is:
A
1=ka
1
A
2=ka
2
…………
A
i=ka
i
…………
A
j=ka
j
…………
A
n=ka
n
In formula, A
1, A
2..., A
i..., A
j..., A
nfor the cycle after adjustment, be positive integer; K is for making A
1, A
2..., A
i..., A
j..., A
nfor the minimum positive number of positive integer;
Here it should be noted that, if:
A
1, a
2..., a
i..., a
j..., a
nbe integer, so k=1, the content that corresponding claims 1 are protected;
A
1, a
2..., a
i..., a
j..., a
nbe not entirely positive integer or complete be not positive integer, so k ≠ 1, the content that corresponding claims 3 are protected;
Therefore, without loss of generality;
S3, resolve into factors of prime number
According to the following formula respectively to A
1, A
2..., A
i..., A
j..., A
ncarry out prime factor decomposition:
………………………………
………………………………
………………………………
Wherein, B
1, B
2..., B
mfor from A
1, A
2..., A
i..., A
j..., A
nmiddle decomposition all different prime factor out;
Due to a
j/ a
i∈ N, therefore ka
j/ ka
i∈ N, and then A
j/ A
i∈ N, that is: so have:
due to B
1, B
2..., B
mfor mutually different prime number, therefore require A
jz>=A
i, wherein, z=1,2 ..., m;
S4, calculating range
Calculate range according to the following formula:
With max (A
11, A
21..., A
i1..., A
j1..., A
n1) illustrate, due to A
jz>=A
i, so A
j1>=A
i1, Jin Eryou
by that analogy, max (A is had
1z, A
2z..., A
iz..., A
jz..., A
nz)=max (A
1z, A
2z..., A
i-1z, A
i+1z..., A
jz..., A
nz), this explanation cycle is a
ior A
iencoded light whether exist, all can not change range, and then demonstrate when the cycle of a strip encoding is another strip encoding cycle integral multiple, the change of short period strip encoding to range does not have contributive conclusion.
S5, adjustment range
Calculate range according to the following formula:
t=T/k
Wherein, t is the range of n frequency coded structured light.
Specific embodiment five
In the present embodiment, by changing the projection sequence of i-th coded structured light and a jth coded structured light in n frequency coded structured light, verify that the projection sequence of n frequency coded structured light does not affect range.
S1, project two group coding stripeds
First group: project n strip encoding, the cycle of described strip encoding is respectively a
1, a
2..., a
i..., a
j..., a
n;
Second group: project n strip encoding, the cycle of described strip encoding is respectively a
1, a
2..., a
j..., a
i..., a
n;
Can be by, in these two groups, the projection sequence of i-th coded structured light and a jth coded structured light has been exchanged;
S2, adjustment code period
To the cycle a of strip encoding
1, a
2..., a
i..., a
j..., a
n, and a
1, a
2..., a
j..., a
i..., a
nadjust, concrete grammar is:
A
1=ka
1
A
2=ka
2
…………
A
i=ka
i
…………
A
j=ka
j
…………
A
n=ka
n
And
A
1=ka
1
A
2=ka
2
…………
A
j=ka
j
…………
A
i=ka
i
…………
A
n=ka
n
In formula, A
1, A
2..., A
i..., A
j..., A
nand A
1, A
2..., A
j..., A
i..., A
nbe the cycle after adjustment, be positive integer; K is for making A
1, A
2..., A
i..., A
j..., A
nand A
1, A
2..., A
j..., A
i..., A
nbe the minimum positive number of positive integer;
Here it should be noted that, if:
A
1, a
2..., a
i..., a
j..., a
nand a
1, a
2..., a
j..., a
i..., a
nbe integer, so k=1, the content that corresponding claims 1 are protected;
A
1, a
2..., a
i..., a
j..., a
nand a
1, a
2..., a
j..., a
i..., a
nbe not entirely positive integer or complete be not positive integer, so k ≠ 1, the content that corresponding claims 3 are protected;
Therefore, without loss of generality;
S3, resolve into factors of prime number
According to the following formula respectively to A
1, A
2..., A
i..., A
j..., A
nand A
1, A
2..., A
j..., A
i..., A
ncarry out prime factor decomposition:
………………………………
………………………………
………………………………
And
………………………………
………………………………
………………………………
Wherein, B
1, B
2..., B
mfor from A
1, A
2..., A
i..., A
j..., A
nand A
1, A
2..., A
j..., A
i..., A
nmiddle decomposition all different prime factor out;
S4, calculating range
Calculate range according to the following formula:
For the first group coding light:
For the second group coding light:
With max (A
11, A
21..., A
i1..., A
j1..., A
n1) and max (A
11, A
21..., A
j1..., A
i1..., A
n1) illustrate, due to get in one group of data the result of maximal value and this to organize data ordering order irrelevant, therefore have:
max(A
11,A
21,…,A
i1,…,A
j1,…,A
n1)=max(A
11,A
21,…,A
j1,…,A
i1,…,A
n1)
The like, can know:
T=T
1=T
2
Wherein, T is the range of two groups of n frequency coded structured lights after adjustment code period;
S5, adjustment range
Calculate range according to the following formula:
t=T/k
Wherein, t is the range of two groups of n coded structured lights frequently, visible, and no matter how the projection sequence of encoded light changes, and final range is all unique, and the projection sequence demonstrating n coded structured light frequently does not affect the conclusion of range.