CN102156626B - Sine-cosine function IP core capable of reconfiguring spaceborne computer - Google Patents

Sine-cosine function IP core capable of reconfiguring spaceborne computer Download PDF

Info

Publication number
CN102156626B
CN102156626B CN201110107337A CN201110107337A CN102156626B CN 102156626 B CN102156626 B CN 102156626B CN 201110107337 A CN201110107337 A CN 201110107337A CN 201110107337 A CN201110107337 A CN 201110107337A CN 102156626 B CN102156626 B CN 102156626B
Authority
CN
China
Prior art keywords
cosine
value
module
sine
multiplier
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CN201110107337A
Other languages
Chinese (zh)
Other versions
CN102156626A (en
Inventor
潘瑞
于文进
兰盛昌
徐国栋
徐卓异
丁玉叶
马玉海
林晓辉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Harbin Institute of Technology
Original Assignee
Harbin Institute of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Harbin Institute of Technology filed Critical Harbin Institute of Technology
Priority to CN201110107337A priority Critical patent/CN102156626B/en
Publication of CN102156626A publication Critical patent/CN102156626A/en
Application granted granted Critical
Publication of CN102156626B publication Critical patent/CN102156626B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Position Fixing By Use Of Radio Waves (AREA)
  • Control Of Position, Course, Altitude, Or Attitude Of Moving Bodies (AREA)

Abstract

The invention relates to a sine-cosine function IP core capable of reconfiguring a spaceborne computer and a control method thereof, relating to the technical field of aerospace electronics, and solving the problems that the result of initial value assignment is largely influenced due to rounding errors, and the larger the angle is, the more the iteration times is needed. An initializing module is connected with a right-shift N-bit module and a module 1, the module 1 is connected with a cosine value storing device, the right-shift N-bit module is connected with a sine value storing device, the cosine value storing device and the sine value storing device are connected with a subtracter-adder and a first multiplier, the subtracter-adder is connected with a second multiplier and then is connected with the cosine value storing device, the first multiplier is connected with a left-shift 1-bit module and then is connected with the sine value storing device, and the a controller is connected with the sine value storing device and the cosine value storing device. The control method comprises the following steps of: mapping eta into [0, pi/2] to generate theta; judging whether theta is less than and equal to beta; if theta is less than and equal to beta, directly assigning the value and carrying out the last step; otherwise, carrying out the iteration operation, and obtaining an assigned initial value according to an approximate rule; calculating by utilizing a double-angle formula, judging whether n is less than N; if n is less than N, calculating again; otherwise, finishing the operation; finally assigning a sine/cosine function value according to the positive/negative result obtained by the sign bit judgment. The invention is applied to attitude control.

Description

The sin cos functions IP kernel of reconfigurable satellite-borne computer
Technical field
The present invention relates to the electronic technology field of space flight and aviation.
Background technology
Along with the restructural technology is constantly opened up in the application of space industry, become satellite electron systematic research focus based on the spaceborne computer of FPGA (Field Programmable GateArray, field programmable gate array).Use with FPGA and can reduce volume, weight, power consumption and the cost of microsatellite, improve the functional density of system as the satellite electron system of core.
Attitude is confirmed and the attitude control and treatment is one of critical function of spaceborne computer; In traditional spaceborne computer; The standard sincos functions that call in the C language mathematical function library that rely on carry out the calculating of attitude control algolithm more; Its time of calculating sin cos functions is up to 2.5 μ s/ time (be accurate to radix point after 7), it is thus clear that the computed in software sin cos functions is consuming time very long.The general algorithm that adopts IP kernel to calculate sin cos functions has look-up table, polynomial expansion method, cordic algorithm and process of iteration.Though wherein look-up table also can Rapid Realization, be subject to the size and the speed of memory device; The polynomial expansion method does not receive the restriction of storage space, but needs could guarantee convergence after the normalization, and precision is not high; Cordic algorithm can reach precision arbitrarily, but its computing velocity is relevant with computational accuracy, and computational accuracy requires high more, and convergent speed is just slow more as a result; Process of iteration is the fastest, but iterations is relevant with the calculating angle, and it is big more to calculate angle, and required iterations is just many more.The principle of iterative algorithm is: for arbitrary input angle θ, with it divided by 2 N, when N is enough big, all can obtain very little angle [alpha] ≈ θ/2 nAccording to approximate criterion, can be similar to and obtain sin α ≈ α, cos α ≈ 1.Utilize double angle formula
sin2α=2×sinα×cosα
cos2α=(cosα+sinα)×(cosα-sinα)
Iteration can obtain importing the sine and cosine value of angle for N time.
Can know from principle: when angle was little, less N just can satisfy the approximate valuation requirement, and number of iterations is less, and the speed of calculating is very fast.In the process of iteration, can use two register-stored result of calculations, as the input of next iteration, and do not need extra storage space, and can calculate the sin cos functions value simultaneously.But there is round-off error in the initial assignment of iterative algorithm, and it is very big to result's influence; Keep limited bits in the iterative process, have truncation error, along with increasing of iterations, the error of accumulation increases; For different angles, the iterations that needs is different, and angle is big more, and the iterations that needs is many more, therefore needs further to optimize.
Summary of the invention
There is round-off error in the initial assignment that the present invention solves for existing iterative algorithm, and it is to the far-reaching problem of result; And for different angles, the iterations that needs is different, and angle is big more, the more defectives of iterations that need, and a kind of sin cos functions IP kernel and control method thereof of reconfigurable satellite-borne computer are proposed.
The sin cos functions IP kernel of reconfigurable satellite-borne computer comprises initialization module 1, the N position module that moves to right 2,1 module 3, subtracter 4, totalizer 5, first multiplier 6, second multiplier 7,1 module 8, sine value storer 9, cosine value storer 10 and controller 11 move to left; The input end of initialization module 1 is the angle η input end of the sin cos functions IP kernel of reconfigurable satellite-borne computer; Two output terminals of initialization module 1 connect the move to right input end of N position module 2 and the input end of 1 module 3 respectively; The output terminal of 1 module 3 connects the first input end of cosine value storer 10; The output terminal of the N position module 2 that moves to right connects the first input end of sine value storer 9; The output terminal of cosine value storer 10 connects the first input end of subtracter 4, the first input end of totalizer 5 and the first input end of first multiplier 6 respectively; The output terminal of sine value storer 9 connects second input end of subtracter 4, second input end of totalizer 5 and second input end of first multiplier 6 respectively; The output terminal of subtracter 4 connects the first input end of second multiplier 7; The output terminal of totalizer 5 connects second input end of second multiplier 7, and the output terminal of second multiplier 7 connects second input end of cosine value storer 10, and the output terminal of first multiplier 6 connects the input end of 1 module 8 that moves to left; The output terminal of 1 module 8 that moves to left connects second input end of sine value storer 9; The 4th output terminal of sine value storer 9 is the sinusoidal output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer, and the 4th output terminal of cosine value storer 10 is the cosine output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer, and two signal controlling ends of controller 11 connect the control signal receiving end of sine value storer 9 and the control signal receiving end of cosine value storer 10 respectively.
The step of the control method of the sin cos functions IP kernel of reconfigurable satellite-borne computer is following:
Step 1: according to the periodicity of trigonometric function angle η being mapped to becomes input angle θ in [0, pi/2], and sign bit is set;
Step 2: it is disconnected to carry out anticipation, and whether the input angle θ that judges input smaller or equal to given critical angle β is; Promptly when β>=θ, then directly utilize sin θ=θ, cos θ=1 to carry out assignment and get into step 4, not; Promptly when β<θ≤pi/2, then get into step 3;
Step 3: interative computation:
Step 1: the input angle θ to input carries out interative computation, will import angle θ divided by 2 N, obtain initial assignment according to approximate criterion:
sinα=θ/2 N
cosα=1
n=0
Wherein, N representes total iterations, and n representes iteration the n time;
Step 2: utilize double angle formula to calculate:
cos2 n+1α=(cos2 nα+sin2 nα)×(cos2 nα-sin2 nα)
sin2 n+1α=2×sin2 nα×cos2 nα
n=n+1
Step 3: judge n<N, be, then return step 2 and calculate once more, not, then get into step 4;
Step 4: accomplish sine and cosine value sin θ=sin 2 that interative computation obtains importing angle θ Nα, cos θ=cos 2 Nα;
Step 4: judge the positive and negative of resulting result according to sign bit, give the sin cos functions value, obtain final sine and cosine value.
The objective of the invention is to design the IP kernel that a kind of FPGA of utilization hardware calculates the sincos function,, carry out attitude control, improve the performance of reconfigurable satellite-borne computer as the coprocessor of reconfigurable satellite-borne computer.Require very high to the real-time of calculating in the attitude of satellite control; The computing velocity of process of iteration is the fastest and to take resource also less; So the present invention is optimized process of iteration according to actual needs; Round-off error in the iterative algorithm and truncation error are inevitably, but can error reduced through the method that increases the register figure place.For being accurate to behind the radix point 7, will keep 15 position effective digitals among the present invention and carry out interative computation, and the error that computing machine is preserved double-precision floating points is 10 -15~10 -16Between, carry out interative computation so keep 15 position effective digitals among the present invention.When the calculating angle was big, iterations is very big could to satisfy accuracy requirement, suitably dwindled the scope of calculating angle and can improve the efficient of calculating.In addition, just can satisfy accuracy requirement, carry out interative computation and can increase unnecessary calculated amount on the contrary for the low-angle indirect assignment; And precision is reduced, in design, iterative algorithm is optimized according to analyzing: the field of definition of calculating angle η sin cos functions for (∞ ,+∞); According to the periodicity of trigonometric function, will import angle θ and be mapped in [0, pi/2]; And sign bit is set, import the calculating of angle θ sin cos functions again.Calculate the scope of angle and dwindle, make iterations reduce, accumulated error is little, has improved speed and the precision calculated.As input angle θ during smaller or equal to given critical angle β, indirect assignment need not carry out the requirement that iteration also can reach precision, improves the speed of calculating.
Description of drawings
Fig. 1 is the process flow diagram of control method of the sin cos functions IP kernel of reconfigurable satellite-borne computer; Fig. 2 is the structural representation of the sin cos functions IP kernel of reconfigurable satellite-borne computer.
Embodiment
Embodiment one: combine Fig. 1 that this embodiment is described, this embodiment step is following:
Step 1: according to the periodicity of trigonometric function angle η being mapped to becomes input angle θ in [0, pi/2], and sign bit is set;
Step 2: it is disconnected to carry out anticipation, and whether the input angle θ that judges input smaller or equal to given critical angle β is; Promptly when θ≤β, then directly utilize sin θ=θ, cos θ=1 to carry out assignment and get into step 4, not; Promptly when β<θ≤pi/2, then get into step 3;
Step 3: interative computation:
Step 1: the input angle θ to input carries out interative computation, will import angle θ divided by 2 N, obtain initial assignment according to approximate criterion:
sinα=θ/2 N
cosα=1
n=0
Wherein, N representes total iterations, and n representes iteration the n time;
Step 2: utilize double angle formula to calculate:
cos2 n+1α=(cos2 nα+sin2 nα)×(cos2 nα-sin2 nα)
sin2 n+1α=2×sin2 nα×cos2 nα
n=n+1
Step 3: judge n<N, be, then return step 2 and calculate once more, not, then get into step 4;
Step 4: accomplish sine and cosine value sin θ=sin2 that interative computation obtains importing angle θ Nα, cos θ=cos2 Nα;
Step 4: judge the positive and negative of resulting result according to sign bit, give the sin cos functions value, obtain final sine and cosine value.
Embodiment two: this embodiment and embodiment one difference are the asking for of critical angle β in the step 2:
The design accuracy that expection reaches is 10 -m, according to the principle of initial assignment, critical angle β should satisfy:
sin β - β ≤ 10 - m 1 - cos β ≤ 10 - m
For example, expect that the design accuracy that reaches is 10 -7, critical angle β should satisfy:
sin β - β ≤ 10 - 7 1 - cos β ≤ 10 - 7
The β that asks=0.0014.Other composition is identical with embodiment one with connected mode.
Embodiment three: this embodiment and embodiment one or 2 are that the total iterations N in the step 3 is 21 times; Adopt iterative algorithm to realize that the main error of sin cos functions has: round-off error and truncation error.When iterative process keeps significant figure more for a long time, truncation error is very little to the result of calculation influence, can ignore, so only consider the round-off error that in initial assignment, produces.
Sinx, cosx are carried out Taylor launch, have:
sinx=x-x 3/3!+x 5/5!-…
cosx=1-x 2/2!+x 4/4!-…
When the value of x much smaller than 1 the time, only need to keep first requirement that can satisfy computational accuracy of expansion.
Make α ≈ θ/2 N, establish n step iterative computation error sinusoidal, cosine and be respectively ε n, Δ n, the error expression of employing recurrence method derivation sin cos functions.At first carry out initial assignment, sin α ≈ α, cos α ≈ 1 ignore high order power error, then have
ε 0=|-α 3/3!+α 5/5!-…|≈α 3/3!
Δ 0=|-α 2/2!+α 4/4!-…|≈α 2/2!
By that analogy, the size of finding iteration error and α, number of iterations are relevant, and the derivation iteration error is as shown in table 1:
Table 1 iteration error
Iterations The sinusoidal calculations error The cosine error of calculation
0 α 3/3 α 2/2
1 3/3 α 2
2 20α 3/3 2
3 88α 3/3 2
... ... ...
n 2 n-1(2 n-2/3)α 3 2 n-1α 2
When θ>1, can get
2 n-1(2 n-2/3)α 3≈2 2n-1α 3
=(2 n-1α 2)·(2 nα)
=2 n-1α 2·θ>2 n-1α 2
Derive and can know according to following formula: when angle is big, the error that the error of sinusoidal calculations is calculated greater than cosine, the precision that only needs to consider sinusoidal calculations gets final product.Angle is big more in iterative algorithm, and iterations is many more.When θ=pi/2, can know according to the sinusoidal calculations error formula, reach 10 -7Precision need iteration 21 times, so can reach the requirement of design accuracy for 21 times for [0, pi/2] interior unspecified angle iteration.Other composition is identical with embodiment one or two with connected mode.
Embodiment four: combine bright embodiment of Fig. 2, this embodiment comprises initialization module 1, the N position module that moves to right 2,1 module 3, subtracter 4, totalizer 5, first multiplier 6, second multiplier 7,1 module 8, sine value storer 9, cosine value storer 10 and controller 11 move to left; The input end of initialization module 1 is the angle η input end of the sin cos functions IP kernel of reconfigurable satellite-borne computer; Two output terminals of initialization module 1 connect the move to right input end of N position module 2 and the input end of 1 module 3 respectively; The output terminal of 1 module 3 connects the first input end of cosine value storer 10; The output terminal of the N position module 2 that moves to right connects the first input end of sine value storer 9; The output terminal of cosine value storer 10 connects the first input end of subtracter 4, the first input end of totalizer 5 and the first input end of first multiplier 6 respectively; The output terminal of sine value storer 9 connects second input end of subtracter 4, second input end of totalizer 5 and second input end of first multiplier 6 respectively; The output terminal of subtracter 4 connects the first input end of second multiplier 7; The output terminal of totalizer 5 connects second input end of second multiplier 7, and the output terminal of second multiplier 7 connects second input end of cosine value storer 10, and the output terminal of first multiplier 6 connects the input end of 1 module 8 that moves to left; The output terminal of 1 module 8 that moves to left connects second input end of sine value storer 9; The 4th output terminal of sine value storer 9 is the sinusoidal output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer, and the four-input terminal of cosine value storer 10 is the cosine output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer, and two signal controlling ends of controller 11 connect the control signal receiving end of sine value storer 9 and the control signal receiving end of cosine value storer 10 respectively.
Initialization module 1 is used for angle η with input and is mapped to and becomes input angle θ in [0, pi/2]; It is disconnected also to be used to carry out anticipation; Judge that input angle θ whether smaller or equal to given critical angle β, is, then indirect assignment; Not, then will import angle θ converts equivalent integer into and sends to move to right N position module 2 and 1 module 3 simultaneously; Described input angle θ is standardizing number or the arithmetic number zero in the double-precision floating points; Numerical range is [0; 2), because the multiplier that FPGA provides only supports multiplication to calculate, in order to guarantee to call first multiplier 6 and second multiplier 7; Therefore just double-precision floating points converts equivalent integer into, thereby accelerates arithmetic speed.
Its transfer process: at first, read symbol, exponent and tail sign indicating number and the preservation of double-precision floating points, next, each the respective weights addition of tail sign indicating number is obtained weight and P, afterwards, calculate carry digit N and direction of displacement according to exponent, final, the integer of equivalence is p/2 NKeep behind the radix point 15, be about to floating number and take advantage of 1e+15, the every weight table of binary load is as shown in table 2:
Table 2 binary load tail sign indicating number weight table
The tail sign indicating number 52 51 50 49 ... 0
Weight 1e+15 5e+14 2.5e+14 1.25e+14 ... 0
Wherein, IEEE 754 standard codes the coding of binary storage of double-precision floating points, sign bit is that 1, exponent are that 11, tail sign indicating number are 52 in the double-precision floating points, totally 64, accounts for 2 continuous 32 words;
The N position module that moves to right 2,1 module 3, subtracter 4, totalizer 5, first multiplier 6, second multiplier 7 and 1 module 8 that moves to left are used for the equivalent integer and carry out interative computation N time;
The N position module 2 that moves to right is used for initial value sin=θ/2 of exporting the sine function iteration according to the equivalent integer that receives N, and the initial value of sine function iteration sent to sine value storer 9;
1 module 3 is used for exporting according to the equivalent integer that receives the initial value cos=1 of cosine function iteration, and the initial value of cosine function iteration is sent to cosine value storer 10;
Sine value storer 9; Be used to store the sine value that receives; And with this sine value as the sinusoidal input value of next iteration or final sinusoidal output valve; When receiving the control input signals of controller 11; The sine value that then will store sends subtracter 4, totalizer 5 and first multiplier 6 respectively as the sinusoidal input value of next iteration, and when receiving the control output signal of controller 11, the sine value that then will store converts double-precision floating points into as final sinusoidal output valve and outwards exports;
Cosine value storer 10; Be used to store the cosine value that receives; And with this cosine value as the cosine input value of next iteration or final cosine output valve; When receiving the control input signals of controller 11; The cosine value that then will store sends subtracter 4, totalizer 5 and first multiplier 6 respectively as the cosine input value of next iteration, and when receiving the control output signal of controller 11, the cosine value that then will store converts double-precision floating points into as final cosine output valve and outwards exports;
The whole-number result of sine value storer 9 and 10 pairs of outputs of cosine value storer is operated as follows and is converted into double-precision floating points output: at first, output result one is decided to be positive integer, sign bit S=0; Secondly, the N bit manipulation that moves to right (is for decimal number and takes advantage of 2 to the output result NOperation), the result is satisfied between 1e+15 to 2e+15, and storage move to right figure place N and R as a result; Finally, can get the exponent value according to the figure place N that moves to right; Can corresponding everybody value of tail sign indicating number of judged result R according to tail sign indicating number weight table 2.Calculate sin cos functions, its result keeps behind the radix point 15 between 0-1, can know that the output result (decimal representation) who utilizes the multiplier IP kernel to realize iterative algorithm is between 0-1e+15.
Subtracter 4 be used for the sine function and the cosine function value of input are poor cos-sin, and the difference that will obtain sends to second multiplier 7,
Totalizer 5 is used for sine function and the cosine function value of input are done and cos+sin, and will obtain and send to second multiplier 7,
First multiplier 6, sine function that is used to import and the cosine function value cos * sin that multiplies each other, and the product that obtains sent to 1 module 8 that moves to left,
Second multiplier 7 is used for the output valve of totalizer and the output valve of subtracter are multiplied each other (cos+sin) * (cos-sin), and the product that obtains sent to is cosine value storer 10;
1 module 8 that moves to left moves to left 1 with the output valve of first multiplier 6, accomplishes and takes advantage of operation 2 * cos * sin of 2, and its output valve sent to be sine value storer 9;
Table 3 is the corresponding relation of double-precision floating points, equivalent integer and corresponding binary format product thereof.Can find out that therefrom when calling multiplier and carrying out multiplying, the output figure place can double.During binary representation, the input of multiplier IP kernel is 128 at most, is output as 256.When binary representation, n figure place and n figure place multiply each other, and will import the 2n figure place.Iteration can be found several times: the scope that the output number of bits will can calculate above multiplier, iteration can not continue.Need after each multiplying, block the operation of figure place, just can guarantee the continuation of iteration.Can find out from table 3, for keep N position behind the radix point carry out iteration the time, block the figure place operation and be equivalent to the result of multiplier is removed 10 NOperation, and round.Describe to keep 2 significant digits below, maximum available 7 bits of integer double figures are represented, so select multiplier to be input as 27 bits, are output as 14 bits.Table 4 is depicted as everybody weight of output binary number; Decimal number 4300 (binary form is shown 01000011001100); Every weight addition of binary representation is got 43, and block coming to the same thing of figure place in the table 3, so solved the problem that the multiplying figure place doubles.
The corresponding relation of table 3 different data format product
Product The result Block figure place
Floating number 0.50×0.86 0.4300 0.43
The equivalence integer 50×86 4300 43
Scale-of-two 0110010×1010110 01000011001100 0101011
The every weight table of table 4 output binary number
The output scale-of-two is every 13 12 11 10 9 8 7 6 5…0
Weight 82 41 20 10 5 3 1 1 0
Controller 11; Be used for transmitting control signal to sine value storer 9 and cosine value storer 10; When second multiplier 7 or 1 module 8 that moves to left count down to N; Then stop interative computation and send control output signals to sine value storer 9 and cosine value storer 10 respectively, when second multiplier 7 or 1 module, 8 countings that move to left arrive N, then continue interative computation respectively to sine value storer 9 and cosine value storer 10 transmission control input signals.
Content of the present invention is not limited only to the content of above-mentioned each embodiment, and the combination of one of them or several embodiments equally also can realize the purpose of inventing.

Claims (1)

1. the sin cos functions IP kernel of reconfigurable satellite-borne computer is characterized in that it comprises initialization module (1), the N position module (2) that moves to right, l module (3), subtracter (4), totalizer (5), first multiplier (6), second multiplier (7), 1 module (8) that moves to left, sine value storer (9), cosine value storer (10) and controller (11); The input end of initialization module (1) is the angle η input end of the sin cos functions IP kernel of reconfigurable satellite-borne computer; Two output terminals of initialization module (1) connect the input end of the N position module (2) that moves to right and the input end of 1 module (3) respectively; The output terminal of 1 module (3) connects the first input end of cosine value storer (10); The output terminal of the N position module (2) that moves to right connects the first input end of sine value storer (9); The output terminal of cosine value storer (10) connects the first input end of subtracter (4), the first input end of totalizer (5) and the first input end of first multiplier (6) respectively; The output terminal of sine value storer (9) connects second input end of subtracter (4), second input end of totalizer (5) and second input end of first multiplier (6) respectively; The output terminal of subtracter (4) connects the first input end of second multiplier (7); The output terminal of totalizer (5) connects second input end of second multiplier (7); The output terminal of second multiplier (7) connects second input end of cosine value storer (10), and the output terminal of first multiplier (6) connects the input end of 1 module (8) that moves to left, and the output terminal of 1 module (8) that moves to left connects second input end of sine value storer (9); The 4th output terminal of sine value storer (9) is the sinusoidal output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer; The 4th output terminal of cosine value storer (10) is the cosine output terminal of the sin cos functions IP kernel of reconfigurable satellite-borne computer, and two signal controlling ends of controller (11) connect the control signal receiving end of sine value storer (9) and the control signal receiving end of cosine value storer (10) respectively
Initialization module (1) is used for angle η with input and is mapped to and becomes input angle θ in [0, pi/2]; It is disconnected also to be used to carry out anticipation; Judge that input angle θ whether smaller or equal to given critical angle β, is, then indirect assignment; Not, then will import angle θ converts equivalent integer into and sends to move to right N position module (2) and 1 module (3) simultaneously;
The N position module (2) that moves to right is used for initial value sin=θ/2 of exporting the sine function iteration according to the equivalent integer that receives N, and the initial value of sine function iteration sent to sine value storer (9);
1 module (3) is used for exporting according to the equivalent integer that receives the initial value cos=1 of cosine function iteration, and the initial value of cosine function iteration is sent to cosine value storer (10);
Sine value storer (9); Be used to store the sine value that receives; And with this sine value as the sinusoidal input value of next iteration or final sinusoidal output valve; When receiving the control input signals of controller (11); The sine value that then will store sends subtracter (4), totalizer (5) and first multiplier (6) respectively as the sinusoidal input value of next iteration, and when receiving the control output signal of controller (11), the sine value that then will store converts double-precision floating points into as final sinusoidal output valve and outwards exports;
Cosine value storer (10); Be used to store the cosine value that receives; And with this cosine value as the cosine input value of next iteration or final cosine output valve; When receiving the control input signals of controller (11); The cosine value that then will store sends subtracter (4), totalizer (5) and first multiplier (6) respectively as the cosine input value of next iteration, and when receiving the control output signal of controller (11), the cosine value that then will store converts double-precision floating points into as final cosine output valve and outwards exports;
Subtracter (4) be used for the sine function and the cosine function value of input are poor cos-sin, and the difference that will obtain sends to second multiplier (7),
Totalizer (5) is used for sine function and the cosine function value of input are done and cos+sin, and will obtain and send to second multiplier (7),
First multiplier (6), sine function that is used to import and the cosine function value cos * sin that multiplies each other, and the product that obtains sent to 1 module (8) that moves to left,
Second multiplier (7) is used for the output valve of totalizer and the output valve of subtracter are multiplied each other (cos+sin) * (cos-sin), and the product that obtains sent to is cosine value storer (10);
1 module (8) that moves to left moves to left 1 with the output valve of first multiplier (6), accomplishes and takes advantage of operation 2 * cos * sin of 2, and its output valve sent to be sine value storer (9);
Controller (11); Be used for transmitting control signal to sine value storer (9) and cosine value storer (10); When second multiplier (7) or move to left 1 module (8) when counting down to N; Then stop interative computation and send control output signal to sine value storer (9) and cosine value storer (10) respectively, when second multiplier (7) or 1 module (8) that moves to left counting arrive N, then continue interative computation respectively to sine value storer (9) and cosine value storer (10) transmission control input signals.
CN201110107337A 2011-04-27 2011-04-27 Sine-cosine function IP core capable of reconfiguring spaceborne computer Expired - Fee Related CN102156626B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110107337A CN102156626B (en) 2011-04-27 2011-04-27 Sine-cosine function IP core capable of reconfiguring spaceborne computer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110107337A CN102156626B (en) 2011-04-27 2011-04-27 Sine-cosine function IP core capable of reconfiguring spaceborne computer

Publications (2)

Publication Number Publication Date
CN102156626A CN102156626A (en) 2011-08-17
CN102156626B true CN102156626B (en) 2012-10-10

Family

ID=44438136

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110107337A Expired - Fee Related CN102156626B (en) 2011-04-27 2011-04-27 Sine-cosine function IP core capable of reconfiguring spaceborne computer

Country Status (1)

Country Link
CN (1) CN102156626B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107402743B (en) * 2017-07-24 2023-06-02 珠海泰为电子有限公司 Phase demodulation device and method based on CORDIC algorithm
CN108100308B (en) * 2017-12-07 2021-01-05 西北工业大学 Reconfigurable veneer skin satellite system
CN109190084B (en) * 2018-07-25 2022-10-11 中国航空工业集团公司西安飞行自动控制研究所 Hardware implementation method for sine and cosine calculation
CN112650973B (en) * 2019-10-11 2022-05-20 珠海格力电器股份有限公司 Trigonometric function calculation device and electronic equipment
CN117573069B (en) * 2023-11-23 2024-04-19 北京国科天迅科技股份有限公司 CORDIC algorithm chip

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1983103A (en) * 2006-06-15 2007-06-20 华为技术有限公司 Trigonometric value determiner, determining method and telecommunicating apparatus therewith
CN101493809A (en) * 2009-03-03 2009-07-29 哈尔滨工业大学 Multi-core onboard spacecraft computer based on FPGA

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8200728B2 (en) * 2008-05-29 2012-06-12 Harris Corporation Sine/cosine generator

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1983103A (en) * 2006-06-15 2007-06-20 华为技术有限公司 Trigonometric value determiner, determining method and telecommunicating apparatus therewith
CN101493809A (en) * 2009-03-03 2009-07-29 哈尔滨工业大学 Multi-core onboard spacecraft computer based on FPGA

Also Published As

Publication number Publication date
CN102156626A (en) 2011-08-17

Similar Documents

Publication Publication Date Title
CN102156626B (en) Sine-cosine function IP core capable of reconfiguring spaceborne computer
CN108780492B (en) Analog coprocessor
CN109062540A (en) A kind of restructural floating-point operation device based on cordic algorithm
CN110705703B (en) Sparse neural network processor based on systolic array
CN106155627B (en) Low overhead iteration trigonometric device based on T_CORDIC algorithm
CN102073472A (en) Trigonometric function CORDIC iteration operation coprocessor and operation processing method thereof
WO2020176248A1 (en) Neural network layer processing with scaled quantization
CN110187866B (en) Hyperbolic CORDIC-based logarithmic multiplication computing system and method
CN102096844A (en) FPGA-based RBF function calculation module
CN108228136A (en) The method and device that logarithmic function based on optimization loop up table calculates
CN110222305A (en) A kind of logarithmic function computing system and method based on hyperbolic CORDIC
CN111061992A (en) Function fitting method and device based on parabola
CN104536720A (en) Method and system for measuring and calculating trigonometric function value of to-be-measured angle based on FPGA
CN107423026A (en) The implementation method and device that a kind of sin cos functionses calculate
CN103049716B (en) First moment-based convolver
CN107657078B (en) Ultrasonic phased array floating point focusing transmission implementation method based on FPGA
CN102789446A (en) DDS (Direct Digital Synthesizer) signal spurious suppression method and system on basis of CORDIC (Coordinated Rotation Digital Computer) algorithm
CN105302520A (en) Reciprocal operation solving method and system
CN103365826A (en) Small-area radical-3 FFT (Fast Fourier Transform) butterfly-shaped unit
US20210064976A1 (en) Neural network circuitry having floating point format with asymmetric range
CN102073471B (en) Method and circuit for Cordic (Coordinate Rotation Digital Computer) iterative operation of processor
WO2020008643A1 (en) Data processing device, data processing circuit, and data processing method
CN110738311A (en) LSTM network acceleration method based on high-level synthesis
CN107203491A (en) A kind of triangle systolic array architecture QR decomposers for FPGA
EP4345600A1 (en) Multiplication hardware block with adaptive fidelity control system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C17 Cessation of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20121010

Termination date: 20130427