JPH0448253B2 - - Google Patents

Info

Publication number
JPH0448253B2
JPH0448253B2 JP61103653A JP10365386A JPH0448253B2 JP H0448253 B2 JPH0448253 B2 JP H0448253B2 JP 61103653 A JP61103653 A JP 61103653A JP 10365386 A JP10365386 A JP 10365386A JP H0448253 B2 JPH0448253 B2 JP H0448253B2
Authority
JP
Japan
Prior art keywords
data
output
bit
multiplication
value
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 - Lifetime
Application number
JP61103653A
Other languages
Japanese (ja)
Other versions
JPS62260227A (en
Inventor
Toshifumi Kunimoto
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.)
Yamaha Corp
Original Assignee
Yamaha Corp
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 Yamaha Corp filed Critical Yamaha Corp
Priority to JP61103653A priority Critical patent/JPS62260227A/en
Priority to US07/047,034 priority patent/US4831576A/en
Publication of JPS62260227A publication Critical patent/JPS62260227A/en
Publication of JPH0448253B2 publication Critical patent/JPH0448253B2/ja
Granted legal-status Critical Current

Links

Description

【発明の詳細な説明】 〔産業上の利用分野〕 この発明は乗算回路に関し、例えば、乗算出力
が乗算回路の入力側のフイードバツクされて繰り
返し演算されるようなデイジタルフイルタや電子
楽器のエンベロープ波形発生回路残響効果装置等
に適用し得るものである。
[Detailed Description of the Invention] [Industrial Application Field] The present invention relates to a multiplication circuit, and is used, for example, to generate envelope waveforms for digital filters and electronic musical instruments in which the multiplication output is fed back to the input side of the multiplication circuit and is repeatedly calculated. This can be applied to circuit reverberation effect devices, etc.

〔発明の概要〕[Summary of the invention]

この発明は、乗算回路において、入力データに
乗算データを乗算して得られた積データのうち上
位ビツトデータに対して、下位ビツトデータの値
に対応する確率で発生する1加算制御信号を加算
して乗算出力データとするようにすることによ
り、誤差の小さい所定ビツト数の乗算出力データ
を得るようにしたものである。
In the present invention, in a multiplication circuit, a 1 addition control signal, which is generated with a probability corresponding to the value of the lower bit data, is added to the upper bit data of the product data obtained by multiplying the input data by the multiplication data. By setting the multiplication output data as the multiplication output data, multiplication output data of a predetermined number of bits with a small error can be obtained.

〔従来の技術〕[Conventional technology]

従来、例えば、2次のIIR(infinite impulse
response)フイルタ、ラテイスフイルタ等のデイ
ジタルフイルタや、電子楽器のエンベロープ発生
回路、残響効果装置等には、乗算回路が使用され
ている。
Conventionally, for example, second-order IIR (infinite impulse
Multiplication circuits are used in digital filters such as response) filters and latex filters, envelope generation circuits for electronic musical instruments, reverberation effect devices, and the like.

このような装置においては、乗算回路からの乗
算結果を示す積データがデータ処理回路を示して
データ処理された後、当該乗算回路の乗算入力デ
ータとしてフイードバツクされるようになされ、
かくして乗算回路を用いて繰り返し演算を実行す
る。そのため、繰り返し演算によつて積データが
発散することを防止するように、入力データに対
して乗算する乗算データを「1」より小さく選定
している。
In such a device, product data indicating a multiplication result from a multiplication circuit is processed by a data processing circuit, and then fed back as multiplication input data to the multiplication circuit,
In this way, the multiplication circuit is used to perform repeated operations. Therefore, in order to prevent the product data from diverging due to repeated calculations, the multiplication data to be multiplied by the input data is selected to be smaller than "1".

従つて、例えば、Mビツトの整数部データでな
る入力データに対してNビツトの小数部データで
なる乗算データを乗算回路において乗算したと
き、乗算結果として、整数部がMビツトであつて
全体が最大M+Nビツトの積データMULが得ら
れる。
Therefore, for example, when input data consisting of M-bit integer part data is multiplied by multiplication data consisting of N-bit fractional part data in a multiplication circuit, the result of the multiplication is that the integer part is M bits and the whole is Product data MUL of maximum M+N bits can be obtained.

ところで、上述したような乗算回路を用いて、
電子楽器のエンベロープ波形を表す波形信号を発
生する方法として、第8図に示すような関数信号
発生回路が提案されている(特公昭57−39434号
公報)。
By the way, using the multiplication circuit as described above,
As a method of generating a waveform signal representing an envelope waveform of an electronic musical instrument, a function signal generating circuit as shown in FIG. 8 has been proposed (Japanese Patent Publication No. 39434/1983).

この関数信号発生回路は、シフトレジスタ1の
出力端に得られる現在値データSbを、減算器2に
フイードバツクして目標値データSaから減算し、
その減算出力D1に対して乗算器3において数値
1以下の値(例えば2-8)をもつ微小係数データ
Scを乗算する。かくして乗算器3の出力端に得ら
れるデータD2は、目標値データSaと現在値デー
タSbとの差に対応する大きさをもつ微小値データ
になる。
This function signal generation circuit feeds back the current value data S b obtained at the output end of the shift register 1 to the subtracter 2 and subtracts it from the target value data S a .
Minimal coefficient data having a value of 1 or less (for example, 2 -8 ) in the multiplier 3 for the subtracted output D 1
Multiply by S c . Thus, the data D 2 obtained at the output end of the multiplier 3 becomes minute value data having a size corresponding to the difference between the target value data S a and the current value data S b .

この微小値データD2は、ゲート回路4を介し
てクロツク信号CKのタイミングで加算器5に一
方の加算入力として与えられる。加算器5には、
現在値データSbが他方の加算入力として与えられ
ており、かくして加算器5の出力端に現在値デー
タSbに微小値データD2をクロツク信号CKのタイ
ミングで加算して行くことによつて時間の経過に
従つて微小値データD2の分だけ増大又は減少し
て行く加算出力D3が得られ、この加算出力D3
シフトレジスタ1に新たな現在値データとして入
力される。
This minute value data D2 is applied to the adder 5 as one addition input via the gate circuit 4 at the timing of the clock signal CK. Adder 5 has
The current value data S b is given as the other addition input, and by adding the minute value data D 2 to the current value data S b at the output terminal of the adder 5 at the timing of the clock signal CK. An addition output D 3 is obtained that increases or decreases by the minute value data D 2 as time passes, and this addition output D 3 is input to the shift register 1 as new current value data.

第8図の構成において、シフトレジスタ1は遅
延回路として動作し、その遅延時間が経過するご
とに新たな現在値データSbが減算器2に送出され
ることにより、目標値データSaと現在値データSb
との差に対応する微小値データD2が繰り返し現
在値データSbに加算される。かくして第9図又は
第10図に示すように、時間の経過に従つて目標
値Saに近づいて行くように増大し又は減少して行
くような立上り波形又は立下り波形を表す関数信
号を発生することができる。
In the configuration shown in FIG. 8, the shift register 1 operates as a delay circuit, and each time the delay time elapses, new current value data S b is sent to the subtracter 2, so that the target value data S a and the current value Value data S b
The minute value data D 2 corresponding to the difference between the two values is repeatedly added to the current value data S b . In this way, as shown in FIG. 9 or FIG. 10, a function signal representing a rising or falling waveform that increases or decreases as time approaches the target value S a is generated. can do.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

ところがこの構成の関数信号発生回路は、現在
値データSbが目標値データSaに近づいて、乗算器
3の乗算結果が非常に小さな値になつて、微小値
データD2の値が加算器5の演算可能な最小値以
下になつたときには、加算器5がこれを切り捨て
てしまうために、これが誤差となつて、現在値デ
ータSbが目標値データSaに到達できなくなる。
However, in the function signal generation circuit with this configuration, as the current value data S b approaches the target value data S a , the multiplication result of the multiplier 3 becomes a very small value, and the value of the minute value data D 2 becomes the value of the adder. 5, the adder 5 discards this value, which becomes an error, and the current value data S b cannot reach the target value data S a .

実際上、加算器5が加算動作を行い得る加算入
力データの値(これを便宜上整数値とする)が制
限されていると考えれば、小数点以下の値(すな
わち小数)をもつ加算入力については加算動作を
なし得ず、結局乗算器3の出力である微小値デー
タD2が小数点以下の値であれば、切り捨てられ
る結果になる。
In practice, if we consider that the value of the addition input data (which is assumed to be an integer value for convenience) on which the adder 5 can perform the addition operation is limited, the addition input data having a value below the decimal point (i.e., a decimal number) cannot be added. If the micro value data D 2 which is the output of the multiplier 3 is a value below the decimal point, it will be truncated.

そのため、第9図、第10図に示すように、現
在値Sbが目標値に近づくと微小値データD2が加
算器5に加算できなくなることにより、関数信号
に誤差ΔE1,ΔE2が残るおそれがある。
Therefore, as shown in FIGS. 9 and 10, when the current value S b approaches the target value, the minute value data D 2 cannot be added to the adder 5, and errors ΔE 1 and ΔE 2 are generated in the function signal. There is a risk that it will remain.

要するに、乗算器3の乗算結果の下位ビツト
(小数部のデータ)が切り捨てられ上位ビツト
(整数部のデータ)だけが次段の加算回路5にお
いて乗算出力データとして利用されることにな
る。
In short, the lower bits (data in the decimal part) of the multiplication result of the multiplier 3 are discarded, and only the upper bits (data in the integer part) are used as multiplication output data in the adder circuit 5 at the next stage.

そこで、小数部のデータを切り捨てる場合に、
四捨五入して切り捨てるようにすることが考えら
れる。しかし、2進化されたデータを四捨五入し
ようとすると、その構成は非常に複雑になる。
Therefore, if you want to truncate the decimal part of the data,
It may be possible to round off the value to the nearest whole number. However, if you try to round off the binary coded data, the structure becomes very complicated.

この発明は以上の点を考慮してなされたもの
で、乗算結果の下位ビツトを切り捨て残りの上位
ビツトを実質的な乗算出力データとして使用する
場合において、この乗算出力データが有する誤差
をできるだけ小さく抑えることのできる乗算回路
を提供しようとするものである。
This invention was made in consideration of the above points, and when the lower bits of the multiplication result are rounded down and the remaining upper bits are used as the actual multiplication output data, the error in the multiplication output data is kept as small as possible. The purpose of this paper is to provide a multiplication circuit that can perform the following functions.

〔問題点を解決するための手段〕[Means for solving problems]

かかる問題点を解決するためこの発明において
は、第11図において原理的構成として示すよう
に入力データS1に乗数データS2を乗算する乗算手
段MULと、乗算手段MULから出力される積デー
タS3のうち所定ビツト数の下位ビツトデータS4
値に対応する確率で1加算制御信号S6を発生する
桁上げ制御手段CARと、積データS3のうちの上
位ビツトデータS5と1加算制御信号S6とを加算す
る加算手段ADDとを具え、加算手段ADDにおけ
る加算値を乗算出力データS7とするようにする。
In order to solve this problem , in the present invention, as shown in the principle configuration in FIG . A carry control means CAR generates a 1 addition control signal S6 with a probability corresponding to the value of lower bit data S4 of a predetermined number of bits out of 3 , and adds 1 to upper bit data S5 of product data S3 . and an addition means ADD for adding the control signal S6 , and the added value in the addition means ADD is made to be the multiplication output data S7 .

〔作用〕[Effect]

第11図において、桁上げ制御手段CARは、
乗算手段MULの積データS3のうち、小数部デー
タS4の値に対応する確率で論理「1」レベルに立
ち上がるような1加算制御信号S6を発生する。一
般に小数値は、1に対する割合(例えば百分率)
を表していることから小数値は整数値の「1」に
なる確率を表している。従つて、小数部データS4
はこれを繰り返し加算したとき整数値「1」にな
るまでに要する時間を表しており、小数部データ
S4の数値が小さければ確率は小さくなることによ
り、小数部データS4を繰り返し加算したとき整数
値「1」になるまでの時間は長くなる。これに対
して小数部データS4の値が大きければ、小数部デ
ータS4を繰り返し加算したとき整数値「1」にな
るまでの時間は短くなる。
In FIG. 11, the carry control means CAR is
A 1 addition control signal S6 is generated that rises to the logic "1" level with a probability corresponding to the value of the decimal part data S4 of the product data S3 of the multiplication means MUL. Generally, a decimal value is a ratio of 1 (e.g. a percentage)
Therefore, the decimal value represents the probability that the integer value is "1". Therefore, the fractional data S 4
represents the time required to reach the integer value "1" when this is repeatedly added, and the decimal part data
If the value of S 4 is small, the probability becomes small, and therefore, when the decimal part data S 4 is repeatedly added, it takes a long time to reach the integer value "1". On the other hand, if the value of the decimal part data S 4 is large, the time until the integer value "1" is reached when the decimal part data S 4 is repeatedly added becomes shorter.

かくして、加算手段ADDに1加算制御信号S6
が与えられる頻度は、小数部データS4の数値に対
応することになり、これにより加算手段ADDで
は、整数部データS5に、小数部データS4に基づく
1加算制御信号S6による「+1」加算された値の
出力データS7が得られる。
Thus, the 1 addition control signal S 6 is applied to the addition means ADD.
The frequency at which is given corresponds to the numerical value of the decimal part data S4 , and as a result, the addition means ADD adds "+1" to the integer part data S5 by the 1 addition control signal S6 based on the decimal part data S4 . ” Output data S7 of the added value is obtained.

これにより、乗算手段MULの乗算結果の整数
部には小数部の値に対応する確率で「+1」加算
され、その結果、整数部を選択した乗算出力デー
タS7の期待値は乗算結果を実質的に等しくなり、
小数部を切り捨てたことによる誤差を小さくする
ことができる。
As a result, "+1" is added to the integer part of the multiplication result of the multiplication means MUL with a probability corresponding to the value of the decimal part, and as a result, the expected value of the multiplication output data S7 which selected the integer part is the multiplication result. is equal to
Errors caused by truncating the decimal part can be reduced.

〔実施例〕〔Example〕

以下図面と共に、この発明を、例えば電子楽器
のエンベロープ信号形成回路等に用いられる関数
信号発生回路に適用した場合の実施例について詳
述する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment in which the present invention is applied to a function signal generation circuit used, for example, in an envelope signal formation circuit of an electronic musical instrument will be described in detail with reference to the drawings.

第1図において、11は全体として関数信号発
生回路を示し、加算器12(第11図の加算手段
ADDに対応する)の出力端に得られる例えば8
ビツトのパラレルデータでなる現在値データSPRX
が関数信号発生回路11の出力SOUTとして送出さ
れると共に、遅延回路13を介して減算器14の
減算入力端にフイードバツクされる。
In FIG. 1, 11 indicates the function signal generation circuit as a whole, and an adder 12 (adding means in FIG. 11)
For example 8 obtained at the output end of (corresponding to ADD)
Current value data S PRX consisting of bit parallel data
is sent out as the output S OUT of the function signal generation circuit 11, and is also fed back to the subtraction input terminal of the subtracter 14 via the delay circuit 13.

減算器14は、この現在値データSPRを8ビツ
トのパラレルデータでなる目標値データSTAから
減算し、この出力端に得られる8ビツトのパラレ
ルデータでなる減算出力データSSBを乗算器15
(第11図の乗算手段MULに対応する)に送出す
る。
The subtracter 14 subtracts this current value data SPR from the target value data STA consisting of 8-bit parallel data, and the subtracted output data SSB consisting of 8-bit parallel data obtained at the output terminal is sent to the multiplier 15.
(corresponding to the multiplication means MUL in FIG. 11).

乗算器15は減算出力データSSBに対して8ビ
ツトのパラレルデータでなる微小係数データSMI
を乗算して、16ビツトのパラレルデータでなる積
データSMUを送出する。
The multiplier 15 outputs minute coefficient data SMI , which is 8-bit parallel data, to the subtracted output data SSB .
The product data SMU consisting of 16-bit parallel data is sent out.

ここで微小係数データSMIは、減算出力データ
SSBに対して1以下の値、例えば2-8の微小係数を
乗算して、8ビツトの整数部データSITと、8ビ
ツトの小数部データSDCとでなる16ビツトの積デ
ータSMUを送出する。
Here, the minute coefficient data S MI is the subtracted output data
S SB is multiplied by a value less than 1, for example, a minute coefficient of 2 - 8 , to produce 16-bit product data S MU consisting of 8-bit integer part data S IT and 8-bit decimal part data S DC . Send out.

この積データSMUのうち、整数部データSITは加
算器12の第1の加算入力として与えられ、遅延
回路13の出力端に得られる現在値データSPR
加算され、その加算結果SPRXが遅延回路13を介
して新たな現在値データSPRとして送出される。
Of the product data S MU , the integer part data S IT is given as the first addition input of the adder 12, and is added to the current value data S PR obtained at the output terminal of the delay circuit 13, and the addition result S PRX is sent out via the delay circuit 13 as new current value data S PR .

これに対して積データSMUのうち、小数部デー
タSDCが桁上げ制御回路16(第11図の桁上げ
制御手段CARに対応する)に与えられると共に、
この桁上げ制御回路16の出力端に得られる1加
算制御信号SCRが加算器12のキヤリー入力端CI
に与えられる。
On the other hand, the decimal part data S DC of the product data S MU is given to the carry control circuit 16 (corresponding to the carry control means CAR in FIG. 11), and
The 1 addition control signal SCR obtained at the output terminal of this carry control circuit 16 is applied to the carry input terminal CI of the adder 12.
given to.

桁上げ制御回路16は、第2図に示すように、
小数部データSDCを構成する8ビツトを構成する
8ビツトのデータa0〜a7を端子T00〜T07に受け
て、対応するアンド回路AD0〜AD7に入力する。
The carry control circuit 16, as shown in FIG.
8-bit data a0 to a7 constituting the 8 bits constituting the decimal part data SDC are received at terminals T00 to T07 and input to corresponding AND circuits AD0 to AD7 .

これに加えて桁上げ制御回路16は、確率発生
回路21を有し、小数部データSDCの各ビツトの
データa0〜a7に対応する8つの確率出力b0〜b7
なる確率出力データSPROを発生し、各確率出力デ
ータb0〜b7を対応するアンド回路AD0〜AD7に入
力する。
In addition, the carry control circuit 16 has a probability generation circuit 21, which generates probability outputs consisting of eight probability outputs b0 to b7 corresponding to each bit of data a0 to a7 of the fractional part data SDC . Data S PRO is generated and each probability output data b 0 to b 7 is input to the corresponding AND circuits AD 0 to AD 7 .

アンド回路AD0〜AD7の出力は、オア回路OR1
を通じて1加算制御信号SCRとして送出される。
The output of AND circuit AD 0 to AD 7 is OR circuit OR 1
It is sent as the 1 addition control signal SCR through

ここで確率出力データb0〜b7は、8ビツトの2
進数20〜27を表すパルス出力でなり、時間の経過
に従つて、小数部データSDCの対応するビツトデ
ータa0〜a7の重み付けに対応する確率で論理
「1」レベルに立ち上がるようなデータでなり、
第3図〜第5図に示すように構成された確率発生
回路21によつてそれぞれ形成される。
Here, the probability output data b 0 to b 7 are 2 bits of 8 bits.
It is a pulse output representing a base number 20 to 27 , and rises to the logic "1" level with a probability corresponding to the weighting of the corresponding bit data a0 to a7 of the decimal part data S DC as time passes. The data is
Each of them is formed by a probability generation circuit 21 configured as shown in FIGS. 3 to 5.

確率発生回路21は、第3図に示すように、8
ビツトカウンタ25、優先選択エンコーダ26、
デコーダ27を有する。8ビツトカウンタ25は
所定周期のクロツク信号φをカウントし、その2
進出力SBINを優先選択エンコーダ26の入力端に
出力する。
As shown in FIG. 3, the probability generation circuit 21 has 8
bit counter 25, priority selection encoder 26,
It has a decoder 27. The 8-bit counter 25 counts the clock signal φ of a predetermined period, and
The output power S BIN is output to the input terminal of the priority selection encoder 26.

優先選択エンコーダ26は、第4図に示すよう
に、8ビツトのカウント出力SBINを入力端子T40
〜T47に受けて、インバータIN11〜IN14、アンド
回路AD11〜AD15、オア回路OR11〜OR13で構成
される論理回路によつて、第5図の優先選択エン
コーダ26の欄に示すように、入力端子T40
T47のうち、下位ビツト側から見て最初に論理
「1」となつている端子番号を優先的に選択して
対応する出力端子T50〜T52に所定の2進コード
のエンコード出力SPREを送出する。
The priority selection encoder 26 inputs the 8-bit count output S BIN to the input terminal T 40 as shown in FIG.
~ T47 , a logic circuit consisting of inverters IN11 ~ IN14 , AND circuits AD11 ~ AD15 , and OR circuits OR11 ~ OR13 sets the priority selection encoder 26 in FIG. As shown, input terminal T 40 ~
Out of T47 , the terminal number whose logic is "1" first when viewed from the lower bit side is selected preferentially, and a predetermined binary code is encoded and output S PRE to the corresponding output terminals T50 to T52 . Send out.

このようにすれば、8ビツトカウンタ25の第
0ビツトの出力端子T30、第1ビツトの出力端子
T31、第2ビツトの出力端子T32……第7ビツト
の出力端子T37が論理「1」レベルになり、かつ
その下位ビツトが論理「0」になる状態が発生す
る確率は、順次1/21=1/2、1/22=1/
4、1/23=1/8……1/28=1/256となる。
In this way, the output terminal T 30 of the 0th bit of the 8-bit counter 25 and the output terminal of the 1st bit
T 31 , the output terminal T 32 of the second bit...the output terminal T 37 of the seventh bit are at the logic "1" level, and the probability that the lower bit thereof is at the logic "0" level is sequentially 1 /2 1 = 1/2, 1/2 2 = 1/
4. 1/2 3 = 1/8...1/2 8 = 1/256.

なお、この実施例の場合、優先選択エンコーダ
26は、第7番目のビツトについて、論理「1」
及び「0」になる確率1/128を確率出力として
出力し得るようになされている。
In this embodiment, the priority selection encoder 26 sets the logic "1" to the seventh bit.
It is possible to output a probability output of 1/128 as a probability output of "0".

このことは、所定の演算時間TREFとして例えば
128個のクロツクパルスが到来する時間を基準に
考えると、優先選択エンコーダ26の出力端子
T52,T51,T50に論理「111」の出力が得られる
タイミングは当該所定の演算時間TREFの1/2の
時間の間であり、従つて当該演算時間TREFの間に
64回論理「111」の出力が得られることになる。
This means that for a given computation time T REF , for example
Based on the arrival time of 128 clock pulses, the output terminal of the priority selection encoder 26
The timing at which the output of logic "111" is obtained at T 52 , T 51 , and T 50 is during 1/2 of the predetermined calculation time T REF , and therefore, during the calculation time T REF .
The output of logic "111" will be obtained 64 times.

同様にして優先選択エンコーダ26の出力端子
T52,T51,T50に論理「110」,「101」……
「001」,「000」が得られるタイミングは、順次
1/4の時間(32個のパルスに相当する)、1/
8の時間(16個のパルスに相当する)……1/
128の時間(1個のパルスに相当する)、1/128
の時間(1個のパルスに相当する)の確率になる
ことを意味しており、かくして確率1/2,1/
4,1/8……1/128,1/128を表すデータ
を、優先選択エンコーダ26の出力端子T52
T51,T50から送出されるエンコード出力SPREによ
つて得ることができることになる。
Similarly, the output terminal of the priority selection encoder 26
Logic "110", "101" for T 52 , T 51 , T 50 ...
The timing at which "001" and "000" are obtained is sequentially 1/4 time (corresponding to 32 pulses), 1/4 time
8 time (equivalent to 16 pulses)...1/
128 times (equivalent to 1 pulse), 1/128
(corresponding to one pulse), thus the probability is 1/2, 1/
4, 1/8...Data representing 1/128, 1/128 is sent to the output terminal T 52 of the priority selection encoder 26,
This can be obtained by the encoded output SPRE sent from T 51 and T 50 .

デコーダ27は、このエンコード出力SPREを受
けて、エンコード出力SPREのコードに対応して出
力端子T70〜T77のうちの1つの論理「1」レベ
ルのデータを出力する。かくしてデコーダ27の
出力端子T77,T76,T75……T71,T70が論理
「1」になる確率は、それぞれ1/2,1/4,
1/8……1/128,1/128になる。
The decoder 27 receives the encoded output SPRE and outputs logic "1" level data from one of the output terminals T70 to T77 in accordance with the code of the encoded output SPRE . Thus, the probabilities that the output terminals T 77 , T 76 , T 75 ...T 71 , T 70 of the decoder 27 become logic "1" are 1/2, 1/4, and 1/4, respectively.
1/8...1/128, 1/128.

このことは、デコーダ27の出力端子T77
T76,T75……T71,T70が論理「1」になる周期
は、端子T77の周期を基準にして21倍、22倍……
27倍、27倍になることを表している。
This means that the output terminals T 77 of the decoder 27,
T 76 , T 75 ...... The period at which T 71 and T 70 become logic "1" is 2 1 times, 2 2 times ... based on the period of terminal T 77 .
It means that it will increase 27 times, 27 times.

このデコーダ27の出力端子T77,T76,T75
…T71,T70に得られる確率出力は、確率発生回
路21の確率出力データSPROとしてそれぞれアン
ド回路AD0,AD1,AD2……AD7に送出され(第
2図)、そのアンド出力がオア回路OR1を通じて
1加算制御信号SCRとして桁上げ制御回路16か
ら加算器12に送出される。
Output terminals T 77 , T 76 , T 75 ... of this decoder 27
...The probability outputs obtained at T 71 and T 70 are sent to the AND circuits AD 0 , AD 1 , AD 2 ...AD 7 (Fig. 2) as probability output data S PRO of the probability generation circuit 21, respectively (Fig. 2), and The output is sent from the carry control circuit 16 to the adder 12 as a 1 addition control signal SCR through the OR circuit OR1 .

以上の構成において、第6図の時点t0において
関数信号発生回路11が演算動作を開始すると、
減算器14は整数でなる目標値データSTAを減算
出力データSSBとして乗算器15に送出し、乗算
器15はこの減算出力データSSBに対して8ビツ
トの微小係数データSMIを乗算する。
In the above configuration, when the function signal generation circuit 11 starts the calculation operation at time t 0 in FIG.
The subtracter 14 sends the target value data STA , which is an integer, to the multiplier 15 as subtraction output data SSB , and the multiplier 15 multiplies the subtraction output data SSB by 8-bit minute coefficient data SMI . .

その結果、乗算器15の出力端には、上位8ビ
ツトの整数部データSITと、下位8ビツトの小数
部データSDCでなる16ビツトの積データSMUが得ら
れ、整数部データSITが加算器12において現在
値データSPRに加算されると共に、小数部データ
SDCが桁上げ制御回路16において1加算制御信
号SCRに変換処理される。
As a result, 16-bit product data S MU consisting of the upper 8 bits of integer part data S IT and the lower 8 bits of decimal part data S DC is obtained at the output terminal of the multiplier 15, and the integer part data S IT is added to the current value data S PR in the adder 12, and the decimal part data
The carry control circuit 16 converts S DC into a 1 addition control signal S CR .

ここで、桁上げ制御回路16は、小数部データ
SDCを構成する8ビツトのデータa0〜a7(第2図)
のうち、論理「1」レベルにあるデータを、対応
するアンド回路AD0〜AD7の第1の入力条件とし
て与えることにより、確率発生回路21の確率出
力データSPROを構成する確率出力b0〜b7の対応す
るデータを抽出してオア回路OR1を介して1加算
制御信号SCRとして送出する。
Here, the carry control circuit 16 controls the decimal part data.
8-bit data a0 to a7 that make up S DC (Figure 2)
Among them, by giving data at the logic "1" level as the first input condition of the corresponding AND circuits AD 0 to AD 7 , the probability output b 0 constituting the probability output data S PRO of the probability generation circuit 21 is generated. The data corresponding to ~ b7 is extracted and sent as the 1 addition control signal SCR via the OR circuit OR1.

例えば、小数部データSDCの8ビツトのデータ
a7〜a0が「01000010」であつたとすると、第6ビ
ツトのデータa6、及び第1ビツトのデータa1が論
理「1」になり、かつ他の第7ビツト、第5〜第
2ビツト、第0ビツトのデータa7,a5〜a2,a0
論理「0」になつているので、論理「1」になつ
ているデータa6及びa1に対応するアンド回路AD6
及びAD1から、確率出力b6及びb1だけが抽出され
て1加算制御信号SCRとして送出される。
For example, 8-bit data of decimal part data S DC
Assuming that a 7 to a 0 are "01000010", the data a 6 of the 6th bit and the data a 1 of the 1st bit become logic "1", and the other 7th bit, 5th to 2nd bit Since the data a 7 , a 5 to a 2 , a 0 of the 0th bit are logic "0", the AND circuit AD 6 corresponds to the data a 6 and a 1 which are logic "1".
and AD 1 , only the probability outputs b 6 and b 1 are extracted and sent as the 1-addition control signal S CR .

ところで、第6ビツト及び第1ビツトの確率出
力b6及びb1は、それぞれ1/4及び1/128の確
率を持つており(第5図)、このことは、確率出
力b6が論理「1」になる周期が4クロツク周期で
あるのに対して、第1ビツトの確率出力b1が論理
「1」になる周期は128クロツク周期であることを
表している。この結果1加算制御信号SCRが論理
「1」になることによつて加算器12が「+1」
加算動作することによつて整数部データSIT
「+1」加算をするタイミングは、小数部データ
SDCのうち第6ビツトのデータa6について4個の
クロツクパルスごとに発生すると共に、第1ビツ
トのデータa1について128個のクロツクパルスご
とに発生する。
By the way, the probability outputs b 6 and b 1 of the 6th bit and the 1st bit have probabilities of 1/4 and 1/128, respectively (Figure 5), which means that the probability output b 6 is logical This means that the period at which the probability output b1 of the first bit becomes logic "1" is 4 clock cycles, while the period at which the probability output b1 of the first bit becomes logic "1" is 128 clock cycles. As a result, the 1 addition control signal S CR becomes logic "1", and the adder 12 becomes "+1".
The timing of adding “+1” to the integer part data S IT by adding operation is the decimal part data.
S DC occurs every 4 clock pulses for the 6th bit of data a 6 and every 128 clock pulses for the 1st bit of data a 1 .

かくして加算器12は、積データSMUのうち、
8ビツトの整数部データSITに対して、同様に8
ビツトの整数部データでなる現在値データSPR
加算することによつて、8ビツトの新たな現在値
データSPRを得ることができる。これと同時に、
8ビツトの整数部データSITに対して、小数部デ
ータSDCの値に対応する確率に対応する周期ごと
に整数値「1」を内容とする1加算制御信号SCR
を送出する。
In this way, the adder 12 selects the product data SMU from the product data SMU.
Similarly, for 8-bit integer part data S IT , 8
By adding the current value data S PR consisting of bit integer part data, new 8-bit current value data S PR can be obtained. At the same time,
For the 8-bit integer part data S IT , a 1 addition control signal S CR whose content is an integer value "1" is generated for each period corresponding to the probability corresponding to the value of the decimal part data S DC .
Send out.

かくして加算器12は、整数部データSITに小
数部データSDCの値に対応する確率で「+1」加
算をすることにより、小数部データの値を考慮し
た加算出力SPRXを得ることができることになる。
In this way, the adder 12 can obtain the addition output S PRX in consideration of the value of the decimal part data by adding "+1" to the integer part data S IT with a probability corresponding to the value of the decimal part data S DC . become.

かかる結果を得るにつき、加算器12として
は、整数部データSITと同じビツト数すなわち8
ビツトの加算回路で構成すれば良く、かくして加
算器12の構成を複雑にしないようにし得る。
To obtain such a result, the adder 12 uses the same number of bits as the integer part data S IT , that is, 8 bits.
It is sufficient to configure the adder 12 with a bit adding circuit, thus making it possible to avoid complicating the configuration of the adder 12.

実験によれば、第7図に示すように、従来の場
合の関数信号KOは目標値STAに対して誤差が残
るが、この発明によれば、符号K1で示すように、
誤差が残らない関数信号を発生することができ
た。
According to experiments, as shown in FIG. 7, the function signal KO in the conventional case has an error with respect to the target value STA , but according to the present invention, as shown by the symbol K1,
We were able to generate a function signal with no residual error.

なお、上述の実施例においては、関数信号出力
SOUTを演算する際に、パラレルデータを用いてパ
ラレル演算するようにした場合について述べた
が、これに代え、シリアルデータを用いてシリア
ル演算するようにしても上述の場合と同様の効果
を得ることができる。
In addition, in the above embodiment, the function signal output
When calculating S OUT , we have described the case where parallel calculations are performed using parallel data, but instead of this, the same effect as in the above case can be obtained by performing serial calculations using serial data. be able to.

また、上述の実施例においては、一系列分の関
数信号SOUTを得るようにした実施例について述べ
たが、例えば複数の楽音にそれぞれ異なるエンベ
ロープを付与する場合のように、複数系列の関数
信号を必要とする場合には、各系列の関数信号の
演算を時分割的に実行するようにすれば良い。
In addition, in the above embodiment, an example was described in which one series of function signals S OUT is obtained, but for example, when assigning different envelopes to multiple musical tones, multiple series of function signals S OUT are obtained. If necessary, the calculation of the function signal of each series may be performed in a time-sharing manner.

また、上述の実施例においては、この発明を繰
り返し演算を実行する電子楽器のエンベロープ信
号形成回路等に用いられる関数発生回路に適用す
る場合について述べたが、これに限らず例えば繰
り返し演算を実行するデイジタルフイルタや電子
楽器の残響効果等のように、乗算結果の上位ビツ
トを実質的な乗算出力データとして使用するよう
にした各種回路に広く適用することができる。
Further, in the above-described embodiment, the present invention is applied to a function generating circuit used in an envelope signal forming circuit of an electronic musical instrument that performs repeated calculations, but the present invention is not limited to this, for example. The present invention can be widely applied to various circuits that use the upper bits of the multiplication result as actual multiplication output data, such as digital filters and reverberation effects of electronic musical instruments.

〔発明の効果〕〔Effect of the invention〕

以上のようにこの発明によれば、乗算出力デー
タとして送出する場合に捨て去られる下位ビツト
の情報を、その内容に対応して確率的に決まる1
加算信号として乗算出力データに含めようにした
ので、乗算出力データが有する誤差を小さくする
ことのできる乗算回路を容易に得ることができ
る。
As described above, according to the present invention, the lower bit information that is discarded when the multiplication output data is sent out is changed to
Since it is included in the multiplication output data as an addition signal, it is possible to easily obtain a multiplication circuit that can reduce errors in the multiplication output data.

【図面の簡単な説明】[Brief explanation of drawings]

第1図はこの発明による乗算回路の一実施例を
適用した関数信号発生回路を示す接続部、第2図
〜第5図はその桁上げ制御回路16の詳細構成を
示す接続図及び図表、第6図は第1図の動作の説
明に供する特性曲線図、第7図は実験結果を示す
特性曲線図、第8図は従来の関数信号発生回路を
示す接続図、第9図及び第10図はその問題点の
説明に供する特性曲線図、第11図はこの発明の
原理的構成を示すブロツク図である。 11……関数信号発生回路、12……加算器、
13……遅延回路、14……減算器、15……乗
算器、16……桁上げ制御回路。
FIG. 1 shows a connection section of a function signal generation circuit to which an embodiment of the multiplication circuit according to the present invention is applied; FIGS. 2 to 5 are connection diagrams and charts showing the detailed configuration of the carry control circuit 16; Fig. 6 is a characteristic curve diagram for explaining the operation of Fig. 1, Fig. 7 is a characteristic curve diagram showing experimental results, Fig. 8 is a connection diagram showing a conventional function signal generation circuit, and Figs. 9 and 10. 11 is a characteristic curve diagram for explaining the problem, and FIG. 11 is a block diagram showing the basic structure of the present invention. 11...Function signal generation circuit, 12...Adder,
13... Delay circuit, 14... Subtractor, 15... Multiplier, 16... Carry control circuit.

Claims (1)

【特許請求の範囲】 1 入力データに乗数データを乗算する乗算手段
と、 上記乗算手段から出力される積データのうち所
定ビツト数の下位ビツトデータの値に対応する確
率で1加算制御信号を発生する桁上げ制御手段
と、 上記積データのうちの上位ビツトデータと上記
1加算制御信号とを加算する加算手段と を具え、上記加算手段における加算値を乗算出力
データとするようにしたことを特徴とする乗算回
路。
[Claims] 1. Multiplying means for multiplying input data by multiplier data, and generating a 1 addition control signal with a probability corresponding to the value of lower bit data of a predetermined number of bits of the product data output from the multiplication means. and an addition means for adding the upper bit data of the product data and the 1 addition control signal, and the added value in the addition means is used as multiplication output data. A multiplication circuit.
JP61103653A 1986-05-06 1986-05-06 Multiplication circuit Granted JPS62260227A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP61103653A JPS62260227A (en) 1986-05-06 1986-05-06 Multiplication circuit
US07/047,034 US4831576A (en) 1986-05-06 1987-05-04 Multiplier circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP61103653A JPS62260227A (en) 1986-05-06 1986-05-06 Multiplication circuit

Publications (2)

Publication Number Publication Date
JPS62260227A JPS62260227A (en) 1987-11-12
JPH0448253B2 true JPH0448253B2 (en) 1992-08-06

Family

ID=14359737

Family Applications (1)

Application Number Title Priority Date Filing Date
JP61103653A Granted JPS62260227A (en) 1986-05-06 1986-05-06 Multiplication circuit

Country Status (1)

Country Link
JP (1) JPS62260227A (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH03200294A (en) * 1989-12-28 1991-09-02 Yamaha Corp Musical sound synthesizer

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS54104248A (en) * 1978-02-03 1979-08-16 Hitachi Ltd Digital arithmetic control method
JPS5625824A (en) * 1979-08-10 1981-03-12 Mitsubishi Electric Corp Digital-analog converter
JPS57197650A (en) * 1981-05-29 1982-12-03 Toshiba Corp Operation circuit
JPS5949640A (en) * 1982-09-16 1984-03-22 Toshiba Corp Multiplying circuit

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS54104248A (en) * 1978-02-03 1979-08-16 Hitachi Ltd Digital arithmetic control method
JPS5625824A (en) * 1979-08-10 1981-03-12 Mitsubishi Electric Corp Digital-analog converter
JPS57197650A (en) * 1981-05-29 1982-12-03 Toshiba Corp Operation circuit
JPS5949640A (en) * 1982-09-16 1984-03-22 Toshiba Corp Multiplying circuit

Also Published As

Publication number Publication date
JPS62260227A (en) 1987-11-12

Similar Documents

Publication Publication Date Title
EP0238300B1 (en) Serial digital signal processing circuitry
US6745219B1 (en) Arithmetic unit using stochastic data processing
US4023454A (en) Tone source apparatus for an electronic musical instrument
JPH0448253B2 (en)
GB2236924A (en) Pulse width modulation circuit
US4831576A (en) Multiplier circuit
JPS6328368B2 (en)
JPS6359570B2 (en)
US6680683B2 (en) Waveform shaping circuit
JP3258938B2 (en) Decimation filter
JP2699358B2 (en) Decoder circuit
JPS6059776B2 (en) pulse width modulation circuit
JP4315783B2 (en) Single-bit ΔΣ modulation arithmetic circuit
JPH07120964B2 (en) Extension circuit
JP2550597B2 (en) Squarer
JPH0744459B2 (en) PWM circuit
JPS6213120Y2 (en)
JPS6318366B2 (en)
JP3041932B2 (en) Sample rate conversion circuit
JPH039661B2 (en)
JPH0567959B2 (en)
JPH0451857B2 (en)
JP2956373B2 (en) Arithmetic circuit
JPH0621820A (en) Sign magnitude outputting device
JPH0331015B2 (en)

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees