JP2011204148A - Settlement-order determining system, method and program - Google Patents
Settlement-order determining system, method and program Download PDFInfo
- Publication number
- JP2011204148A JP2011204148A JP2010073068A JP2010073068A JP2011204148A JP 2011204148 A JP2011204148 A JP 2011204148A JP 2010073068 A JP2010073068 A JP 2010073068A JP 2010073068 A JP2010073068 A JP 2010073068A JP 2011204148 A JP2011204148 A JP 2011204148A
- Authority
- JP
- Japan
- Prior art keywords
- transaction
- settlement
- order
- settlement order
- trial
- 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.)
- Pending
Links
Images
Abstract
Description
本発明は、決済順序確定システム、方法及びプログラムに関し、特に、債券等の複数の取引を連続して決済する場合に決済可能な決済順序を確定する決済順序確定システム、方法及びプログラムに関する。 The present invention relates to a settlement order determination system, method, and program, and more particularly, to a settlement order determination system, method, and program for determining a settlement order that can be settled when a plurality of transactions such as bonds are settled continuously.
近年、債券等のペーパーレス化に伴い、物理的な券面を発行せず、所定の機関において保有者、銘柄名及び額面等の管理が行われるようになった。そして、これらの管理が情報システム化されることにより、取引後の受渡し決済時に券面の移動を伴わないため、省力化やコストの軽減が図れるようになった。 In recent years, with the paperlessness of bonds, etc., management of holders, brand names, face values, etc. has been carried out at a predetermined institution without issuing physical bill faces. And, since these managements are made into an information system, it is possible to save labor and reduce costs because the ticket face does not move at the time of settlement after delivery.
特許文献1には、同一銘柄で異額面の債券取引におけるネッティング決済を可能とするネッティング決済システムに関する技術が開示されている。特許文献1にかかるネッティング決済システムは、二者による債券取引に関する取引関連データを入力する取引関連データ入力手順と、入力された取引関連データの中から同一銘柄の受け渡しの組合せを抽出する同一銘柄受け渡し抽出手順と、抽出された受け渡しの組合せの中から相殺すべき受け渡しの組合せたる相殺組合せを抽出する相殺抽出手順と、抽出された相殺組合せを決済演算可能な決済演算手順と、決済演算された結果を決済明細として出力する決済明細出力手順とを備える。特に、前記相殺抽出手順は、異額面の債券の受け渡しの組合せを含む相殺組合せを抽出可能とする。
債券等の取引の中には、所定期間内に請求された複数の取引の請求を所定の期日又は時間に一括して決済を行うものがある。例えば、日中であれば取引の請求毎に即時に決済が行われるが、夜間に取引をまとめて受け付けて、翌朝までに決済を行う場合などである。ここで、債券等の取引の決済は、取引元の口座から取引先の口座へ金融商品の取引額を移動させることである。そして、取引額に比べて取引元の口座に債券等の残高が不足している場合は、決済を行うことができない。また、複数の取引の決済を一括して行う場合、ある取引における決済により口座の残高が変更することに伴い、他の取引の決済の可否が影響を受ける場合がある。つまり、決済の順序により、取引における決済の可否の結果が異なる場合がある。そのため、ある口座が複数の取引に関係している場合、これらの取引をまとめて取引グループとして扱うことが必要である。そして、複数の取引の決済を一括して行う場合、取引グループに含まれる複数の取引について所定の決済順序により直列に決済を行い、取引グループ内の全ての取引が決済可能である場合に、当該取引グループについて、一括して決済が可能と判断することができる。 Some transactions of bonds, etc., collectively settle a plurality of transactions charged within a predetermined period on a predetermined date or time. For example, in the case of daytime, payment is made immediately every time a transaction is charged, but in the case where transactions are accepted at night and payment is made by the next morning. Here, settlement of transactions such as bonds is to move the transaction amount of the financial product from the account of the transaction source to the account of the transaction destination. If the balance of bonds, etc. is insufficient in the transaction source account compared to the transaction amount, settlement cannot be performed. Further, when settlement of a plurality of transactions is performed at once, the availability of settlement of other transactions may be affected as the account balance changes due to settlement in a certain transaction. That is, depending on the order of settlement, the result of whether or not settlement is possible in the transaction may differ. Therefore, when an account is related to a plurality of transactions, it is necessary to treat these transactions together as a transaction group. And when settlement of multiple transactions is performed in a lump, when a plurality of transactions included in a transaction group are settled in series in a predetermined settlement order and all transactions in the transaction group can be settled, It can be determined that the transaction group can be settled together.
例えば、取引グループに含まれる複数の取引について、決済順序の組み合わせを総当たりで試行することにより、決済可能な決済順序を検出することも可能である。この場合、取引グループに含まれる取引数に伴う計算量の増加が著しい。債券等における取引の請求は、一時期に集中する傾向があり、取引額は数千億円にのぼる場合もある。また、取引グループ内の取引の関係は複雑であるため、決済可能な決済順序を検出するには、複雑な処理を必要とし、時間がかかるという問題がある。 For example, for a plurality of transactions included in a transaction group, it is possible to detect a settlement order that can be settled by trying combinations of settlement orders with brute force. In this case, the increase in the amount of calculations accompanying the number of transactions included in the transaction group is significant. Bills for transactions in bonds, etc. tend to be concentrated at one time, and the amount of transactions can amount to several hundred billion yen. In addition, since the relationship of transactions within a transaction group is complicated, there is a problem that it takes time to detect a settlement order that can be settled and it takes time.
ここで、債券等における大部分の取引グループにおける取引の関係には、様々なパターンが存在するが、大部分の取引グループについては、単純なパターンが多く含まれ、複雑なパターンが全体に占める割合は少ないという特徴がある。 Here, there are various patterns in the relationship of transactions in most transaction groups such as bonds, but most of the transaction groups include many simple patterns and the ratio of complex patterns to the total There are few features.
本発明は、このような問題を解決するためになされたものであり、複数の取引を連続して決済する場合に、決済可能な決済順序について、少ない試行回数により効率的に確定するための決済順序確定システム、方法及びプログラムを提供することを目的とする。 The present invention has been made to solve such a problem, and in the case where a plurality of transactions are successively settled, a settlement for efficiently confirming a settlement order that can be settled with a small number of trials. An object is to provide an order determination system, method and program.
本発明の第1の態様にかかる決済順序確定システムは、取引グループに含まれるL(Lは、3以上の整数)個の取引における決済可能な決済順序を確定する決済順序確定システムであって、前記取引に関わる口座の残高情報を記憶する残高情報記憶部(例えば、本発明の実施の形態1にかかる口座情報記憶部32)と、前記取引グループに含まれる各取引における決済順序を記憶する決済順序記憶部(例えば、本発明の実施の形態1にかかる取引情報記憶部33)と、前記取引における前記決済順序を確定する処理を制御する制御部と、を備え、前記制御部は、前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整手段と、前記第1の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定手段と、を備え、前記第1の決済順序調整手段は、前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行手段と、前記取引決済試行手段による試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高情報更新手段と、Nが1からLまでの間、前記取引決済試行手段による処理及び前記残高情報更新手段による処理を繰り返し実行する第1の繰り返し実行手段と、前記第1の繰り返し実行手段による実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新手段と、前記決済順序更新手段による更新後に、NがM+1からLまでの間、前記取引決済試行手段による処理及び前記残高情報更新手段による処理を繰り返し実行する第2の繰り返し実行手段と、を含む。
The settlement order confirmation system according to the first aspect of the present invention is a settlement order confirmation system for confirming a settlement order that can be settled in L (L is an integer of 3 or more) transactions included in a transaction group, A balance information storage unit (for example, the account
また、前記確定手段により前記決済順序が決済可能な順序として確定されなかった場合に、前記残高情報記憶部及び前記決済順序記憶部を参照し、前記取引グループに含まれる全ての取引の決済が確定したと仮定した場合の口座当たりの残高を算出し、算出された残高が所定値以下となる口座について、残高が所定値となる取引額を加算して前記残高情報記憶部に格納された残高情報を補正する残高情報補正手段と、前記残高情報補正手段により補正された残高情報を用いて、前記決済順序記憶部に格納された決済順序に基づき、前記第1の決済順序調整手段により前記試行が失敗した全ての取引についての決済を試行することにより前記決済順序を調整する第2の決済順序調整手段と、をさらに備え、前記確定手段は、前記第2の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、前記第1の決済順序調整手段により前記試行が成功した最後の取引の決済順序までを決済可能な順序としてさらに確定することが望ましい。 In addition, when the settlement order is not confirmed as an order that can be settled by the confirmation unit, the settlement of all transactions included in the transaction group is confirmed with reference to the balance information storage unit and the settlement order storage unit. The balance information stored in the balance information storage unit is calculated by calculating the balance per account in the case where it is assumed that the calculated balance is equal to or less than a predetermined value and adding the transaction amount where the balance is a predetermined value. Using the balance information corrected by the balance information correction means, and the balance information corrected by the balance information correction means, based on the payment order stored in the payment order storage unit, the trial is adjusted by the first payment order adjustment means. Second settlement order adjustment means for adjusting the settlement order by trying settlement for all failed transactions, and the confirmation means includes the second settlement order. When the settlement of all transactions included in the transaction group succeeds due to the settlement order adjusted by the adjustment unit, the settlement sequence of the last transaction for which the trial was successful by the first settlement order adjustment unit. It is desirable to further determine the order in which settlement is possible.
また、前記確定手段により前記決済順序が決済可能な順序として確定されなかった場合に、前記取引グループに含まれる各取引から、取引元の口座が当該取引グループ内の他の取引の取引先の口座と一致しない取引である始点取引と、取引先の口座が当該取引グループ内の他の取引の取引元の口座と一致しない取引である終点取引とを選択する端点取引選択手段と、前記始点取引における決済順序を、最初の順序として前記決済順序記憶部を更新し、当該始点取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、前記終点取引における決済順序を、最後の順序として前記決済順序記憶部を更新する端点取引処理手段と、前記端点取引処理手段により更新された決済順序に基づき、前記取引グループの内、前記始点取引及び前記終点取引を除いた取引についての決済を試行することにより前記決済順序を調整する第3の決済順序調整手段と、をさらに備え、前記確定手段は、前記第3の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、前記決済順序記憶部に格納された決済順序を決済可能な順序として確定することが望ましい。 Further, when the settlement order is not confirmed as the order in which the settlement can be made by the confirmation unit, the account of the transaction source is the account of the other business partner in the transaction group from each transaction included in the transaction group. An end point transaction selecting means for selecting a start point transaction that is a transaction that does not match the transaction and an end point transaction that is a transaction in which the account of the customer does not match the account of the other transaction source in the transaction group; Update the settlement order storage unit with the settlement order as the first order, update the balance information stored in the balance information storage unit on the assumption that the settlement of the starting transaction has been confirmed, and settle the settlement order in the end point transaction , Based on the settlement order updated by the endpoint transaction processing means, the endpoint transaction processing means for updating the settlement order storage unit as the last order, And third settlement order adjustment means for adjusting the settlement order by trying settlement for transactions excluding point transactions and end-point transactions, and the confirmation means includes the third settlement order adjustment means. It is desirable that the settlement order stored in the settlement order storage unit is determined as an order that can be settled when the settlement trials of all the transactions included in the transaction group are successful by the settlement order adjusted by the above.
さらに、前記第3の決済順序調整手段により試行が失敗した取引に含まれる口座から、自己が前記取引先の口座となる取引が存在し、かつ、自己が前記取引元の口座となる取引が2以上存在する口座を選択する起点口座選択手段と、前記起点口座選択手段により選択された口座が前記取引元の口座となる取引である2以上の起点取引の決済順序における先後関係を入れ替えて前記決済順序記憶部を更新する起点取引処理手段と、をさらに備え、前記第3の決済順序調整手段は、前記起点取引処理手段により更新された決済順序に基づき、前記取引グループの内、前記始点取引及び前記終点取引を除いた取引についての決済を試行することにより前記決済順序を調整することが望ましい。 Further, there is a transaction in which the self is the account of the customer from the accounts included in the transaction for which the trial has failed by the third settlement order adjustment means, and there are 2 transactions in which the self is the account of the transaction source. The settlement by selecting the origin account selection means for selecting the existing account, and the settlement relationship in the settlement order of two or more origin transactions that are transactions in which the account selected by the origin account selection means is the account of the transaction source Starting transaction processing means for updating the order storage unit, wherein the third settlement order adjustment means is based on the settlement order updated by the origin transaction processing means, and the starting transaction and It is desirable to adjust the settlement order by trying to settle a transaction excluding the end point transaction.
また、前記確定手段は、前記第3の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、前記第1の決済順序調整手段により前記試行が成功した最後の取引の決済順序までを決済可能な順序として確定するとよい。 In addition, when the settlement attempt of all the transactions included in the transaction group is successful by the settlement order adjusted by the third settlement order adjustment unit, the determination unit performs the first settlement order adjustment unit. It is preferable that the settlement order of the last transaction for which the trial has been successful is determined as the order in which settlement is possible.
さらに、取引元の口座から取引先の口座へ所定額を決済するための複数の取引を外部から受け付け、受け付けた複数の取引の中から、前記取引先の口座又は前記取引元の口座の少なくとも一方の口座が他の取引と共通する取引を選択し、選択した取引の集合を前記取引グループとして生成する取引グループ生成手段をさらに備え、前記第1の決済順序調整手段は、前記取引グループ生成手段により生成された取引グループに対して、前記決済順序を調整するとよい。 Further, a plurality of transactions for settlement of a predetermined amount from a trading partner account to a trading partner account are accepted from the outside, and at least one of the trading partner account or the trading partner account from among the plurality of accepted transactions A transaction group generating unit that selects a transaction that is common to other transactions and generates a set of the selected transactions as the transaction group, and the first settlement order adjustment unit includes: The settlement order may be adjusted for the generated transaction group.
さらに、前記残高情報補正手段は、前記取引が券種及び枚数により定まる債券における取引である場合に、前記取引グループに含まれる口座の残高における債券の券種及び枚数に基づき、前記口座当たりの残高を算出するとよい。 Further, the balance information correction means, when the transaction is a transaction on a bond determined by a ticket type and the number of sheets, based on the bond type and number of bonds in the account balance included in the transaction group, the balance per account Should be calculated.
本発明の第2の態様にかかる決済順序確定方法は、取引に関わる口座の残高情報を記憶する残高情報記憶部(例えば、本発明の実施の形態1にかかる口座情報記憶部32)と、取引グループに含まれるL(Lは、3以上の整数)個の取引における決済順序を記憶する決済順序記憶部(例えば、本発明の実施の形態1にかかる取引情報記憶部33)と、前記取引における前記決済順序を確定する処理を制御する制御部と、を備えるコンピュータにおける前記取引グループに含まれる各取引における決済可能な決済順序を確定する処理を制御するための決済順序確定方法であって、前記制御部において、前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整ステップと、前記第1の決済順序調整ステップにより調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定ステップと、を含み、前記第1の決済順序調整ステップは、前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行ステップと、前記取引決済試行ステップによる試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高更新ステップと、Nが1からLまでの間、前記取引決済試行ステップ及び前記残高更新ステップを繰り返し実行する第1の繰り返し実行ステップと、前記第1の繰り返し実行ステップによる実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新ステップと、前記決済順序更新ステップによる更新後に、NがM+1からLまでの間、前記取引決済試行ステップ及び前記残高更新ステップを繰り返し実行する第2の繰り返し実行ステップと、を含む。
The settlement order confirmation method according to the second aspect of the present invention includes a balance information storage unit (for example, the account
本発明の第3の態様にかかる決済順序確定プログラムは、取引に関わる口座の残高情報を記憶する残高情報記憶部(例えば、本発明の実施の形態1にかかる口座情報記憶部32)と、取引グループに含まれるL(Lは、3以上の整数)個の取引における決済順序を記憶する決済順序記憶部(例えば、本発明の実施の形態1にかかる取引情報記憶部33)と、前記取引における前記決済順序を確定する処理を制御する制御部と、を備えるコンピュータに、前記取引グループに含まれる各取引における決済可能な決済順序を確定する処理を実行させる決済順序確定プログラムであって、前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整処理と、前記第1の決済順序調整処理により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定処理と、を含み、前記第1の決済順序調整処理は、前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行処理と、前記取引決済試行処理による試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高更新処理と、Nが1からLまでの間、前記取引決済試行処理及び前記残高更新処理を繰り返し実行する第1の繰り返し実行処理と、前記第1の繰り返し実行処理による実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新処理と、前記決済順序更新処理による更新後に、NがM+1からLまでの間、前記取引決済試行処理及び前記残高更新処理を繰り返し実行する第2の繰り返し実行処理と、を含む。
The settlement order determination program according to the third aspect of the present invention includes a balance information storage unit (for example, the account
本発明によれば、複数の取引を連続して決済する場合に、決済可能な決済順序について、少ない試行回数により効率的に確定するための決済順序確定システム、方法及びプログラムを提供することができる。 According to the present invention, it is possible to provide a settlement order determination system, method, and program for efficiently determining a settlement order that can be settled with a small number of trials when a plurality of transactions are settled continuously. .
以下では、本発明を適用した具体的な実施の形態について、図面を参照しながら詳細に説明する。各図面において、同一要素には同一の符号が付されており、説明の明確化のため、必要に応じて重複説明は省略する。 Hereinafter, specific embodiments to which the present invention is applied will be described in detail with reference to the drawings. In the drawings, the same elements are denoted by the same reference numerals, and redundant description will be omitted as necessary for the sake of clarity.
<発明の実施の形態1>
図1は、本発明の実施の形態1にかかる決済順序確定システム3を含む全体構成を示すブロック図である。決済順序確定システム3は、ネットワーク2を介して、端末1a、1b、・・・1nと接続され、端末1a、1b、・・・1nから送信される複数の取引の請求を受け付け、所定期間内に受け付けた複数の取引について決済可能な決済順序を確定する決済順序確定処理を行う情報システムである。また、決済順序確定システム3は、決済が不可能な取引については、その旨を通知する。ここで、取引とは、取引元の口座から取引先の口座へ金融商品の取引額の移動又は債券等の権利の移転を定義したものとする。そして、取引の決済とは、取引額の移動又は債券等の権利の移転を実行することとする。また、決済順序とは、複数の取引について、取引の決済を実行する順序を示すものとする。
<
FIG. 1 is a block diagram showing an overall configuration including a settlement
決済順序確定システム3は、汎用的なコンピュータシステムであり、取引における決済順序を確定する処理を制御する制御部31と、口座情報記憶部32と、取引情報記憶部33とを少なくとも備える。口座情報記憶部32は、口座ID321と、残高情報322とを関連付けて記憶する記憶装置である。ここでは、口座ID321は、取引に関わる口座を識別する情報である。また、残高情報322は、取引に関わる口座の取引可能な金額情報又は債券額である。尚、口座情報記憶部32は、言い換えると、取引に関わる口座の残高情報322を記憶する残高情報記憶部といえる。
The settlement
ここで、図2は、本発明の実施の形態1にかかる口座情報の例を示す図である。図2では、30個の口座IDについてそれぞれ残高情報が関連付けられていることを示す。
Here, FIG. 2 is a figure which shows the example of the account
図1に戻り、取引情報記憶部33は、グループID331と、取引ID332と、取引元口座ID333と、取引先口座ID334と、取引額335と、決済順序336とを記憶する記憶装置である。グループID331は、取引グループを識別する情報である。ここで、取引グループは、取引先の口座又は取引元の口座の少なくとも一方の口座が他の取引と共通する取引の集合である。取引ID332は、取引を識別する情報である。取引元口座ID333は、口座ID321の内、取引における取引元の口座IDである。取引先口座ID334は、口座ID321の内、取引における取引先の口座IDである。取引額335は、取引において決済される金額情報又は債券額である。決済順序336は、取引の決済を実行する順序を示す情報である。例えば、決済順序336は、数値で表現される番号情報であり、番号の昇順又は降順に実行されるものとする。尚、決済順序336は、開始の番号は、任意であり、番号は連続している必要はない。また、決済順序336は、少なくとも取引グループ内で一意に順序が定まるものとする。または、決済順序336は、当該取引の直前又は直後に決済を実行する取引ID332であってもよい。尚、取引情報記憶部33は、言い換えると、取引グループに含まれる各取引における決済順序を記憶する決済順序記憶部といえる。また、取引は、取引ID332、取引元口座ID333、取引先口座ID334、取引額335及び決済順序336の組み合わせで表現される。そして、一つのグループID331には、複数の取引ID332が関連付けられている。
Returning to FIG. 1, the transaction
ここで、図3は、本発明の実施の形態1にかかる取引情報の例を示す図である。図3では、図2の口座が取引元又は取引先の口座となった28個の取引IDについて取引元口座ID、取引先口座ID、取引額及び決済順序が関連付けられていることを示し、各取引IDは、6個のグループIDのいずれかに関連付けられていることを示す。
Here, FIG. 3 is a figure which shows the example of the transaction
図1に戻り、端末1a、1b、・・・1nは、キーボードやマウス等の入力装置(不図示)と、画面等の表示装置(不図示)と通信機能を備える端末装置である。そして、端末1a、1b、・・・1nは、ネットワーク2を介して、任意のタイミングで取引に関する情報を決済順序確定システム3へ送信する。また、ネットワーク2は、インターネット、公衆網、専用線及び移動体通信網等の通信ネットワークである。
Returning to FIG. 1, the
尚、口座情報記憶部32及び取引情報記憶部33は、ハードディスクドライブ、フラッシュメモリ等の不揮発性の記憶装置であることが望ましい。
The account
図4は、本発明の実施の形態1にかかる決済順序確定システム3の機能ブロック図である。決済順序確定システム3は、取引グループに含まれるL(Lは、3以上の整数)個の取引における決済可能な決済順序を確定する情報システムである。決済順序確定システム3は、取引グループ生成手段340と、取引グループ決済試行手段350と、残高情報補正手段360と、擬似ループ判定手段370と、確定手段380とを備える。
FIG. 4 is a functional block diagram of the settlement
取引グループ生成手段340は、端末1a、1b、・・・1nからネットワーク2を介して、複数の取引を外部から受け付け、受け付けた複数の取引の中から、取引先の口座又は取引元の口座の少なくとも一方の口座が他の取引と共通する取引を選択し、選択した取引の集合を取引グループとして生成する。これにより、大量の取引について複数の取引グループに分けて効率的に決済順序を確定することができる。尚、このとき、取引グループ生成手段340は、取引グループ内の各取引について決済順序を初期設定するとよい。
The transaction group generation means 340 accepts a plurality of transactions from the outside via the
取引グループ決済試行手段350は、取引情報記憶部33に格納された決済順序336に基づき、取引グループに含まれる取引の決済を試行することにより決済順序を調整する。つまり、取引グループ決済試行手段350は、取引グループ生成手段340により生成された取引グループに対して設定された決済順序を調整する。尚、取引グループは、取引グループ生成手段340により生成されたものの代わりに、予め定められたものを対象としてもよい。また、取引グループ決済試行手段350は、取引決済試行手段351と、残高情報更新手段352と、繰り返し実行手段353と、決済順序更新手段354とを備える。
The transaction group settlement trial means 350 adjusts the settlement order by trying settlement of transactions included in the transaction group based on the
取引決済試行手段351は、口座情報記憶部32及び取引情報記憶部33を参照し、決済順序336がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する。残高情報更新手段352は、取引決済試行手段351による試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して口座情報記憶部32に格納された残高情報322を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする。繰り返し実行手段353は、取引情報記憶部33に格納された決済順序336に従い、例えば、Nが1からLまでの間、取引決済試行手段351による処理及び残高情報更新手段352による処理を繰り返し実行する。
The transaction
決済順序更新手段354は、繰り返し実行手段353による実行の結果、試行が成功した取引における決済順序以前に、試行が失敗した取引が存在する場合、試行が失敗した全ての取引における決済順序が、試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように取引情報記憶部33を更新する。そして、繰り返し実行手段353は、決済順序更新手段354による更新後に、NがM+1からLまでの間、取引決済試行手段351による処理及び残高情報更新手段352による処理を繰り返し実行する。
As a result of the execution by the repeated execution means 353, the settlement
確定手段380は、取引グループ決済試行手段350により調整された決済順序により取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する。
The
このように、少なくとも上述した取引グループ決済試行手段350及び確定手段380を実行することにより、1巡目の試行では、初期設定された決済順序に基づき、各取引についての決済が試行され、試行が成功した取引の残高については、随時、決済後の残高に更新する。そして、更新後の残高を用いて以降の決済順序における取引が試行される。そして、1巡目の試行が終了した後に、試行が成功した取引及び試行が失敗した取引がそれぞれ存在し、かつ、最初の失敗以後に1以上の成功がある場合、言い換えると、最後の成功以前に1以上の失敗がある場合に、決済順序の更新及び2巡目の試行が行われる。決済順序更新手段354では、少なくとも試行が失敗した取引の決済順序を、試行が成功した全ての取引の決済順序より後の順序とする。
In this way, by executing at least the transaction group
そして、2巡目の試行では、試行が失敗した取引のみについて、更新した決済順序に基づき決済が試行される。このとき、1巡目における試行が成功した取引における口座の残高は更新されており、2巡目の開始時点の条件は1巡目の開始時点とは条件が異なるため、1巡目にて最後の成功以前に試行が失敗した取引については、2巡目において試行が成功する可能性がある。これにより、初期設定とは異なる決済順序により試行を行ったこととなる。また、2巡目においては、1巡目において試行が成功した取引については、再度の試行を行わないため、試行回数を減らすことができる。すなわち、異なる決済順序を少ない試行回数により実行することができる。これにより、決済順序を並べ替えるだけで決済可能な取引グループであるか否かについて効率的に判定し、決済可能な決済順序を確定することができる。 In the second round of trial, settlement is attempted only for the transaction for which the trial has failed based on the updated settlement order. At this time, the account balance in the transaction in which the trial in the first round was successful has been updated, and the conditions at the start of the second round are different from those at the start of the first round. For transactions that failed before the success of, the trial may be successful in the second round. As a result, the trial is performed in a settlement order different from the initial setting. Further, in the second round, since the transaction that has been successfully tried in the first round is not retried, the number of trials can be reduced. That is, different settlement orders can be executed with a small number of trials. Accordingly, it is possible to efficiently determine whether or not the transaction group can be settled only by rearranging the settlement order, and the settlement order in which settlement is possible can be determined.
また、残高情報補正手段360は、確定手段380により決済順序が決済可能な順序として確定されなかった場合に、口座情報記憶部32及び取引情報記憶部33を参照し、取引グループに含まれる全ての取引の決済が確定したと仮定した場合の口座当たりの残高を算出し、算出された残高が所定値以下となる口座について、残高が所定値となる取引額を加算して口座情報記憶部32に格納された残高情報322を補正する。そして、取引グループ決済試行手段350は、残高情報補正手段360により補正された残高情報を用いて、取引情報記憶部33に格納された決済順序336に基づき、取引グループ決済試行手段350により前回、試行が失敗した全ての取引についての決済を試行することにより決済順序を調整する。このとき、確定手段380は、取引グループ決済試行手段350により調整された決済順序により取引グループに含まれる全ての取引の決済の試行が成功する場合に、取引グループ決済試行手段350により試行が成功した最後の取引の決済順序までを決済可能な順序としてさらに確定する。
Further, the balance
ここで、取引グループが決済順序に関わらず、そもそも取引元の口座の初期残高が不足していたために決済不可能であったことを赤残連鎖取引と呼ぶ。上述した手段により、赤残連鎖取引について、初期残高の不足を解消した場合に決済可能な決済順序を確定することができる。また、初期残高が不足している口座を特定でき、当該口座の持ち主へ不足額の解消を依頼する通知をすることにより、初期残高の不足が解消した後、直ちに決済可能となるため、不要に取引を決済不可能とすることがなくなる。よって、決済可能な取引グループを検出する精度を高めることができる。 Here, regardless of the order of payment, regardless of the order of payment, the fact that the initial balance of the account of the transaction source was insufficient and the payment was not possible is called red balance chain transaction. By the means described above, the settlement order that can be settled when the shortage of the initial balance is resolved for the red balance chain transaction can be determined. In addition, it is possible to identify an account with a shortage of initial balance, and by notifying the owner of the account to resolve the shortage, it becomes possible to settle immediately after the shortage of the initial balance has been resolved, which is unnecessary. The transaction is no longer impossible to settle. Therefore, the precision which detects the transaction group which can be settled can be improved.
ここで、取引グループにおけるループ取引について説明する。ループ取引とは、複数の口座間で取引元の口座と取引先の口座とが入れ替わった取引を含む取引グループである。つまり、ループ取引とは、複数の口座間で循環する複数の取引を指す。特に、取引額が同額で循環する場合、当該ループ取引における口座の収支は過不足がない。そのため、残高情報補正手段360により初期残高の不足する口座を含む取引グループとして検出することはできない。しかし、上述したようにループ取引は口座の収支に過不足がないため、取引グループ内の初期設定の決済順序と異なる順序とすることで、決済可能となる場合もある。このようなループ取引を擬似ループ取引と呼ぶ。さらに、赤残連鎖取引であったために、初期設定の決済順序では決済可能とならなかったが、初期残高の不足を解消した上で、擬似ループ取引となる取引グループもある。このようなループ取引を、赤残連鎖取引かつ擬似ループ取引と呼ぶ。一方、ループ取引に関係する各口座のいずれにも初期残高が不足している場合には、決済順序に関わらず決済可能とはならない。このようなループ取引を真正ループ取引と呼ぶ。さらに、赤残連鎖取引であり、ループ取引以外の取引のための初期残高の不足を解消したとしても、真正ループ取引となる取引グループもある。このようなループ取引を、赤残連鎖取引かつ真正ループ取引と呼ぶ。
Here, the loop transaction in the transaction group will be described. A loop transaction is a transaction group including a transaction in which a trading source account and a trading partner account are exchanged between a plurality of accounts. That is, the loop transaction refers to a plurality of transactions that circulate between a plurality of accounts. In particular, when the transaction amount circulates at the same amount, the account balance in the loop transaction is not excessive or insufficient. For this reason, the balance
そこで、擬似ループ判定手段370は、取引グループ決済試行手段350における試行に失敗した取引が存在する場合、取引グループが擬似ループ取引となっているか否かを判定する。擬似ループ判定手段370は、端点取引選択手段371と、端点取引処理手段372と、起点口座選択手段373と、起点取引処理手段374とを備える。
Therefore, when there is a transaction that failed in the trial in the transaction group
端点取引選択手段371は、確定手段380により決済順序が決済可能な順序として確定されなかった場合に、取引グループに含まれる各取引から、取引元の口座が当該取引グループ内の他の取引の取引先の口座と一致しない取引である始点取引と、取引先の口座が当該取引グループ内の他の取引の取引元の口座と一致しない取引である終点取引とを選択する。端点取引処理手段372は、始点取引における決済順序を、最初の順序として取引情報記憶部33を更新し、当該始点取引の決済が確定したと仮定して口座情報記憶部32に格納された残高情報322を更新し、終点取引における決済順序を、最後の順序として取引情報記憶部33を更新する。
The end point
そして、擬似ループ判定手段370は、端点取引処理手段372により更新された決済順序に基づき、取引グループの内、始点取引及び終点取引を除いた取引についての決済を試行することにより決済順序を調整する。このとき、確定手段380は、取引グループ決済試行手段350により調整された決済順序により取引グループに含まれる全ての取引の決済の試行が成功する場合に、取引情報記憶部33に格納された決済順序336を決済可能な順序として確定する。これにより、擬似ループ取引を検出して決済可能な順序として確定することができる。よって、決済可能な取引グループを検出する精度を高めることができる。
Then, the pseudo
また、起点口座選択手段373は、擬似ループ判定手段370により試行が失敗した取引に含まれる口座から、自己が取引先の口座となる取引が存在し、かつ、自己が取引元の口座となる取引が2以上存在する口座を選択する。起点取引処理手段374は、起点口座選択手段373により選択された口座が取引元の口座となる取引である2以上の起点取引の決済順序における先後関係を入れ替えて取引情報記憶部33を更新する。そして、擬似ループ判定手段370は、起点取引処理手段374により更新された決済順序に基づき、取引グループの内、始点取引及び終点取引を除いた取引についての決済を試行することにより決済順序を調整する。このように、ループ取引における起点となりうる複数の起点取引を特定し、当該複数の起点取引の決済順序における先後関係を入れ替えることにより、試行に成功する場合があり、結果的に試行回数を減らし、効率的に決済順序を確定することができる。
In addition, the origin
さらに、確定手段380は、擬似ループ判定手段370により調整された決済順序により取引グループに含まれる全ての取引の決済の試行が成功する場合に、取引グループ決済試行手段350により試行が成功した最後の取引の決済順序までを決済可能な順序として確定するとよい。これにより、擬似ループ取引を検出して決済可能な順序として確定することができる。また、確定手段380は、擬似ループ判定手段370により調整された決済順序により試行が失敗した場合にも、取引グループ決済試行手段350により試行が成功した最後の取引の決済順序までを決済可能な順序として確定してもよい。これにより、赤残連鎖取引又は真正ループ取引であっても、決済可能な取引については決済順序を確定させることができる。逆に、決済不可能な取引を特定することができる。そのため、決済不可能な取引の原因を絞り込み、後処理を効率的に行うことができる。
Further, when the settlement attempt of all transactions included in the transaction group is successful by the settlement order adjusted by the pseudo
図5は、本発明の実施の形態1にかかる決済順序確定システム3のハードウェア構成を示すブロック図である。決済順序確定システム3は、CPU(Central Processing Unit)301と、RAM(Random Access Memory)302と、ROM(Read Only Memory)303と、通信部304と、ハードディスク305とを備える。また、ハードディスク305は、不揮発性記憶装置であり、OS(Operating System)306及び決済順序確定プログラム307が格納されている。尚、ハードディスク305は、口座情報記憶部32及び取引情報記憶部33をさらに含むものであってもよい。決済順序確定プログラム307は、本発明の実施の形態1にかかる決済順序確定処理が実装されたコンピュータプログラムである。
FIG. 5 is a block diagram showing a hardware configuration of the settlement
CPU301は、決済順序確定システム3における各種処理、RAM302、ROM303、通信部304及びハードディスク305へのアクセス等を制御する。通信部304は、口座情報記憶部32及び取引情報記憶部33並びにネットワーク2を介して端末1a、1b、・・・1nとの通信を行う。決済順序確定システム3は、CPU301が、RAM302、ROM303又はハードディスク305に格納されたOS306及び決済順序確定プログラム307を読み込み、実行する。これにより、決済順序確定システム3は、決済順序確定処理を実現することができる。尚、決済順序確定システム3は、複数台のコンピュータサーバに分散して実現されても構わない。
The
図6は、本発明の実施の形態1にかかる決済順序確定処理の流れを示すフローチャートである。まず、取引グループ生成手段340は、端末1a、1b、・・・1nから取引情報を受け付ける(S11)。具体的には、取引グループ生成手段340は、受け付けた取引情報に応じて取引ID332を発行し、取引情報に含まれる取引元口座ID333、取引先口座ID334及び取引額335に取引ID332を関連付けて取引情報記憶部33に格納する。次に、取引グループ生成手段340は、取引グループ生成処理を行う(S12)。尚、取引グループ生成処理の詳細は、図7を用いて後述する。
FIG. 6 is a flowchart showing a flow of settlement order determination processing according to the first embodiment of the present invention. First, the transaction group generation means 340 receives transaction information from the
そして、取引グループ決済試行手段350は、取引グループを選択する(S13)。具体的には、取引グループ決済試行手段350は、取引情報記憶部33を参照し、複数のグループID331の内、一つを選択する。その後、取引グループ決済試行手段350は、決済順序調整処理を行う(S14)。尚、決済順序調整処理の詳細は、図9を用いて後述する。引き続き、確定手段380は、決済順序を確定する確定処理を行う(S15)。尚、確定処理の詳細は、図18を用いて後述する。
Then, the transaction group settlement trial means 350 selects a transaction group (S13). Specifically, the transaction group settlement trial means 350 refers to the transaction
ここで、取引グループ決済試行手段350は、未選択の取引グループが存在するか否かを判定する(S16)。具体的には、取引グループ決済試行手段350は、取引情報記憶部33を参照し、グループID331の内、未選択のグループが存在するか否かを判定する。ステップS16において、未選択のグループが存在すると判定した場合、全ての取引グループが選択し終えるまでの間、ステップS13乃至S16を繰り返し実行する。ステップS16において、未選択のグループが存在しない、すなわち、全てのグループが選択済みであると判定した場合、決済順序確定システム3は、決済順序確定処理を終了する。
Here, the transaction group settlement trial means 350 determines whether or not an unselected transaction group exists (S16). Specifically, the transaction group
図7は、本発明の実施の形態1にかかる取引グループ生成処理の流れを示すフローチャートである。まず、取引グループ生成手段340は、取引情報を選択する(S21)。具体的には、取引グループ生成手段340は、取引情報記憶部33を参照し、複数の取引ID332の内、一つを選択する。次に、取引グループ生成手段340は、選択した取引情報に関連する取引情報が存在するか否かを判定する(S22)。具体的には、取引グループ生成手段340は、取引情報記憶部33を参照し、ステップS21において選択した取引ID332に関連付けられた取引元口座ID333及び取引先口座ID334を取得する。そして、取引グループ生成手段340は、取得した取引元口座ID333又は取引先口座ID334の口座IDを検索キーとして、取引情報記憶部33を検索する。そして、検索キーと一致する取引元口座ID333又は取引先口座ID334が関連付けられた取引ID332が存在するか否かを判定する。
FIG. 7 is a flowchart showing a flow of transaction group generation processing according to the first exemplary embodiment of the present invention. First, the transaction group generation means 340 selects transaction information (S21). Specifically, the transaction
ステップS22において、関連する取引情報が存在すると判定した場合、取引グループ生成手段340は、当該関連する取引情報を選択する(S23)。具体的には、取引グループ生成手段340は、取引情報記憶部33を参照し、複数の取引ID332の内、ステップS22において、検索キーと一致する取引元口座ID333又は取引先口座ID334が関連付けられた取引ID332を全て選択する。その後、取引グループ生成手段340は、ステップS23において選択した取引ID332に関連する取引情報を選択する。以後、関連する取引情報が存在しなくなるまでの間、ステップS22及びS23を繰り返し実行する。尚、ステップS22において、取引グループ生成手段340は、未選択の口座IDについて、未選択の取引情報の中から検索を行うものとする。また、ステップS23において複数の関連する取引情報が選択された場合、それぞれについてステップS22及びS23を繰り返し実行する。例えば、ステップS22において、図3の取引t11が選択された場合、取引元の口座a1Bを取引元口座ID333とする取引t14と、取引先口座ID334とする取引t13とが関連する取引情報として選択される。一方、取引t11の取引先の口座a1Eを取引元口座ID333又は取引先口座ID334とする取引は存在しないため、口座a1Eに関連する取引情報は選択されない。そして、取引t14における取引先の口座a1Dと、取引t13の取引元の口座a1Aとのいずれかに関連する取引情報として、取引t12が選択される。その後、取引t12の取引元の口座a1Aに関連する取引情報(取引t13)が選択済みであり、取引先の口座a1Cに関連する取引情報が存在しないため、ステップS22において、関連する取引情報が存在しないと判定される。
If it is determined in step S22 that relevant transaction information exists, the transaction
ステップS22において、関連する取引情報が存在しないと判定した場合、取引グループ生成手段340は、取引グループを生成する(S24)。具体的には、取引グループ生成手段340は、一つのグループID331を発行し、選択した複数の取引ID332に関連付けてグループID331を取引情報記憶部33に格納する。
In step S22, when it is determined that there is no relevant transaction information, the transaction
そして、取引グループ生成手段340は、取引グループ内の取引情報に決済順序を設定する(S25)。具体的には、取引グループ生成手段340は、所定の項目についてソートを行う。そして、取引グループ生成手段340は、ソート結果に従い決済順序を設定する。すなわち、取引グループ生成手段340は、選択されたグループID331に関連付けられた取引ID332について、所定のソート順に基づき、並び替えを行い、並び替えた結果に基づき、各取引ID332に対応する決済順序336に順序番号を設定して取引情報記憶部33を更新する。
And the transaction group production | generation means 340 sets a payment order to the transaction information in a transaction group (S25). Specifically, the transaction group generation means 340 performs sorting on predetermined items. And the transaction group production | generation means 340 sets a payment order according to a sorting result. That is, the transaction
例えば、受け付けた順序、取引の種別等を考慮してソートを行う。取引の種別によっては、他の取引種別が決済可能となるための前提となるものや、優先して決済しなければならないものがあるため、特定の取引の種別を優先してソートを行う。また、債券取引の場合、債券の券種が小さいものを優先してソートを行ってもよい。つまり、業務における優先順位に基づき決済順序を初期設定することにより、決済順序試行処理において、少ない試行回数により試行が成功しやすくなる。 For example, the sorting is performed in consideration of the received order, the type of transaction, and the like. Depending on the type of transaction, there are a premise that other transaction types can be settled and a case where payment has to be preferentially performed, so sorting is performed with priority on a specific transaction type. In the case of bond trading, sorting may be performed with priority given to bonds having a small bond type. In other words, by initializing the payment order based on the priority order in the business, the trial is likely to succeed with a small number of trials in the payment order trial process.
続いて、取引グループ生成手段340は、未選択の取引情報が存在するか否かを判定する(S26)。具体的には、取引グループ生成手段340は、取引情報記憶部33を参照し、取引ID332の内、未選択の取引情報が存在するか否かを判定する。ステップS26において、未選択の取引情報が存在すると判定した場合、取引グループ生成手段340は、未選択の取引ID332の内、一つを選択する(S27)。その後、全ての取引情報について選択し終えるまでの間、ステップS22乃至S27を繰り返し実行する。
Subsequently, the transaction
ステップS26において、未選択の取引情報が存在しない、つまり、全ての取引情報が選択済みであると判定した場合、取引グループ生成手段340は、取引グループ生成処理を終了する。尚、ステップS25は、全ての取引グループ生成処理の最後に、まとめて決済順序を設定してもよい。上述した図3は、本発明の実施の形態1にかかる取引グループ生成処理の実行結果の一例である。
In step S26, when it is determined that there is no unselected transaction information, that is, all the transaction information has been selected, the transaction
図8は、本発明の実施の形態1にかかる取引グループの例を示す図である。尚、図8(a)〜(f)は、図3の取引グループg1〜g6について、口座と取引との関係を概念で示した図である。また、図8(g)は、図8(a)〜(f)における一取引の凡例である。以下の決済順序調整処理及び確定処理の説明においては、適宜、図2、図3及び図8に例示した残高情報、取引グループ及び取引情報を用いる。 FIG. 8 is a diagram showing an example of a transaction group according to the first exemplary embodiment of the present invention. 8A to 8F are diagrams conceptually showing the relationship between accounts and transactions for the transaction groups g1 to g6 in FIG. FIG. 8 (g) is a legend of one transaction in FIGS. 8 (a) to 8 (f). In the following description of the settlement order adjustment process and the confirmation process, the balance information, transaction group, and transaction information illustrated in FIGS. 2, 3, and 8 are used as appropriate.
図9は、本発明の実施の形態1にかかる決済順序調整処理の流れを示すフローチャートである。まず、取引グループ決済試行手段350は、取引グループ決済試行処理を行う(S301)。ここで、図10は、本発明の実施の形態1にかかる取引グループ決済試行処理の流れを示すフローチャートである。まず、繰り返し実行手段353は、N及びLに初期値を設定する(S41)。ここで、Nは、後述するステップS42の決済試行処理において参照する決済順序の番号であり、決済試行処理を繰り返し実行するためのループカウンタである。つまり、ステップS41では、決済試行処理の対象とする最初の決済順序を設定する。また、Lは、決済試行処理において参照する決済順序の番号の上限値である。尚、図9のステップS301においては、Nに"1"を設定し、Lに図6のステップS13において選択された取引グループに含まれる取引数を設定する。尚、このとき、併せて、成功回数Mは、"0"に設定される FIG. 9 is a flowchart showing the flow of the settlement order adjustment process according to the first embodiment of the present invention. First, the transaction group settlement trial means 350 performs a transaction group settlement trial process (S301). Here, FIG. 10 is a flowchart showing the flow of the transaction group settlement trial process according to the first embodiment of the present invention. First, the repeated execution means 353 sets initial values for N and L (S41). Here, N is the number of the settlement order to be referred to in the settlement trial process in step S42 described later, and is a loop counter for repeatedly executing the settlement trial process. That is, in step S41, the first settlement order that is the target of the settlement trial process is set. L is an upper limit value of the number of the settlement order referred to in the settlement trial process. In step S301 in FIG. 9, “1” is set in N, and the number of transactions included in the transaction group selected in step S13 in FIG. 6 is set in L. At this time, the success count M is also set to “0”.
次に、繰り返し実行手段353は、決済試行処理を行う(S42)。ここで、図11は、本発明の実施の形態1にかかる決済試行処理の流れを示すフローチャートである。まず、取引決済試行手段351は、N番目の取引の決済を試行する(S51)。例えば、図10のステップS41の直後、かつ、1回目の試行においては、Nは"1"であるため、繰り返し実行手段353は、"N=1"として取引決済試行手段351を実行させる。そして、取引決済試行手段351は、口座情報記憶部32及び取引情報記憶部33を参照し、決済順序336がN番目の取引の決済を試行する。すなわち、取引決済試行手段351は、決済順序336がN番目である取引ID332に関連付けられた取引元口座ID333及び取引先口座ID334を特定し、取引額335を取得する。そして、取引決済試行手段351は、特定した取引元口座ID333に対応する残高情報322を口座情報記憶部32から取得する。続いて、取引決済試行手段351は、取得した残高情報322が取得した取引額335以上であるか否かを判定する。
Next, the repeated execution means 353 performs a settlement trial process (S42). Here, FIG. 11 is a flowchart showing the flow of the settlement trial process according to the first embodiment of the present invention. First, the transaction settlement trial means 351 tries settlement of the Nth transaction (S51). For example, immediately after step S41 of FIG. 10 and in the first trial, since N is “1”, the repeated execution means 353 causes the transaction settlement trial means 351 to execute with “N = 1”. Then, the transaction
続いて、残高情報更新手段352は、ステップS51における試行が成功したか否かを判定する(S52)。具体的には、ステップS51において、N番目の取引ID332における取引元口座ID333の残高情報322が、当該取引ID332における取引額335以上であると判定した場合、残高情報更新手段352は、当該試行が成功したと判定する。一方、取引額335未満であると判定した場合、残高情報更新手段352は、当該試行が失敗したと判定する。尚、残高情報更新手段352は、ステップS51における試行が成功したか否かの判定結果(不図示)を、取引ID332に関連付けて取引情報記憶部33に格納するものとする。また、2巡目以降が実行される場合、個別に記憶することが望ましい。ステップS52において、当該試行が失敗したと判定した場合、ステップS55へ進む。
Subsequently, the balance
ステップS52において、当該試行が成功したと判定した場合、残高情報更新手段352は、成功回数Mに"1"を加算する(S53)。そして、残高情報更新手段352は、残高情報322を更新する(S54)。具体的には、まず、残高情報更新手段352は、上記特定した取引元口座ID333に対応する残高情報322から取引額335を減算した結果を、取引元口座ID333における残高情報322として口座情報記憶部32を更新する。また、残高情報更新手段352は、上記特定した取引先口座ID334に対応する残高情報322に取引額335を加算した結果を、取引先口座ID334における残高情報322として口座情報記憶部32を更新する。
If it is determined in step S52 that the trial is successful, the balance
その後、繰り返し実行手段353は、NがL未満であるか否かを判定する(S55)。すなわち、繰り返し実行手段353は、決済が未試行である取引が存在するか否かにより、取引決済試行手段351の処理及び残高情報更新手段352の処理を繰り返し実行すべきか否かを判定する。ステップS55において、NがL未満であると判定した場合、繰り返し実行手段353は、Nに"1"を加算する(S56)。その後、全ての取引について決済順序に従って試行を終えるまでの間、ステップS51乃至S56を繰り返し実行する。ステップS55において、NがL以上であると判定した場合、つまり、全ての取引について試行を終えた場合、繰り返し実行手段353は、決済試行処理を終了する。
Thereafter, the repeated execution means 353 determines whether N is less than L (S55). That is, the
図12及び図13は、本発明の実施の形態1にかかる取引グループ決済試行処理の実行結果の例を示す図である。図12(a)〜(c)は、図8に示した取引グループg1〜g3における1巡目並びに取引グループg1及びg2における2巡目の決済試行処理の実行結果の例を示す図である。図13(d)〜(f)は、図8に示した取引グループg4〜g6における1巡目の決済試行処理の実行結果の例を示す図である。 12 and 13 are diagrams illustrating examples of execution results of the transaction group settlement trial process according to the first embodiment of the present invention. 12A to 12C are diagrams illustrating examples of execution results of the settlement trial process in the first round in the transaction groups g1 to g3 and the second round in the transaction groups g1 and g2 illustrated in FIG. FIGS. 13D to 13F are diagrams illustrating examples of execution results of the first round of settlement trial processing in the transaction groups g4 to g6 illustrated in FIG.
例えば、取引グループg1の場合、1巡目の決済試行処理では、決済順序に従い、取引t11、t12、t13、t14の順序で決済が試行される。まず、決済順序"1"である取引t11については、取引額が"10"であるところ、取引元口座a1Bの残高情報が"0"である。そのため、残高情報更新手段352は、取引t11の試行が失敗すると判定する(S52)。よって、取引元口座a1B及び取引先口座a1Eの残高情報は更新されない。次に、決済順序"2"である取引t12については、取引額が"10"であるところ、取引元口座a1Aの残高情報が"30"である。そのため、残高情報更新手段352は、取引t12の試行が成功すると判定する(S52)。よって、残高情報更新手段352は、成功回数Mを"1"とし(S53)、取引元口座a1Aの残高情報"30"から取引額"10"を減算した"20"として口座情報記憶部32の口座ID"a1A"の残高情報322を更新する。また、残高情報更新手段352は、取引先口座a1Cの残高情報"0"に取引額"10"を加算した"10"として口座情報記憶部32の口座ID"a1C"の残高情報322を更新する(S54)。その後、決済順序"3"である取引t13については、取引額が"20"であるところ、取引元口座a1Aの残高情報が"20"である。そのため、残高情報更新手段352は、取引t13の試行が成功すると判定(S52)し、上述したようにステップS53及びS54を行う。さらに、決済順序"4"である取引t14については、取引額が"10"であるところ、取引元口座a1Bの残高情報が"10"である。そのため、残高情報更新手段352は、取引t14の試行が成功すると判定(S52)し、上述したようにステップS53及びS54を行う。
For example, in the case of the transaction group g1, in the settlement trial process for the first round, settlement is attempted in the order of transactions t11, t12, t13, and t14 according to the settlement order. First, for the transaction t11 having the settlement order “1”, the balance information of the transaction source account a1B is “0” when the transaction amount is “10”. Therefore, the balance
以上が取引グループg1における1巡目の決済試行処理の流れである。図12(a)の1巡目の成否の"○"が試行に成功した取引を示し、"×"が試行に失敗した取引を示す。また、同様に、図12(b)(c)、図13(d)〜(f)が取引グループg2からg6についての1巡目の決済試行処理の結果を示す。 The above is the flow of the first round of settlement trial processing in the transaction group g1. In FIG. 12A, the success or failure “◯” in the first round indicates a successful transaction, and “x” indicates a failed transaction. Similarly, FIGS. 12B and 12C and FIGS. 13D to 13F show the results of the first round of settlement trial processing for the transaction groups g2 to g6.
図10に戻り、決済順序更新手段354は、ステップS42の結果により再試行を行う必要があるか否かを判定する(S43)。すなわち、決済順序更新手段354は、ステップS42の結果、試行が成功した取引における決済順序以前に、試行が失敗した取引が存在するか否かを判定する。つまり、決済順序更新手段354は、少なくとも試行が最後に成功した取引における決済順序以前に、試行が失敗した取引が1以上存在するか否かを判定することとなる。
Returning to FIG. 10, the settlement
例えば、図12(a)では、試行が成功した取引t12〜t14の決済順序"2"〜"4"以前に、試行が失敗した取引t11が存在する。そのため、決済順序更新手段354は、取引グループg1について再試行を行う必要があると判定する。また、図12(b)では、試行が成功した取引t21の決済順序"1"以前には、試行が失敗した取引が存在しないが、試行が成功した取引t23の決済順序"3"以前には、試行が失敗した取引t22が存在する。そのため、決済順序更新手段354は、取引グループg2について再試行を行う必要があると判定する。また、図12(c)及び図13(d)では、全ての取引について試行が失敗しているため、決済順序更新手段354は、取引グループg3及びg4について再試行を行う必要がないと判定する。これは、試行が成功していないため、各口座の残高が更新されておらず、試行を行う際の条件が変更していないため、再試行により結果の差が生じえないためである。さらに、図13(e)及び(f)では、最後に試行が成功した取引t52又はt62の決済順序"2"以前には、試行が失敗した取引が存在しないため、決済順序更新手段354は、取引グループg5及びg6について再試行を行う必要がないと判定する。
For example, in FIG. 12A, there is a transaction t11 for which the trial has failed before the settlement order “2” to “4” of the transactions t12 to t14 for which the trial was successful. Therefore, the settlement
ステップS43において、再試行を行う必要があると判定した場合、決済順序更新手段354は、決済順序を更新する(S44)。すなわち、決済順序更新手段354は、試行が失敗した全ての取引における決済順序が、試行が成功した全ての取引(成功数M)における決済順序より後の順序である"M+1"以降となるように取引情報記憶部33を更新する。具体的には、まず、決済順序更新手段354は、試行が成功した各取引における決済順序を、当該試行が成功した時点における成功した取引の成功数Mとして、取引情報記憶部33を更新する。次に、決済順序更新手段354は、試行が失敗した全ての取引における決済順序を、M+1以上かつL以下として、取引情報記憶部33を更新する。
If it is determined in step S43 that it is necessary to retry, the settlement
例えば、図12(a)では、まず、試行が成功した全ての取引t12、t13及びt14の2巡目の決済順序として、それぞれ"1"、"2"及び"3"とする。次に、試行が失敗した全ての取引t11の2巡目の決済順序として、"3"に"1"を加算した"4"とする。同様に、図12(b)では、試行が成功した全ての取引t21及びt23の2巡目の決済順序として、それぞれ"1"及び"2"とし、試行が失敗した取引t22の2巡目の決済順序として、"2"に"1"を加算した"3"、そして、取引t24の2巡目の決済順序として、"4"とする。 For example, in FIG. 12A, first, “1”, “2”, and “3” are set as the settlement order of the second round of all transactions t12, t13, and t14 that have been successfully tried, respectively. Next, “4” is obtained by adding “1” to “3” as the settlement order of the second round of all transactions t11 for which the trial has failed. Similarly, in FIG. 12B, the settlement order of the second round of all transactions t21 and t23 for which the trial was successful is set to “1” and “2”, respectively, and the second round of the transaction t22 for which the trial has failed. “3” is obtained by adding “1” to “2” as the settlement order, and “4” as the settlement order of the second round of the transaction t24.
尚、図11のステップS53における成功数Mの算出処理は、ステップS44において、決済順序更新手段354が取引決済試行手段351の試行結果を基に集計することにより実行しても構わない。
The calculation process of the success number M in step S53 in FIG. 11 may be executed by the settlement
また、決済順序更新手段354は、成功した取引の決済順序の更新を図11のステップS53の後に実行しても構わない。すなわち、決済順序更新手段354は、取引決済試行手段351における試行が成功した場合に、当該N番目の取引における決済順序を、ステップS53により加算後の成功数Mとして、取引情報記憶部33を更新しても構わない。
Further, the settlement
続いて、繰り返し実行手段353は、Nに"M+1"を代入する(S45)。その後、再試行を行う必要がある間、ステップS42乃至S45を繰り返し実行する。ステップS43において、再試行を行う必要がないと判定した場合、取引グループ決済試行手段350は、取引グループ決済試行処理を終了する。 Subsequently, the repeated execution means 353 substitutes “M + 1” for N (S45). Thereafter, steps S42 to S45 are repeatedly executed while it is necessary to retry. If it is determined in step S43 that there is no need to retry, the transaction group settlement trial means 350 ends the transaction group settlement trial process.
尚、ステップS43において、再試行を行う必要があると判定した場合、決済順序更新手段354は、最後に試行が成功した取引における決済順序を特定し、試行が失敗した全ての取引における決済順序を、当該特定された決済順序より後の順序として、取引情報記憶部33を更新する。この場合、必ずしも試行に成功した取引の決済順序を更新しなくてもよい。この場合、決済順序更新手段354による更新後に、繰り返し実行手段353は、試行が失敗した全ての取引について、取引情報記憶部33に格納された決済順序に基づいてNを昇順に更新して、取引決済試行手段351の処理及び残高情報更新手段352の処理を繰り返し実行する。
If it is determined in step S43 that it is necessary to retry, the settlement
例えば、図12(a)では、最後に試行が成功した取引t14における決済順序が"4"であることを特定し、取引t11の2巡目の決済順序として、"4"に"1"を加算した"5"としてもよい。同様に、図12(b)では、最後に試行が成功した取引t23における決済順序が"3"であることを特定し、取引t22及びt24の2巡目の決済順序として、それぞれ"4"及び"5"としてもよい。但し、この場合、ステップS42を再度実行する際に、Nを"最後に試行が成功した取引における決済順序+1"とし、Lを"最後に試行が成功した取引における決済順序+失敗した取引総数"とする。これにより、試行が成功した取引における決済順序を更新する処理を減らし、処理コストを減らすことができる。 For example, in FIG. 12A, it is specified that the settlement order in the last successful transaction t14 is “4”, and “1” is set to “4” as the settlement order of the second round of the transaction t11. The added value may be “5”. Similarly, in FIG. 12B, it is specified that the settlement order in the last successful transaction t23 is “3”, and the settlement order of the second round of the transactions t22 and t24 is “4” and It may be “5”. However, in this case, when step S42 is executed again, N is set to “settlement order in the last successful transaction + 1” and L is “settlement order in the last successful transaction + total number of failed transactions”. And Thereby, the process which updates the payment order in the transaction where trial was successful can be reduced, and processing cost can be reduced.
図9に戻り、取引グループ決済試行手段350は、試行に失敗した取引が存在するか否かを判定する(S302)。例えば、取引グループ決済試行手段350は、取引情報記憶部33を参照し、取引ID332に関連付けられた判定結果に基づき判定する。ステップS302において、試行に失敗した取引が存在しないと判定した場合、つまり、対象の取引グループにおける全ての取引についてステップS301における試行が成功した場合、取引グループ決済試行手段350は、当該取引グループが"通常取引"であると判定する(S310)。図8の例では、取引グループg1のみが"通常取引"であると判定される。このとき、取引グループ決済試行手段350は、"通常取引"であることを示す情報である判定結果(不図示)をグループID331に関連付けて取引情報記憶部33に格納する。
Returning to FIG. 9, the transaction group settlement trial means 350 determines whether there is a transaction that has failed in the trial (S302). For example, the transaction group
ステップS302において、試行に失敗した取引が存在すると判定した場合、つまり、対象の取引グループにおける取引の中にステップS301における試行が失敗した取引が含まれる場合、残高情報補正手段360は、口座当たりの収支残高を算出する(S303)。図8の例では、取引グループg2〜g6がステップS303の対象となる。残高情報補正手段360は、口座情報記憶部32及び取引情報記憶部33を参照し、各取引グループに含まれる口座ごとに以下の処理を行う。具体的には、まず、残高情報補正手段360は、口座情報記憶部32から対象口座の残高情報322を取得する。次に、残高情報補正手段360は、取引情報記憶部33を参照し、対象口座を取引元又は取引先の口座とする全ての取引を選択し、選択した取引ID332における取引額335から取引元及び取引先のそれぞれの合計を算出する。そして、残高情報補正手段360は、取得した残高情報322に、対象口座を取引先の口座とする取引の取引額335の合計を加算し、対象口座を取引元の口座とする取引の取引額335の合計を減算する。そして、その結果である口座当たりの収支残高(不図示)を対象口座に関連付けて口座情報記憶部32に格納する。
If it is determined in step S302 that there is a transaction that has failed in the trial, that is, if the transaction in the target transaction group includes a transaction that has failed in the step S301, the balance
ここで、図14は、本発明の実施の形態1にかかる口座収支算出処理の実行結果の例を示す図である。図14(a)〜(e)は、それぞれ取引グループg2〜g6における口座収支の例を示す図である。図14(a)では、例えば、口座a2Bを対象口座とした場合、まず、残高情報補正手段360は、初期残高"0"を取得する。次に、残高情報補正手段360は、口座a2Bを取引先の口座とする取引t21の取引額"10"を取得する。このとき、取引額合計(入)は、"10"である。また、残高情報補正手段360は、口座a2Bを取引元の口座とする取引t23及びt24の取引額"10"及び"10"を取得する。このとき、取引額合計(払)は、"20"である。そして、残高情報補正手段360は、初期残高"0"に、取引額合計(入)"10"を加算し、取引額合計(払)"20"を減算して、収支残高"−10"を算出し、口座情報記憶部32に格納する。その他、図14(a)〜(e)について同様に口座当たりの収支残高が算出される。
Here, FIG. 14 is a figure which shows the example of the execution result of the account balance calculation
その後、残高情報補正手段360は、取引グループ内に収支残高が赤字となる赤字口座が存在するか否かを判定する(S304)。すなわち、残高情報補正手段360は、ステップS303において算出された収支残高が所定値以下となる口座が存在するか否かを判定する。具体的には、残高情報補正手段360は、口座情報記憶部32を参照し、収支残高がマイナスである口座が存在するか否かを確認する。例えば、図14(a)の場合、口座a2A及びa2Bの収支残高がマイナスであるため、取引グループg2内に赤字口座が存在すると判定される。同様に、図14(b)及び(c)に基づき、取引グループg3及びg4内に赤字口座が存在すると判定される。一方、図14(d)及び(e)の場合、収支残高がマイナスとなる口座が存在しないため、取引グループg5及びg6内に赤字口座が存在しないと判定される。ステップS304において、取引グループ内に赤字口座が存在しないと判定された場合、ステップS308へ進む。
Thereafter, the balance
ステップS304において、取引グループ内に赤字口座が存在すると判定された場合、残高情報補正手段360は、残高を補正する(S305)。すなわち、残高情報補正手段360は、残高が所定値となる取引額を加算して口座情報記憶部32に格納された残高情報322を補正する。例えば、残高情報補正手段360は、取引グループg2の口座a2Aの残高情報322に、"10"を加算して口座情報記憶部32を更新する。同様に、取引グループg2、g3及びg4における口座a2B、a3A及びa4Aの残高情報322に、不足額を加算して口座情報記憶部32を更新する。
If it is determined in step S304 that there is a deficit account in the transaction group, the balance
そして、取引グループ決済試行手段350は、取引グループ決済試行処理を実行する(S306)。すなわち、取引グループ決済試行手段350は、残高情報補正手段360により補正された残高情報を用いて、取引情報記憶部33に格納された決済順序336に基づき、取引グループ決済試行手段350により前回、試行が失敗した全ての取引についての決済を試行することにより決済順序を調整する。
Then, the transaction group settlement trial means 350 executes a transaction group settlement trial process (S306). That is, the transaction group
ここで、図15は、本発明の実施の形態1にかかる残高補正処理後の取引グループ決済試行処理の実行結果の例を示す図である。図15(a)〜(c)は、それぞれ取引グループg2〜g4のステップS306における1巡目の決済試行処理の実行結果の例を示す図である。図15(a)の場合、ステップS301の実行後の決済順序に従い、ステップS301により試行が失敗した取引t22及びt24のみについて、口座a2A及びa2Bの残高が補正された状態として、決済を試行する。そして、取引t22及びt24が共に試行に成功する。尚、この場合、図9のステップS306においては、Nに"3"を設定し、Lに"4"を設定して、図10の取引グループ決済試行処理を実行する。そのため、残高を補正する前に試行が成功した取引t21及びt23については、試行の対象とならない。よって、不要な処理を減らすことができる。同様に、図15(b)及び(c)の場合、図9のステップS306においては、Nに"1"を設定し、Lに"5"を設定して、図10の取引グループ決済試行処理を実行する。ここでは、決済順序"1"及び"2"のみが試行に成功するが、以降の取引の試行は失敗する。 Here, FIG. 15 is a diagram illustrating an example of an execution result of the transaction group settlement trial process after the balance correction process according to the first embodiment of the present invention. FIGS. 15A to 15C are diagrams illustrating examples of execution results of the first round of settlement trial processing in step S306 for the transaction groups g2 to g4, respectively. In the case of FIG. 15A, according to the settlement order after the execution of step S301, settlement is attempted only for the transactions t22 and t24 for which the trial failed in step S301, with the balance of the accounts a2A and a2B corrected. Both transactions t22 and t24 succeed in the trial. In this case, in step S306 in FIG. 9, N is set to “3” and L is set to “4”, and the transaction group settlement trial process in FIG. 10 is executed. Therefore, the transactions t21 and t23 that have been successfully tried before the balance is corrected are not targeted. Therefore, unnecessary processing can be reduced. Similarly, in the case of FIGS. 15B and 15C, in step S306 in FIG. 9, N is set to “1”, L is set to “5”, and the transaction group settlement trial process in FIG. Execute. Here, only the settlement orders “1” and “2” succeed in the trial, but subsequent transaction trials fail.
図9に戻り、取引グループ決済試行手段350は、ステップS302と同様に、試行に失敗した取引が存在するか否かを判定する(S307)。ステップS307において、試行に失敗した取引が存在しないと判定した場合、取引グループ決済試行手段350は、当該取引グループが"赤残連鎖取引"であると判定する(S311)。図8の例では、取引グループg2のみが"赤残連鎖取引"であると判定される。このとき、取引グループ決済試行手段350は、"赤残連鎖取引"であることを示す情報である判定結果(不図示)をグループID331に関連付けて取引情報記憶部33に格納する。
Returning to FIG. 9, similarly to step S302, the transaction group
その後、擬似ループ判定手段370は、擬似ループ判定処理を行う(S308)。ここで、図16は、本発明の実施の形態1にかかる擬似ループ判定処理の流れを示すフローチャートである。尚、以下では、図8においては、取引グループg3〜g6が処理対象となる。
Thereafter, the pseudo
まず、端点取引選択手段371は、始点及び終点取引を選択する(S61)。具体的には、端点取引選択手段371は、取引情報記憶部33を参照し、処理対象の取引グループ内の取引について、取引元口座ID333が他の取引の取引先口座ID334と一致しない取引である始点取引を選択する。また、端点取引選択手段371は、取引情報記憶部33を参照し、処理対象の取引グループ内の取引について、取引先口座ID334が他の取引の取引元口座ID333と一致しない取引である終点取引を選択する。尚、始点及び終点取引を端点取引と呼ぶものとする。例えば、取引グループg3の場合、始点取引が取引t31、終点取引が取引t32として選択される。同様に、取引グループg4、g5及びg6の場合、それぞれ始点取引が取引t41、t51及びt61、また、終点取引が取引t42、t52及びt62として選択される。
First, the end point
次に、端点取引処理手段372は、始点及び終点取引の決済順序を更新する(S62)。具体的には、端点取引処理手段372は、始点取引における決済順序を、最初の順序として取引情報記憶部33を更新し、終点取引における決済順序を、最後の順序として取引情報記憶部33を更新する。例えば、取引グループg3の場合、端点取引選択手段371は、始点取引である取引t31の決済順序を"1"とし、終点取引である取引t32の決済順序を"5"として取引情報記憶部33を更新する。同様に、取引グループg4、g5及びg6の場合、端点取引選択手段371は、それぞれ始点取引である取引t41、t51及びt61の決済順序を"1"とし、終点取引である取引t42、t52及びt62の決済順序を"5"として取引情報記憶部33を更新する。尚、始点取引又は終点取引が複数存在する場合、決済順序を同じ値とするとよい。
Next, the end point transaction processing means 372 updates the settlement order of the start point and end point transactions (S62). Specifically, the end point
続いて、端点取引処理手段372は、始点取引に関する残高情報を更新する(S63)。具体的には、端点取引処理手段372は、当該始点取引の決済が確定したと仮定して口座情報記憶部32に格納された残高情報322を更新する。例えば、取引グループg3の場合、端点取引選択手段371は、始点取引の決済を試行して成功する場合に、図11のステップS54に基づき、取引元の口座である口座a3A及び取引先の口座である口座a3Bのそれぞれの残高情報322を決済後の残高情報へ更新する。尚、ステップS305において、残高情報補正手段360により残高が補正された口座については、さらに、残高情報が更新されることとなる。
Subsequently, the end point
そして、擬似ループ判定手段370は、始点及び終点取引を除いて、取引グループ決済試行手段350により取引グループ決済試行処理を実行する(S64)。例えば、擬似ループ判定手段370は、取引グループ内の始点及び終点取引を除いた取引について、決済順序が2以上かつ取引数未満となるように取引情報記憶部33を更新する。そして、Nに"2"を設定し、Lに"取引数−1"を設定して、図10の取引グループ決済試行処理を実行する。尚、ステップS64においては、擬似ループ判定処理の対象となる取引グループに始点取引が存在しない場合、Nに"1"を設定する。また、終点取引が存在しない場合、Lに"取引数"を設定する。そして、図10の取引グループ決済試行処理を実行する。例えば、取引グループがループ取引のみである場合や、始点取引又は終点取引の一方が存在しない場合が該当する。また、始点取引又は終点取引が複数存在する場合、Nに"3"以上の値を設定し、Lに"取引数−1"未満の値を設定して、図10の取引グループ決済試行処理を実行する。
Then, the pseudo
例えば、取引グループg3の場合、擬似ループ判定手段370は、始点又は終点取引以外の取引である取引t33、t34及びt35について、決済順序を"2"〜"4"として更新する。そして、Nに"2"を設定し、Lに"4"を設定して、図10の取引グループ決済試行処理を実行する。ここでは、決済順序"2"の取引t33の取引元の口座a3Bの残高情報322がステップS63により"10"に更新されているため、取引t33の試行が成功する。続いて、決済順序"3"の取引t34の取引元の口座a3Dの残高情報322が上記の試行により"10"に更新されているため取引t34の、試行が成功する。さらに、決済順序"4"の取引t35の取引元の口座a3Eの残高情報322が上記の試行により"10"に更新されているため取引t35の試行が成功する。そのため、決済順序"5"の取引t32の試行も成功することとなる。つまり、取引グループg3は、ステップS64により全ての取引の試行が成功することとなる。また、取引グループg5の場合も同様である。このように、ステップS301及びS306における取引グループ決済試行処理において、試行に失敗した取引を含む取引グループであっても、ステップS61〜S64により、始点及び終点取引を除いた取引に対して試行を行うことにより、決済可能な決済順序を求めることができる。一方、取引グループg4及びg6の場合、ステップS64によっても試行に失敗する取引が存在する。
For example, in the case of the transaction group g3, the pseudo
その後、擬似ループ判定手段370は、ステップS302と同様に、試行に失敗した取引が存在するか否かを判定する(S65)。ステップS65において、試行に失敗した取引が存在しないと判定した場合、擬似ループ判定手段370は、擬似ループ判定処理を終了する。
Thereafter, the pseudo
ステップS65において、試行に失敗した取引が存在すると判定した場合、起点口座選択手段373は、起点口座を選択する(S66)。具体的には、起点口座選択手段373は、取引情報記憶部33を参照し、ステップS64において、試行に失敗した取引に含まれる口座から、1以上の取引先口座ID333かつ2以上の取引元口座ID334として設定される口座を選択する。例えば、取引グループg4の場合、口座a4Bは、取引t42及びt43の取引元の口座であり、取引t41及びt45の取引先の口座であるため、起点口座として選択される。また、取引グループg6の場合、口座a6Bは、取引t62及びt63の取引元の口座であり、取引t61及びt65の取引先の口座であるため、起点口座として選択される。
In step S65, when it is determined that there is a transaction that has failed in the trial, the origin
さらに、図17は、本発明の実施の形態1にかかる起点口座が選択される取引グループの顕著な例を示す図である。図17は、取引グループg7について、口座と取引との関係を概念で示した図である。尚、一取引の凡例は、図8(g)と同様であるため、図示を省略する。ここで、取引グループg7の決済順序の初期設定が取引t71、t72、・・・t79の順序であるものとする。このとき、ステップS301において、取引t71、t72及びt73までの試行が成功し、取引t74以降の試行が失敗する。ステップS304において、赤字口座が存在しないと判定され、擬似ループ判定処理(S308)が実行される。そして、取引グループg7の場合、取引t71が始点取引、取引t73が終点取引として選択される(S61)。その後、ステップS64により、取引t71及びt73を除いて、取引グループ決済試行処理が実行される。このとき、取引t72、t74、t75、t76までが試行に成功し、取引t77〜t79の試行に失敗する。そのため、ステップS65において、試行に失敗した取引が存在すると判定される。そこで、ステップS66において、起点口座選択手段373は、取引t77〜t79に含まれる口座a7B、a7G及びa7Hから、取引t72及びt77の取引元の口座であり、取引t71及びt79の取引先の口座である口座a7Bを起点口座として選択する。
Furthermore, FIG. 17 is a figure which shows the prominent example of the transaction group from which the origin
そして、起点取引処理手段374は、起点取引の決済順序を更新する(S67)。具体的には、起点取引処理手段374は、起点口座選択手段373により選択された口座が取引元の口座となる取引である2以上の起点取引の決済順序における先後関係を入れ替えて取引情報記憶部33を更新する。例えば、取引グループg7の場合、起点取引処理手段374は、口座a7Bが取引元の口座となる取引t77の決済順序を"2"、取引t72の決済順序を"2"より大きい値として、つまり、取引t77と取引t72との決済順序の先後関係を入れ替えて取引情報記憶部33を更新する。同様に、取引グループg4及びg6の場合、起点取引処理手段374は、取引t43及びt63の決済順序を"2"、取引t42及びt62の決済順序を"取引数"として、つまり、取引t42と取引t43との決済順序の先後関係を入れ替えて、また、取引t62と取引t63との決済順序の先後関係を入れ替えて、取引情報記憶部33を更新する。尚、ステップS67においては、擬似ループ判定処理の対象となる取引グループに起点取引が存在しない場合、取引情報記憶部33を更新しない。また、取引t77、t43及びt63の決済順序は、"2"でなくとも構わない。
Then, the originating
その後、擬似ループ判定手段370は、取引グループ内の始点及び終点取引を除いた取引について、取引グループ決済試行処理を行う(S68)。このとき、擬似ループ判定手段370は、取引グループ内の始点及び終点取引を除いた取引について、取引グループ決済試行処理を行う。このとき、複数の起点取引の決済順序における先後関係を適宜入れ替えて、取引情報記憶部33を更新し、取引グループ決済試行処理を行うとよい。そして、全ての取引について試行が成功するか、全ての順序の組み合わせについて試行が終了するまで繰り返し、決済の試行を行う。これにより、赤字口座が存在しない状態の対象の取引グループについて、決済可能か否かについて確実に判明させることができる。尚、ステップS68では、対象となる複数の取引における決済順序の様々な組み合わせについて試行するため、処理時間が長くなる。しかし、ステップS68の処理対象となる取引グループの数は、ステップS64以前の処理により絞りこまれているため、少ないといえる。よって、ステップS68の処理を行う効果が高いといえる。その後、擬似ループ判定手段370は、擬似ループ判定処理を終了する。尚、ステップS66乃至S68に代えて、擬似ループ判定手段370は、取引グループ内の始点及び終点取引を除いた取引について、単に、総当たりにして決済の試行を行ってもよい。
Thereafter, the pseudo
例えば、取引グループg7の場合、擬似ループ判定手段370は、始点取引t71及び終点取引t73を除いた取引t72、t74、t75、t76、t77、t78、t79について、起点取引t72及びt77の決済順序の先後関係を入れ替えて、全ての決済順序の組み合わせについて試行を行う。これにより、取引t71、t77、t78、t79、t72、t74、t75、t76、t73の順序により決済可能であることが判明する。一方、取引グループg4及びg6の場合、全ての決済順序の組み合わせを試行しても決済可能な決済順序が存在しないことが判明する。
For example, in the case of the transaction group g7, the pseudo
図9に戻り、擬似ループ判定手段370は、ステップS302と同様に、試行に失敗した取引が存在するか否かを判定する(S309)。ステップS309において、試行に失敗した取引が存在しないと判定した場合、擬似ループ判定手段370は、当該取引グループが"擬似ループ取引"であると判定する(S312)。尚、当該取引グループがステップS304により赤字口座が存在すると判定されていた場合、擬似ループ判定手段370は、当該取引グループが"赤残連鎖取引"かつ"擬似ループ取引"であると判定する。図8の例では、取引グループg5が"擬似ループ取引"であると判定され、取引グループg3が"赤残連鎖取引"かつ"擬似ループ取引"であると判定される。また、図17の例である取引グループg7が"擬似ループ取引"であると判定される。このとき、擬似ループ判定手段370は、"擬似ループ取引"又は"赤残連鎖取引"かつ"擬似ループ取引"であることを示す情報である判定結果(不図示)をグループID331に関連付けて取引情報記憶部33に格納する。
Returning to FIG. 9, the pseudo
ステップS309において、試行に失敗した取引が存在すると判定した場合、擬似ループ判定手段370は、当該取引グループが"真正ループ取引"であると判定する(S313)。尚、当該取引グループがステップS304により赤字口座が存在すると判定されていた場合、擬似ループ判定手段370は、当該取引グループが"赤残連鎖取引"かつ"真正ループ取引"であると判定する。図8の例では、取引グループg6が"真正ループ取引"であると判定され、取引グループg4が"赤残連鎖取引"かつ"真正ループ取引"であると判定される。このとき、擬似ループ判定手段370は、"真正ループ取引"又は"赤残連鎖取引"かつ"真正ループ取引"であることを示す情報である判定結果(不図示)をグループID331に関連付けて取引情報記憶部33に格納する。
If it is determined in step S309 that there is a transaction that has failed, the pseudo
図18は、本発明の実施の形態1にかかる確定処理の流れを示すフローチャートである。まず、確定手段380は、取引情報記憶部33を参照し、処理対象の取引グループにおける判定結果を確認する(S701)。ステップS701において判定結果が"通常取引"と確認された場合、確定手段380は、処理対象の取引グループにおける全取引のS301後の決済順序を決済可能なものとして確定する(S702)。例えば、取引グループg1の場合、図12(a)の2巡目の決済順序が決済可能なものとして確定される。ここで、確定する処理として、例えば、当該取引グループに含まれる全ての取引の決済を実行するべく勘定系システム等へ通知するか、または、当該取引グループに含まれる口座の所有者へ決済可能である旨を通知する等であるとよい。
FIG. 18 is a flowchart showing the flow of the confirmation process according to the first embodiment of the present invention. First, the
ステップS701において判定結果が"赤残連鎖取引"のみと確認された場合、確定手段380は、ステップS301後の決済順序の内、赤残取引より前の取引の決済順序を決済可能なものとして確定する(S703)。ここで、赤残取引とは、図9のステップS305による残高情報の補正された口座を取引元の口座とする取引の内、ステップS306において、決済の試行が成功した取引である。例えば、取引グループg2の場合、図15(a)の赤残取引である取引t22以前の決済順序である取引t21及び取引t23の決済順序"1"及び"2"が決済可能なものとして確定される。
When it is confirmed in step S701 that the determination result is only “red balance chain transaction”, the
そして、確定手段380は、ステップS305により残高が補正された口座へ残高不足通知を行う(S704)。ここで、残高不足通知として、例えば、通知対象の口座の所有者へ残高不足であるために決済が行えない旨と、不足額を当該口座へ追加する旨等を通知するとよい。例えば、取引グループg2の場合、確定手段380は、口座a2A及びa2Bへ残高不足通知を行う。
Then, the
ステップS701において判定結果が"擬似ループ取引"を含むと確認された場合、確定手段380は、さらに、判定結果が"赤残連鎖取引"を含むか否かを判定する(S705)。ステップS705において、判定結果が"赤残連鎖取引"を含むと判定した場合、確定手段380は、ステップS308後の決済順序の内、赤残取引より前の取引の決済順序を決済可能なものとして確定する(S706)。例えば、取引グループg3の場合、図15(b)の赤残取引である取引t31以前の決済順序である取引は存在しないため、決済可能な決済順序として確定されない。
When it is confirmed in step S701 that the determination result includes “pseudo loop transaction”, the
そして、確定手段380は、ステップS704と同様に、ステップS305により残高が補正された口座へ残高不足通知を行う(S707)。例えば、取引グループg3の場合、確定手段380は、口座a3Aへ残高不足通知を行う。
Then, as in step S704, the
ステップS705において、判定結果が"赤残連鎖取引"を含まないと判定した場合、確定手段380は、処理対象の取引グループにおける全取引のS308後の決済順序を決済可能なものとして確定する(S708)。例えば、取引グループg5の場合、取引t51、t53、t54、t55、t52の決済順序が決済可能なものとして確定される。
If it is determined in step S705 that the determination result does not include “red balance chain transaction”, the
ステップS701において判定結果が"真正ループ取引"を含むと確認された場合、確定手段380は、さらに、判定結果が"赤残連鎖取引"を含むか否かを判定する(S709)。ステップS709において、判定結果が"赤残連鎖取引"を含まないと判定した場合、ステップS711へ進む。ステップS709において、判定結果が"赤残連鎖取引"を含むと判定した場合、確定手段380は、ステップS704と同様に、ステップS305により残高が補正された口座へ残高不足通知を行う(S710)。例えば、取引グループg4の場合、確定手段380は、口座a4Aへ残高不足通知を行う。
When it is confirmed in step S701 that the determination result includes “authentication loop transaction”, the
その後、確定手段380は、ステップS301で試行が成功した取引の決済順序を確定する(S711)。例えば、取引グループg4の場合、図13(d)に示すように、ステップS301で試行が成功した取引が存在しないため、決済可能な決済順序として確定されない。取引グループg6の場合、図13(f)の取引t61及びt62の決済順序"1"及び"2"が決済可能なものとして確定される。
Thereafter, the
そして、確定手段380は、ループ取引に取引不可通知を行う(S712)。ここで、取引不可通知として、例えば、通知対象の口座の所有者へループ取引であるために決済が行えない旨と、関係する他の口座等を通知するとよい。例えば、取引グループg4の場合、確定手段380は、口座a4B、a4D及びa4Eへ取引不可通知を行う。取引グループg6の場合、確定手段380は、口座a6B、a6D及びa6Eへ取引不可通知を行う。
Then, the
その後、確定手段380は、確定処理を終了する。尚、図18は、本発明の実施の形態1にかかる確定処理の一例であり、他の方法でも実現可能である。本発明の実施の形態1にかかる確定処理は、少なくとも決済順序調整処理により判定された取引グループの判定結果に応じて各取引の決済順序を確定すればよい。
Thereafter, the
このように、本発明の実施の形態1では、取引グループ決済試行処理により、所定の順序により決済が可能である取引については、逐次、決済が確定したものとし、以後の試行の対象から除くものである。すなわち、一旦、試行が成功した取引については、原則として再度の試行を行わないようにする。そのため、総当たりで試行を行うことに比べて、試行回数を減らすことができる。つまり、決済可能な決済順序を網羅的に求めず、実際に決済可能である割合が高いケースを優先的に検出する。よって、複数の取引を連続して決済する場合に、決済可能な決済順序について、少ない試行回数により効率的に確定することができる。 As described above, in the first embodiment of the present invention, for transactions that can be settled in a predetermined order by the transaction group settlement trial process, it is assumed that settlement is confirmed sequentially and excluded from the subsequent trial targets. It is. That is, once a transaction has been successfully tried, as a rule, it is not tried again. For this reason, the number of trials can be reduced as compared to trials with brute force. In other words, the settlement order that can be settled is not comprehensively determined, but a case where the rate of actual settlement is high is preferentially detected. Therefore, when a plurality of transactions are settled continuously, the settlement order that can be settled can be determined efficiently with a small number of trials.
<発明の実施の形態2>
債券等の取引では、債券額を券種及び枚数により取り扱う場合がある。例えば、"100"を1単位とする券種と、"50"を1単位とする券種とがある場合、それぞれに券面の枚数を管理する必要がある。そして、取引は、券種及び枚数の指定が可能である。そのため、債券取引の場合、単に、口座の残高の金額において決済可能であっても、券種と枚数により決済不可能となる場合がある。そこで、本発明の実施の形態2にかかる決済順序確定システムは、本発明の実施の形態1にかかる決済順序確定システム3の残高情報補正手段360に変更を加えたものである。すなわち、本発明の実施の形態2にかかる残高情報補正手段は、取引が券種及び枚数により定まる債券における取引である場合に、取引グループに含まれる口座の残高における債券の券種及び枚数に基づき、口座当たりの残高を算出するものである。このとき、図1の口座情報記憶部32には、残高情報322に代えて又は別途、債券の券種の識別情報と、当該券種の枚数とを記憶しているものとする。また、図1の取引情報記憶部33には、取引ID332にかかる債券の券種の識別情報と、当該券種の枚数とを取引ID332に関連付けて記憶しているものとする。尚、本発明の実施の形態2にかかる決済順序確定システムは、本発明の実施の形態1と比べて、上述した以外の構成に変更がない。以下、実施の形態1との違いを中心に説明し、実施の形態1と同等の構成及び処理については、詳細な説明を省略する。
<
In transactions such as bonds, the amount of bonds may be handled depending on the type and number of tickets. For example, when there are a ticket type with “100” as one unit and a ticket type with “50” as one unit, it is necessary to manage the number of sheet surfaces for each. In the transaction, the ticket type and the number of sheets can be specified. Therefore, in the case of bond transactions, even if payment can be made with the balance of the account, payment may not be possible depending on the type and number of tickets. Therefore, the settlement order determination system according to the second embodiment of the present invention is a modification of the balance
図19は、本発明の実施の形態2にかかる券種及び枚数を考慮した取引グループの例を示す図である。図19(a)は、取引グループg8について、口座と取引との関係を概念で示した図である。また、図19(b)は、図19(a)における一取引の凡例である。ここで、取引グループg8の決済順序の初期設定が取引t81、t82、・・・t87の順序であるものとする。また、各口座の下の括弧書きは、債券の券種及び枚数の初期残高を示し、各取引の下の取引額の括弧書きが"−"である取引は、債券の券種及び枚数の指定がない取引であるものとする。 FIG. 19 is a diagram illustrating an example of a transaction group in consideration of the ticket type and the number of sheets according to the second embodiment of the present invention. FIG. 19A is a diagram conceptually showing the relationship between accounts and transactions for the transaction group g8. FIG. 19B is a legend of one transaction in FIG. Here, it is assumed that the initial setting of the settlement order of the transaction group g8 is the order of transactions t81, t82,. The brackets under each account indicate the initial balance of bond type and number of bonds. For transactions where the parenthesis of the transaction amount under each transaction is "-", the bond type and number of bonds are specified. It is assumed that there is no transaction.
また、図20(a)は、本発明の実施の形態1と同様に取引額のみで口座収支を算出した場合の口座収支の例を示す図である。また、図20(b)は、本発明の実施の形態2にかかる券種及び枚数を考慮した口座収支の例を示す図である。 FIG. 20 (a) is a diagram showing an example of an account balance when the account balance is calculated using only the transaction amount as in the first embodiment of the present invention. FIG. 20B is a diagram showing an example of an account balance in consideration of the ticket type and the number of sheets according to the second embodiment of the present invention.
続いて、図9のステップS303において、口座a8Aについての収支残高を算出する場合を説明する。まず、本発明の実施の形態1にかかる残高情報補正手段360は、口座情報記憶部32から口座a8Aの残高情報"100"を取得する。そして、残高情報補正手段360は、取引情報記憶部33から口座a8Aを取引先の口座とする取引t81、t82及びt83の取引額"200"、"100"及び"150"を取得し、取引額合計(入)"450"を算出する。また、残高情報補正手段360は、取引情報記憶部33から口座a8Aを取引元の口座とする取引t84、t85、t86及びt87の取引額"50"、"150"、"100"及び"100"を取得し、取引額合計(払)"400"を算出する。そして、残高情報補正手段360は、取得した残高情報"100"に、取引額合計(入)"450"を加算し、取引額合計(払)"400"を減算して、収支残高"150"を算出する。
Next, the case where the balance of balance for the account a8A is calculated in step S303 in FIG. 9 will be described. First, the balance
一方、本発明の実施の形態2にかかる残高情報補正手段は、口座情報記憶部32から口座a8Aの券種"100"の枚数"1"を初期枚数として取得する。そして、当該残高情報補正手段は、取引情報記憶部33から口座a8Aを取引先の口座とする取引の内、券種指定のある取引t82の券種"100"の枚数"1"を取得し、併せて、券種指定のない取引t81及びt83の取引額"200"及び"150"を取得する。そして、当該残高情報補正手段は、取得した取引額"200"及び"150"についてできるだけ大きな単位の券種の枚数として換算する。つまり、券種"100"の枚数"3"及び券種"50"の枚数"1"と換算する。その後、当該残高情報補正手段は、券種"100"の合計枚数(入)"4"及び券種"50"の合計枚数(入)"1"を算出する。また、当該残高情報補正手段は、取引情報記憶部33から口座a8Aを取引元の口座とする取引の内、券種指定のある取引t84の券種"50"の枚数"1"を取得し、併せて、券種指定のない取引t85、t86及びt87の取引額"150"、"100"及び"100"を取得する。そして、当該残高情報補正手段は、取得した取引額"150"、"100"及び"100"についてできるだけ大きな単位の券種の枚数として換算する。つまり、券種"100"の枚数"3"及び券種"50"の枚数"1"と換算する。その後、当該残高情報補正手段は、券種"100"の合計枚数(払)"3"及び券種"50"の合計枚数(払)"2"を算出する。そして、当該残高情報補正手段は、券種"100"について、初期枚数"1"に、合計枚数(入)"4"を加算し、合計枚数(払)"3"を減算して、収支枚数"2"を算出する。併せて、当該残高情報補正手段は、券種"50"について、初期枚数"0"に、合計枚数(入)"1"を加算し、合計枚数(払)"2"を減算して、収支枚数"−1"を算出する。すなわち、図20(b)に示すように、口座a8Aは、収支残高が赤字と判定される。
On the other hand, the balance information correction unit according to the second exemplary embodiment of the present invention acquires the number “1” of the ticket type “100” of the account a8A from the account
このように、図20(a)のように券種及び枚数を考慮しない場合、黒字と判定されるが、本発明の実施の形態2により、図20(b)のように券種及び枚数を考慮することにより、赤字と判定され、単に、口座の残高の金額において決済可能であっても、券種と枚数により決済不可能となる場合を正確に決済可能な決済順序を確定することができる。 As described above, when the ticket type and the number of sheets are not considered as shown in FIG. 20A, it is determined to be in black. However, according to the second embodiment of the present invention, the ticket type and the number of sheets are determined as shown in FIG. By taking into consideration, it is determined that there is a deficit, and even if payment is possible with the amount of the balance of the account, it is possible to determine a payment order in which payment can be made accurately when payment is not possible depending on the type and number of tickets .
<その他の発明の実施の形態>
さらに、本発明は上述した実施の形態のみに限定されるものではなく、既に述べた本発明の要旨を逸脱しない範囲において種々の変更が可能であることは勿論である。
<Other embodiments of the invention>
Furthermore, the present invention is not limited to the above-described embodiments, and various modifications can be made without departing from the gist of the present invention described above.
1a、1b、・・・1n 端末
2 ネットワーク
3 決済順序確定システム
301 CPU
302 RAM
303 ROM
304 通信部
305 ハードディスク
306 OS
307 決済順序確定プログラム
31 制御部
32 口座情報記憶部
321 口座ID
322 残高情報
33 取引情報記憶部
331 グループID
332 取引ID
333 取引元口座ID
334 取引先口座ID
335 取引額
336 決済順序
340 取引グループ生成手段
350 取引グループ決済試行手段
351 取引決済試行手段
352 残高情報更新手段
353 繰り返し実行手段
354 決済順序更新手段
360 残高情報補正手段
370 擬似ループ判定手段
371 端点取引選択手段
372 端点取引処理手段
373 起点口座選択手段
374 起点取引処理手段
380 確定手段
a1A、a1B、a1C、a1D、a1E 口座
a2A、a2B、a2C、a2D、a2E 口座
a3A、a3B、a3C、a3D、a3E 口座
a4A、a4B、a4C、a4D、a4E 口座
a5A、a5B、a5C、a5D、a5E 口座
a6A、a6B、a6C、a6D、a6E 口座
a7A、a7B、a7C、a7D、a7E、a7F、a7G、a7H 口座
a8A、a8B、a8C、a8D、a8E、a8F、a8G、a8H 口座
g1、g2、g3、g4、g5、g6、g7、g8 取引グループ
t11、t12、t13、t14 取引
t21、t22、t23、t24 取引
t31、t32、t33、t34、t35 取引
t41、t42、t43、t44、t45 取引
t51、t52、t53、t54、t55 取引
t61、t62、t63、t64、t65 取引
t71、t72、t73、t74、t75、t76、t77、t78、t79 取引
t81、t82、t83、t84、t85、t86、t87 取引
1a, 1b,... 1n terminal 2
302 RAM
303 ROM
304
307 Settlement
322
332 Transaction ID
333 Trading account ID
334 Customer account ID
335 Transaction amount 336 Settlement order 340 Transaction group generation means 350 Transaction group settlement trial means 351 Transaction settlement trial means 352 Balance information update means 353 Repeat execution means 354 Settlement order update means 360 Balance information correction means 370 Pseudo loop determination means 371 Endpoint transaction selection Means 372 Endpoint transaction processing means 373 Origin account selection means 374 Origin transaction processing means 380 Confirmation means a1A, a1B, a1C, a1D, a1E accounts a2A, a2B, a2C, a2D, a2E accounts a3A, a3B, a3C, a3D, a3E A4B, a4C, a4D, a4E accounts a5A, a5B, a5C, a5D, a5E accounts a6A, a6B, a6C, a6D, a6E accounts a7A, a7B, a7C, a7D, a7E, a7F, a7G, a7H 8A, a8B, a8C, a8D, a8E, a8F, a8G, a8H accounts g1, g2, g3, g4, g5, g6, g7, g8 trade groups t11, t12, t13, t14 transactions t21, t22, t23, t24 transactions t31 , T32, t33, t34, t35 transactions t41, t42, t43, t44, t45 transactions t51, t52, t53, t54, t55 transactions t61, t62, t63, t64, t65 transactions t71, t72, t73, t74, t75, t76 , T77, t78, t79 transactions t81, t82, t83, t84, t85, t86, t87 transactions
Claims (9)
前記取引に関わる口座の残高情報を記憶する残高情報記憶部と、
前記取引グループに含まれる各取引における決済順序を記憶する決済順序記憶部と、
前記取引における前記決済順序を確定する処理を制御する制御部と、を備え、
前記制御部は、
前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整手段と、
前記第1の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定手段と、を備え、
前記第1の決済順序調整手段は、
前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行手段と、
前記取引決済試行手段による試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高情報更新手段と、
Nが1からLまでの間、前記取引決済試行手段による処理及び前記残高情報更新手段による処理を繰り返し実行する第1の繰り返し実行手段と、
前記第1の繰り返し実行手段による実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新手段と、
前記決済順序更新手段による更新後に、NがM+1からLまでの間、前記取引決済試行手段による処理及び前記残高情報更新手段による処理を繰り返し実行する第2の繰り返し実行手段と、
を含むことを特徴とする決済順序確定システム。 A settlement order determination system that determines a settlement order that can be settled in L (L is an integer of 3 or more) transactions included in a transaction group,
A balance information storage unit for storing balance information of an account related to the transaction;
A settlement order storage unit for storing a settlement order in each transaction included in the transaction group;
A control unit that controls processing for determining the settlement order in the transaction,
The controller is
First settlement order adjusting means for adjusting the settlement order by trying settlement of transactions included in the transaction group based on the settlement order stored in the settlement order storage unit;
A confirming means for confirming the settlement order as an order that can be settled when a trial of settlement of all transactions included in the transaction group is successful by the settlement order adjusted by the first settlement order adjustment means; Prepared,
The first settlement order adjustment means includes:
Transaction settlement trial means for referring to the balance information storage unit and the settlement order storage unit and trying to settle a transaction for which the settlement order is N (N is an integer of 1 or more and L or less);
When the trial by the transaction settlement trial unit is successful, the balance information stored in the balance information storage unit is updated on the assumption that settlement of the Nth transaction is confirmed, and when the trial fails , Balance information updating means that the Nth transaction has not been settled;
A first iterative execution unit that repeatedly executes the process by the transaction settlement trial unit and the process by the balance information update unit while N is from 1 to L;
As a result of execution by the first repetitive execution means, if there is a transaction in which the trial has failed before the settlement order in the transaction in which the trial was successful, the settlement order in all transactions in which the trial has failed is the trial Settlement order update for updating the settlement order storage unit so that it becomes M + 1 or later after the settlement order in the M transactions (M is an integer of 1 or more and less than L) which are all successful transactions Means,
A second iterative execution unit that repeatedly executes the process by the transaction settlement trial unit and the process by the balance information update unit after N is updated from M + 1 to L after the update by the settlement order update unit;
A settlement order determination system characterized by including:
前記残高情報補正手段により補正された残高情報を用いて、前記決済順序記憶部に格納された決済順序に基づき、前記第1の決済順序調整手段により前記試行が失敗した全ての取引についての決済を試行することにより前記決済順序を調整する第2の決済順序調整手段と、をさらに備え、
前記確定手段は、前記第2の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、前記第1の決済順序調整手段により前記試行が成功した最後の取引の決済順序までを決済可能な順序としてさらに確定することを特徴とする請求項1に記載の決済順序確定システム。 When the settlement order is not confirmed as an order that can be settled by the confirmation means, the balance information storage unit and the settlement order storage unit are referred to and settlement of all transactions included in the transaction group is confirmed. The balance per account is calculated under the assumption, and the balance information stored in the balance information storage unit is corrected by adding the transaction amount where the balance is a predetermined value for an account where the calculated balance is a predetermined value or less. Balance information correction means for
Using the balance information corrected by the balance information correcting unit, the first settlement order adjusting unit settles all transactions for which the trial has failed based on the settlement order stored in the settlement order storage unit. A second settlement order adjusting means for adjusting the settlement order by trying,
The confirmation means determines the trial by the first settlement order adjustment means when the trial of settlement of all transactions included in the transaction group is successful by the settlement order adjusted by the second settlement order adjustment means. 2. The settlement order determination system according to claim 1, wherein the settlement order until the settlement order of the last successful transaction is further confirmed as an order that can be settled.
前記始点取引における決済順序を、最初の順序として前記決済順序記憶部を更新し、当該始点取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、前記終点取引における決済順序を、最後の順序として前記決済順序記憶部を更新する端点取引処理手段と、
前記端点取引処理手段により更新された決済順序に基づき、前記取引グループの内、前記始点取引及び前記終点取引を除いた取引についての決済を試行することにより前記決済順序を調整する第3の決済順序調整手段と、をさらに備え、
前記確定手段は、前記第3の決済順序調整手段により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、前記決済順序記憶部に格納された決済順序を決済可能な順序として確定することを特徴とする請求項1又は2に記載の決済順序確定システム。 When the settlement order is not confirmed as an order that can be settled by the confirmation means, from each transaction included in the transaction group, the account of the transaction source matches the account of the business partner of the other transaction in the transaction group An end point transaction selection means for selecting a start point transaction that is a transaction that is not a transaction, and an end point transaction that is a transaction in which the account of the customer does not match the account of the transaction source of another transaction in the transaction group;
The settlement order storage unit is updated with the settlement order in the start point transaction as an initial order, the balance information stored in the balance information storage unit is updated on the assumption that settlement of the start point transaction is confirmed, and the end point An end point transaction processing means for updating the settlement order storage unit as a settlement order in a transaction as the last order;
Based on the settlement order updated by the end point transaction processing means, a third settlement order that adjusts the settlement order by trying settlement for transactions other than the start point transaction and the end point transaction in the transaction group. Adjusting means,
The confirmation means stores the payment order stored in the payment order storage unit when the payment attempt of all the transactions included in the transaction group is successful by the payment order adjusted by the third payment order adjustment means. The settlement order confirmation system according to claim 1 or 2, wherein the settlement order is confirmed as an order in which settlement is possible.
前記起点口座選択手段により選択された口座が前記取引元の口座となる取引である2以上の起点取引の決済順序における先後関係を入れ替えて前記決済順序記憶部を更新する起点取引処理手段と、をさらに備え、
前記第3の決済順序調整手段は、前記起点取引処理手段により更新された決済順序に基づき、前記取引グループの内、前記始点取引及び前記終点取引を除いた取引についての決済を試行することにより前記決済順序を調整することを特徴とする請求項3に記載の決済順序確定システム。 Among the accounts included in the transaction for which the trial has failed by the third settlement order adjustment means, there are transactions in which the customer is the account of the business partner, and there are two or more transactions in which the self is the account of the transaction source Origin account selection means for selecting an account to be
An origin transaction processing means for updating the settlement order storage unit by exchanging a prior relationship in the settlement order of two or more origin transactions, which is a transaction in which the account selected by the origin account selecting means is the transaction of the transaction source; In addition,
The third settlement order adjustment means, based on the settlement order updated by the origin transaction processing means, tries to settle a transaction excluding the start point transaction and the end point transaction in the transaction group. 4. The settlement order determination system according to claim 3, wherein the settlement order is adjusted.
前記第1の決済順序調整手段は、前記取引グループ生成手段により生成された取引グループに対して、前記決済順序を調整することを特徴とする請求項1乃至5のいずれか1項に記載の決済順序確定システム。 A plurality of transactions for settlement of a predetermined amount from a trading partner account to a trading partner account are accepted from the outside, and at least one account of the trading partner account or the trading partner account is selected from the plurality of accepted trading transactions Further comprises a transaction group generating means for selecting a transaction common to other transactions and generating a set of the selected transactions as the transaction group,
The settlement according to any one of claims 1 to 5, wherein the first settlement order adjustment unit adjusts the settlement order with respect to the transaction group generated by the transaction group generation unit. Order confirmation system.
取引グループに含まれるL(Lは、3以上の整数)個の取引における決済順序を記憶する決済順序記憶部と、
前記取引における前記決済順序を確定する処理を制御する制御部と、
を備えるコンピュータにおける前記取引グループに含まれる各取引における決済可能な決済順序を確定する処理を制御するための決済順序確定方法であって、
前記制御部において、
前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整ステップと、
前記第1の決済順序調整ステップにより調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定ステップと、を含み、
前記第1の決済順序調整ステップは、
前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行ステップと、
前記取引決済試行ステップによる試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高更新ステップと、
Nが1からLまでの間、前記取引決済試行ステップ及び前記残高更新ステップを繰り返し実行する第1の繰り返し実行ステップと、
前記第1の繰り返し実行ステップによる実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新ステップと、
前記決済順序更新ステップによる更新後に、NがM+1からLまでの間、前記取引決済試行ステップ及び前記残高更新ステップを繰り返し実行する第2の繰り返し実行ステップと、
を含むことを特徴とする決済順序確定方法。 A balance information storage unit for storing balance information of accounts related to transactions;
A settlement order storage unit for storing settlement orders in L (L is an integer of 3 or more) transactions included in the transaction group;
A control unit for controlling processing for determining the settlement order in the transaction;
A settlement order determination method for controlling a process for determining a settlement order that can be settled in each transaction included in the transaction group in a computer comprising:
In the control unit,
A first settlement order adjustment step of adjusting the settlement order by trying to settle a transaction included in the transaction group based on the settlement order stored in the settlement order storage unit;
A confirming step of determining the settlement order as a settlementable order when trials of settlement of all transactions included in the transaction group are successful by the settlement order adjusted in the first settlement order adjustment step; Including
The first settlement order adjustment step includes:
A transaction settlement trial step of referring to the balance information storage unit and the settlement order storage unit and attempting settlement of a transaction whose Nth order is N (N is an integer of 1 or more and L or less);
When the trial by the transaction settlement trial step is successful, the balance information stored in the balance information storage unit is updated on the assumption that settlement of the Nth transaction is confirmed, and when the trial fails , A balance update step in which the Nth transaction has not been settled;
A first iterative execution step for repeatedly executing the transaction settlement trial step and the balance update step while N is from 1 to L;
As a result of the execution by the first repeated execution step, if there is a transaction in which the trial has failed before the settlement order in the transaction in which the trial was successful, the settlement order in all transactions in which the trial has failed is the trial Settlement order update for updating the settlement order storage unit so that it becomes M + 1 or later after the settlement order in the M transactions (M is an integer of 1 or more and less than L) which are all successful transactions Steps,
A second repetitive execution step of repeatedly executing the transaction settlement trial step and the balance update step while N is from M + 1 to L after the settlement order update step;
A settlement order determination method comprising:
取引グループに含まれるL(Lは、3以上の整数)個の取引における決済順序を記憶する決済順序記憶部と、
前記取引における前記決済順序を確定する処理を制御する制御部と、
を備えるコンピュータに、前記取引グループに含まれる各取引における決済可能な決済順序を確定する処理を実行させる決済順序確定プログラムであって、
前記決済順序記憶部に格納された決済順序に基づき、前記取引グループに含まれる取引の決済を試行することにより前記決済順序を調整する第1の決済順序調整処理と、
前記第1の決済順序調整処理により調整された決済順序により前記取引グループに含まれる全ての取引の決済の試行が成功する場合に、当該決済順序を決済可能な順序として確定する確定処理と、を含み、
前記第1の決済順序調整処理は、
前記残高情報記憶部及び前記決済順序記憶部を参照し、前記決済順序がN(Nは、1以上かつL以下の整数)番目の取引の決済を試行する取引決済試行処理と、
前記取引決済試行処理による試行が成功した場合に、当該N番目の取引の決済が確定したと仮定して前記残高情報記憶部に格納された残高情報を更新し、当該試行が失敗した場合には、当該N番目の取引の決済が行われなかったものとする残高更新処理と、
Nが1からLまでの間、前記取引決済試行処理及び前記残高更新処理を繰り返し実行する第1の繰り返し実行処理と、
前記第1の繰り返し実行処理による実行の結果、前記試行が成功した取引における決済順序以前に、前記試行が失敗した取引が存在する場合、前記試行が失敗した全ての取引における決済順序が、前記試行が成功した取引の全てであるM個(Mは、1以上かつL未満の整数)の取引における決済順序より後の順序であるM+1以降となるように前記決済順序記憶部を更新する決済順序更新処理と、
前記決済順序更新処理による更新後に、NがM+1からLまでの間、前記取引決済試行処理及び前記残高更新処理を繰り返し実行する第2の繰り返し実行処理と、
を含むことを特徴とする決済順序確定プログラム。 A balance information storage unit for storing balance information of accounts related to transactions;
A settlement order storage unit for storing settlement orders in L (L is an integer of 3 or more) transactions included in the transaction group;
A control unit for controlling processing for determining the settlement order in the transaction;
A settlement order determination program for causing a computer comprising: to execute a process for determining a settlement order in which settlement is possible in each transaction included in the transaction group,
A first settlement order adjustment process for adjusting the settlement order by trying settlement of transactions included in the transaction group based on the settlement order stored in the settlement order storage unit;
A confirmation process for confirming the settlement order as an order that can be settled when a settlement trial of all transactions included in the transaction group is successful by the settlement order adjusted by the first settlement order adjustment process; Including
The first settlement order adjustment process includes:
A transaction settlement trial process that refers to the balance information storage unit and the settlement order storage unit, and that attempts to settle a transaction in which the settlement order is N (N is an integer greater than or equal to 1 and less than or equal to L);
When the trial by the transaction settlement trial process is successful, the balance information stored in the balance information storage unit is updated on the assumption that settlement of the Nth transaction is confirmed, and the trial fails , A balance update process that assumes that the Nth transaction has not been settled;
A first iterative execution process for repeatedly executing the transaction settlement trial process and the balance update process while N is from 1 to L;
As a result of execution by the first repetitive execution process, if there is a transaction in which the trial has failed before the settlement order in the transaction in which the trial was successful, the settlement order in all transactions in which the trial has failed is the trial Settlement order update for updating the settlement order storage unit so that it becomes M + 1 or later after the settlement order in the M transactions (M is an integer of 1 or more and less than L) which are all successful transactions Processing,
A second repetitive execution process for repeatedly executing the transaction settlement trial process and the balance update process between N and M + 1 to L after the update by the settlement order update process;
A settlement order determination program characterized by comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010073068A JP2011204148A (en) | 2010-03-26 | 2010-03-26 | Settlement-order determining system, method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010073068A JP2011204148A (en) | 2010-03-26 | 2010-03-26 | Settlement-order determining system, method and program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2011204148A true JP2011204148A (en) | 2011-10-13 |
Family
ID=44880702
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2010073068A Pending JP2011204148A (en) | 2010-03-26 | 2010-03-26 | Settlement-order determining system, method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2011204148A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2014089309A1 (en) * | 2012-12-05 | 2014-06-12 | Google Inc. | Methods for discovering and paying debts owed by a group |
US10410184B2 (en) | 2012-03-30 | 2019-09-10 | Google Llc | Tracking and managing group expenditures |
-
2010
- 2010-03-26 JP JP2010073068A patent/JP2011204148A/en active Pending
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10410184B2 (en) | 2012-03-30 | 2019-09-10 | Google Llc | Tracking and managing group expenditures |
US10963847B2 (en) | 2012-03-30 | 2021-03-30 | Google Llc | Tracking and managing group expenditures |
WO2014089309A1 (en) * | 2012-12-05 | 2014-06-12 | Google Inc. | Methods for discovering and paying debts owed by a group |
US9123038B2 (en) | 2012-12-05 | 2015-09-01 | Google Inc. | Methods for discovering and paying debts owed by a group |
CN104995647A (en) * | 2012-12-05 | 2015-10-21 | 谷歌公司 | Methods for discovering and paying debts owed by a group |
KR101624682B1 (en) | 2012-12-05 | 2016-05-26 | 구글 인코포레이티드 | Methods for discovering and paying debts owed by a group |
KR20160062212A (en) * | 2012-12-05 | 2016-06-01 | 구글 인코포레이티드 | Methods for discovering and paying debts owed by a group |
KR101676453B1 (en) | 2012-12-05 | 2016-11-15 | 구글 인코포레이티드 | Methods for discovering and paying debts owed by a group |
KR20160133009A (en) * | 2012-12-05 | 2016-11-21 | 구글 인코포레이티드 | Methods for discovering and paying debts owed by a group |
CN104995647B (en) * | 2012-12-05 | 2017-11-17 | 谷歌公司 | For finding and paying by the method for group's debt due |
KR102023586B1 (en) | 2012-12-05 | 2019-09-23 | 구글 엘엘씨 | Methods for discovering and paying debts owed by a group |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20220366491A1 (en) | Incrementally perfected digital asset collateral wallet | |
US11037111B2 (en) | Method for issuing currency and making payment by managing balance database for each block in blockchain network and server using same | |
CN110020948A (en) | Assets source tracing method and device, electronic equipment based on block chain | |
US20200294046A1 (en) | Selection of digital properties for transactions | |
CN110020936A (en) | Assets management method and device, electronic equipment based on block chain | |
US20230252569A1 (en) | Computer Implemented Method for Compiling a Portfolio of Assets | |
EP3469539A2 (en) | A pareto-based genetic algorythm for a dynamic portfolio management | |
CN109993517A (en) | Instant chain type method of payment, computer equipment and storage medium | |
CN112884575A (en) | Contract transaction system | |
JP2011204148A (en) | Settlement-order determining system, method and program | |
US8341054B2 (en) | System and method for bank account management and currency investment | |
US20240062204A1 (en) | Eliminating the race condition and infinite approval loophole for smart contracts and other blockchain transactions | |
WO2016016719A2 (en) | Online trading systems and methods | |
CN109544329B (en) | Method, device and system for matching | |
CN116151982A (en) | Transaction data processing method, device, equipment and medium for hot spot account | |
KR102142275B1 (en) | Apparatus and method for approving deposit of cryptocurrency | |
Roig et al. | Optimal allocation strategies in platform trials | |
CN110874789B (en) | Data processing method and device and terminal | |
WO2020041794A1 (en) | A financial transactions system and method utilizing blockchain transfers | |
US20220309478A1 (en) | Optimizing execution of transaction requests | |
KR20200048530A (en) | System for controlling reserve ratio of cryptocurrency based on block chain | |
JP7350205B1 (en) | A method of providing stablecoin services on a blockchain network and a blockchain system using the same | |
US11620707B2 (en) | Systems and methods for prevention of manipulation and gaming in electronic intraday auctions | |
Lommers et al. | The Case for Stochastically Dynamic AMMs | |
US20240112157A1 (en) | Liquidation management operations for improved ledger performance |