WO2005043271A2 - ソフトウェア生成方法 - Google Patents

ソフトウェア生成方法 Download PDF

Info

Publication number
WO2005043271A2
WO2005043271A2 PCT/IB2004/003266 IB2004003266W WO2005043271A2 WO 2005043271 A2 WO2005043271 A2 WO 2005043271A2 IB 2004003266 W IB2004003266 W IB 2004003266W WO 2005043271 A2 WO2005043271 A2 WO 2005043271A2
Authority
WO
WIPO (PCT)
Prior art keywords
word
processing
words
program
output
Prior art date
Application number
PCT/IB2004/003266
Other languages
English (en)
French (fr)
Other versions
WO2005043271A1 (ja
WO2005043271A3 (ja
Inventor
Osamu Arai
Original Assignee
Catena Corp
Osamu Arai
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 Catena Corp, Osamu Arai filed Critical Catena Corp
Priority to JP2005515082A priority Critical patent/JPWO2005043271A1/ja
Publication of WO2005043271A1 publication Critical patent/WO2005043271A1/ja
Publication of WO2005043271A2 publication Critical patent/WO2005043271A2/ja
Publication of WO2005043271A3 publication Critical patent/WO2005043271A3/ja
Priority to US10/574,703 priority patent/US20070169006A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design

Definitions

  • the present invention relates to a software generation method based on a mathematical concept, and more particularly, to a software generation method using an adjacency matrix and a topology logic in a Lyee methodology.
  • declarative programming in which programming is performed using declarations, which are requirements definitions themselves, includes artificial intelligence, expert systems, logical proofing (logical reasoning), inference (inference), and user intelligence gathering. It is used in non-computational applications.
  • Declarative programming is not a control procedure, The advantage of declaring the relationship between the data for which requirements are defined and performing programming based on the declaration is that unlike requirements in procedural programming, where procedures such as control procedures must be explicitly specified, requirements are defined. It can be implemented correctly.
  • declarative programming also has a problem that its execution efficiency is not high due to the structure of execution control.
  • languages for declarative programming are difficult to use.
  • Languages for performing declarative programming include logical languages that use logical expressions (for example, PROLOG) and functional languages that describe the state of an object as mathematical functions (for example, LISP).
  • PROLOG logical expressions
  • LISP functional languages that describe the state of an object as mathematical functions
  • a declarative language has a procedural logic mechanism to execute the declaration, because just declaring does not generate a value.
  • the logic mechanism of these procedures has many conditions to be able to execute any declaration, requires knowledge of mathematics and logic, and is difficult to use. For this reason, it is not widely used as a programming language. This is because procedural programming using a procedural language that has a structure similar to that of human natural language is more widespread.
  • Object-oriented programming is a programming technique that integrates data and procedures (called methods) that operate on it into a unit called an object, and describes a program as a combination of objects. Since the program is composed of highly independent modules called objects, the range of effects of changes / modifications is limited, and there are merits such as reuse of objects in units.
  • Patent Document 3 WO 99/49387 Pamphlet
  • Lyee gover nme nta ju me thodologyforsoi twar E The ending of providenc E. Read "Lee”. The inventor is Fumio Negoro. A new and very promising methodology called) was proposed. Lyee is a new way to automatically develop software from requirements.
  • L e e e although it is declarative, it does not require a special logical mechanism to execute the declaration, and execution of the declaration is a procedure of simple value assignment, similar to procedural programming. Therefore, the language used may be a widely used procedural language. In other words, Lyee has the declarative advantage of being able to implement requirements accurately and the procedural advantage of using a procedural language that is easy to write.
  • the declared abstraction target is a variable.
  • the declared variable is called a word in Lyye.
  • a specification is declarative in that the unit of abstraction declared is that the order of the description is excluded, and that the bidirectionality from the right side to the left side and from the left side to the right side is expressed as an equation. That is.
  • In Lyee words eliminate the order of description, but are not bidirectional, which simplifies the framework. ,
  • the main elements of a word declaration are the word name, the definition formula, the calculation conditions for the definition formula, input / output attributes, and value attributes.
  • the definition expression is a relational expression indicating a relationship with another word.
  • the procedural language framework that implements the elimination of the order of declarations, while implementing it, is a fixed-form program structure provided by Lyye.
  • Lyye The procedural language framework that implements the elimination of the order of declarations, while implementing it, is a fixed-form program structure provided by Lyye.
  • a procedural language must solve the ordering problem in some way.
  • the declarative language solves it. Lyee, which uses a procedural language, solves this problem by using a program structure.
  • the program structure is a fixed-structure module that executes a word-by-word declaration (hereinafter, “declaration”). This is called a “word execution module”. ), And these modules are grouped in units called pallets.
  • the order of execution of the declaration execution modules in the palette can be any array.
  • the execution control module in the palette controls execution so that execution of the declaration execution module is repeated until execution of all the declaration execution modules in the palette is completed (that is, as long as values are generated).
  • the palette is a W02 palette for executing the input word declaration, a W03 palette for executing the calculation conditions in the output word declaration, and a W04 palette for executing the definition formula and executing the output in the output word declaration.
  • These three types of pallets form a set and form a collective unit called the basic structure.
  • the Lyee structure program is divided into basic structure units, the basic structure is divided into three types of palettes, and the palettes are divided into declaration execution modules.
  • the basic structure is created in units of output logic (that is, groups of words that are output simultaneously on the same medium).
  • PRD Process Route Diagram
  • the entire program in Ly e is composed of a fixed-form declaration execution module that executes word-wise declarations, and the method of configuring the entire program with these declaration execution modules is also standardized. Therefore, it is possible to automatically generate a program by substituting the declaration of the requirement in word units into the declaration execution module of this fixed structure.
  • LyeeALL The automatic generation of a program by Lyee is realized by a tool called "Lye eALL". Ly eALL, so to speak, automatically substitutes the declarations of the requirements into the predetermined blanks of the code of the declaration execution module of a fixed structure (called “template”.
  • the template is a template). It is a tool that constructs one program by configuring an execution module according to a predetermined method.
  • Lyee methodology In software development using the Lyee methodology, engineers are divided into two groups, each of which performs two specialized tasks.
  • One team is proficient in technologies related to the external environment in which the Lyee structure program runs, such as the OS, midware, and database, and sets parameters for each external environment in the Lyee structure program template.
  • the other team defines user requirements and declares requirements according to the Ly ee methodology in order to implement the requirements in the template of the Ly ee structure program.
  • the development of this method of division of labor enables the development of Ly ee methodology, which eliminates the need for all programmers to have skills related to a wide range of external environments, and eliminates the shortage of human resources with such skills. it can. (4) Issues of conventional Lyee structure
  • the Lyee methodology has great advantages, such as accurate implementation of requirements, automation of code generation, and ease of maintenance.
  • the structure of its repetition and division also has issues. It is said that the execution speed is slow due to the repetitive processing, and the program size is large due to the divided structure.
  • Lyee divides requirements into units called basic structures and captures specifications. Group of words with explicit information about the execution order, such as screen transitions, database key relationships, etc.
  • the present invention relates to a method of performing a topological 'sort on the entire program by eliminating the division unit of the conventional Lyee structure program. This aims to improve software execution speed and program size by using the Lyee methodology.
  • the present invention provides a user requirement implemented as one program for each logical entity with an access condition, for each word on the logical entity, for a word name, a definition formula, and a definition formula.
  • L2 processing input word attribute check processing
  • L processing output word processing, etc.
  • I2 processing logical input processing
  • 04 processing logical output processing
  • the word unit declaration defined in the first step is subjected to L2 processing (input word attribute check processing), L processing (output word value generation processing), and I2 processing.
  • L2 processing input word attribute check processing
  • L processing output word value generation processing
  • I2 processing I2 processing.
  • a program that executes in the shortest order is created in units of processing (logical input processing), 04 processing (logical output processing), and software generation using the Lyee methodology is more efficient.
  • all the functions of each of these steps can be automated, so eventually the automatic processing can be performed consistently from the elimination of repetitive processing to software generation, and the software production speed and efficiency are further improved.
  • the ⁇ graph '' is a node that represents each declared execution unit included in the requirements issued by the user who is the software development requester, and a ⁇ b (Defines ⁇ ⁇ '' as a sign that b is created from a The same shall apply hereinafter.)
  • a semi-order relationship (or a full-order relationship) between the start point and the end point is indicated by an arrow, for example, the software may be programmed with such functions, or may be the software concerned. May be written in ROM (Read One n Memory).
  • topological means that a depth-first search (described later) is performed on the directed graph obtained above, and nodes are acquired when returning to the search path from where the end was reached.
  • a function that arranges a node sequence (numerical sequence).
  • such functions may be programmed as software, or the software may be coded as R
  • the directed graph obtained above may be represented by an adjacency matrix, and a depth-first search may be performed on the graph to generate a zero-power matrix.
  • “Search” means the power of depth-first search (Depth—First Search), breadth-first search (Breadth—First Search), iterative deepening (Iterative Deeping), and heuristics. search (He uristic S earch), Hill. climbing (H i 1 1 C 1 i mb ing), a single stroke of the best-first search (B est- F i r. st S earch) s Euler (Eu 1 er), Dijkstra (Dijkstra) Refers to various algorithms including the method.
  • the function may be programmed as software, or the coded version of the software may be written into ROM (ReadOn1yMemory).
  • a program (software), a program generation device, a program processing device, a tool (including both as a device or as software), a software development device for producing “software to be developed” as different embodiments of the present invention.
  • the software development support device and the software development management device define the user requirements to be implemented as one program for each logical entity with access conditions, for each word on the logical entity, for the word name, the definition formula, and the definition.
  • L2 processing input word attribute check processing
  • L processing output word
  • I2 processing logical input processing
  • 04 processing logical output processing
  • the present invention is further realized as software produced by the above-described “method of producing software to be developed”, and as a recording medium on which the software is mounted or an apparatus (hardware) on which the software is mounted.
  • the user requirements to be implemented as one program are defined for each logical entity with an access condition, for each word on the logical entity, a word name, a definition formula, and the execution of the definition formula.
  • L2 processing input word attribute check processing
  • L processing output word processing
  • I2 processing I2 processing
  • the present invention provides a software as a template of software code used for producing software by the above-described “method of producing software to be developed”, and a recording medium on which the software is mounted or a recording medium on which the software is mounted. It is also realized as a device (hardware) with software installed.
  • the present invention provides a method of extracting information (document (paper, data)) extracted from the requirements according to the above-described “method of producing software to be developed”, and information (document (document (data)) extracted by the extraction method. Paper, data)), as a method of using the extracted information, or as an information recording medium on which such information is mounted, or software in which the method of extracting / using information is coded.
  • the recording medium / device (hardware) on which the software is mounted may be realized as information extracted from software development requirements including information to be associated that can be realized.
  • the processing of the declaration execution module for generating output data in the program including the word-based declaration execution module is completed with a minimum number of executions by eliminating useless repetition. Can be reduced. More specifically, the following points become possible.
  • Word-based declaration execution units that are no longer required by optimal ordering, such as path action elements, are deleted.
  • the execution condition of the path action element which is the order information that must be implemented in order to maintain the meaning of the requirement, is reflected in the partial order relationship definition of the declaration execution unit in other word units, and the requirement Can retain meaning.
  • Topological sort is performed on the word-based declaration execution units (not including path action elements) obtained in this way, and the word-based declaration execution units are rearranged in the optimal order. This makes it possible to avoid unnecessary repetition and execute the program with the minimum number of executions.
  • the present invention eliminates the division unit of the conventional Lyee structure program and performs the topological sort on the entire program, thereby improving the above-mentioned problem of the conventional technology. According to the present invention, it is possible to improve the execution speed of software developed by the Lyee methodology and improve the program size.
  • Patent Document 6 Regarding the technique of performing topological sorting on a Lyee structure program, Patent Document 6 by the same applicant is cited and is incorporated as a part of the disclosure.
  • the division into basic structures is a declaration that captures the requirements of what group of words should be output and under what conditions.
  • the input / output attribute was added to the element of the word-based declaration.
  • the input / output group (logical entity) to which each word belongs and the input / output group Whether input or output is conditional is also a requirement to be declared.
  • the division structure of Lyee software is a structure in which declaration execution modules, which are the smallest modules, are grouped according to certain rules.
  • the structure is shown in Fig. 1 (a) and (b).
  • Sync range The modules that make up the program are first grouped into units called “synchronization ranges” in Figure 1 ( a ).
  • the synchronization range is a set of requirements that the computer must execute in response to an event (for example, a command such as pressing a button or selecting a menu) that is a user's instruction to execute a program. Means the range of processing.
  • a synchronization range is a group of modules that are executed with the same event as the execution condition. In Lyee, the completion of this synchronization range processing is called “synchronization”. Completion of the processing of the synchronization range means completion of the generation and output of the output words specified in the requirements for the event.
  • the modules within the synchronization range are grouped into basic structural units, as indicated by 101 in FIG. 1 (a).
  • Computer input / output processing is performed not in units of data but in units of data.
  • the set of words that are input or output to the same definition is called a logical unit in Lyee.
  • a logical body is a unit that holds the value of a word, such as a screen, a file, a form, or a message.
  • the basic structure is a group in which modules related to the same output logic are grouped.
  • the role of the program is to generate and output the value of the output word specified by the event by the user, but the output performed within the synchronization range of one event is not limited to one.
  • Is output, and the synchronization range is grouped into several basic structures.
  • the modules in the basic structure are grouped into three groups according to their types.
  • the genorape of the moduinore inside the building is called a palette in Lyye.
  • the three pallets are called W02 pallet, W03 pallet, and W04 pallet, respectively.
  • the W02 palette is a set of modules related to the input of input words.
  • the W03 palette is a set of modules involved in determining the calculation conditions for the definition formula of the output word.
  • the W04 palette is a set of modules involved in generating values by executing the definition expression of output words and outputting values.
  • the target to be optimized by topological sort is the processing executed by the declaration execution module that is a component of Lyee software.
  • declaration execution modules There are two types of declaration execution modules, one is a logical element and is a module for establishing the value of a word. The other is an action element, which is a module that performs processing other than the establishment of values, such as input / output processing.
  • Patent Document 6 by the same applicant treats a logical element that satisfies a value as an element of a directed graph and an adjacent matrix, expresses it by a mathematical model, and discloses an embodiment of topological sort.
  • the action elements can be treated as elements of the directed graph and the adjacency matrix, and can be subject to topological sorting.
  • the major difference between a logical element and a working element is that the logical element acts on only one word (the action of generating a value).
  • the force acting element acts on two or more words at the same time. For example, the path action element (specifying the next basic structure to be executed) operates on the set of words, basic structure, and the output action element (outputting the output word) changes the set of words Act on.
  • L2 is a declaration execution module that checks whether the attribute of the input word meets the requirements. Under any conditions, the condition under which the processing of L2 can be executed is that the value of the input word has been fetched from the medium into the memory area (it has been input). Therefore, the L2 process targeted for the topological sort can be thought of as starting at I2, which inputs the value of L2.
  • Event commands are also treated as one of the input words. [0 0 4 3]
  • the output word generation process is realized by two modules, L 3 (execution of calculation formula) and L 4 (execution of definition formula). Furthermore, when the output word a has a plurality of definition expressions (the word in such a case is called an equivalent word), L3 and L4 are provided by the number of pairs of the definition expression and the calculation condition.
  • the condition under which the generation process of the word a can be executed is only required that all the defining expressions of the word a and all the starting words used in the calculation conditional expression have been determined.
  • the target of the topological sort only needs to execute the definition formula of the words b, c, d, and e first.
  • the target of the topological sort is all of the L3 and L4 processing sets for each output word, and the starting point is the L of the input word used as the starting point in those defining formulas and calculation conditions. This is a set of 2 processing and L 4 and L 3 processing of the output word.
  • I2 is a module that performs processing of taking (input) values from the medium into the memory. Therefore, the conditions under which the processing of I2 can be performed under any conditions are unconditional (that is, they do not depend on other processing).
  • the I2 process subject to topological sorting has no starting point. (However, if the input is from a file, (The value of the key word that is the key must be established)
  • O 4 is a module that writes (outputs) a word value from the Lyee software area to the output buffer on the memory (output). Therefore, under any conditions, the condition under which the processing of O 4 can be executed is that the value of the output word to be output has been established (that is, one L 4 has been executed).
  • the starting point of the O 4 process that is the target of topological sorting can be regarded as the output word of the output target.
  • the initialization of the processing result recording area is not a process for the mechanism of the repetitive structure, so it is also necessary for the integrated Lyee structure.
  • the route action element is a module that performs processing for specifying a pallet to be executed next.
  • the path action element plays a role of linking a pallet, which is a division unit of a program, and a basic structure, which is a collection of the pallets.
  • Figure 2 shows a system screen where the user inputs data into data item c and data item d, and presses the a or b button to obtain the value in data item g.
  • System. 701 is the input data field of data item c
  • 702 is the input data field of data item d
  • 703 is the output data field of data item g
  • 704 is execution button a
  • 705 is execution Button b.
  • the execute button a is pressed, the value of g is calculated by the definition expression c + d
  • the execute button b is pressed, the value of g is calculated by the definition expression c X d.
  • the execute buttons a and b are conditions that determine which of the two defining expressions for generating the value of g is executed, since both are not pressed at the same time.
  • the program on the screen in Fig. 2 is shown in Fig. 3 in terms of the basic structure division unit.
  • BS1, BS2, and BS3 in Fig. 3 each have a basic structure.
  • the basic structure BS1 is the basic structure of the output logic to the screen shown in FIG. BS 1 includes an input word a and an input word b, which are execution buttons, an input word b and an input word c, which are input data items, an output word g, which is an output data item, and a path action element Xr .
  • the basic structure B S 2 is a basic structure (the medium is a file) for calculating the value of the output data item g by the expression c + d when the execution button a is pressed. Contains the word e that records the result of the expression c + d.
  • the basic structure B S 3 is a basic structure (the medium is a file) for calculating the value of the output data item g by the expression c X d when the execution button b is pressed. Contains the word ⁇ that records the result of the calculation of the expression c X d.
  • the basic structure for calculating the value of the output word g after the user enters data on the screen (BS1 has been executed) is BS2 or BS3, but specifies which should be executed This is the path action element Xr .
  • the value of the output word g holds for the word e or the word f.
  • the conventional Lyee structure has a split structure, and since the repetitive processing is performed for each split unit, a pallet function that calls and executes each module in the pallet (installed by the number of pallets) and their pallet functions Two kinds of control modules were required: a pallet chain function (one for each program) to call and execute itself.
  • the entire program is integrated and ordered, so it is sufficient if there is one control module that calls a module in the program for the entire program.
  • FIG. 4 is a diagram showing the relationship between the words in FIG. 3 by a directed graph.
  • Words a, b, c and d which are input words belonging to the basic structure BS1, are the extreme start points of the word network represented by the directed graph.
  • the word Xr which is a path action element belonging to the basic structure BS1
  • has the value a (a true / false judgment of the basic structure determination to be executed next).
  • word b, word c and word d so they are linked to the four words by arrows starting from those four words.
  • the word e belonging to the basic structure BS 2 and the word f belonging to the basic structure BS 3 have the value Since c , word d, and word Xr are required, they are linked to three words each by arrows starting from these three words. Since the output word g belonging to the basic structure BS1 needs the word e or the intermediate word ⁇ ⁇ ⁇ in order for the value to be established, it is linked to the two words by arrows starting from these two words .
  • an adjacency matrix F 1 representing the basic structure B S 1 (90 1) of the input word shown in FIG.
  • the matrix of F1 is composed of these elements.
  • Word x r is a routing action element, as shown in the directed graph of Figure 4, the words as a starting point a, because it has a word word word d, the rows of end-point word x r, the intersection of these starting words the starting point It becomes "1" to indicate that there is.
  • Equation 2 the adjacency matrix F2 representing the combination of the basic structures B S2 and B S3 (hereinafter, referred to as the basic structures B S2 & B S3) is shown in Equation 2 below.
  • the adjacency matrix F 3 of the set that handles the output words of the basic structure B S 1 is shown in Equation 3 below.
  • Adjacency matrix of basic structure B S 1 (output word)
  • the matrix of F 3 is composed of only one word g. Since the word g does not use itself as the starting point, the intersection is “0”.
  • connection matrix that links the basic structures by indicating the relationship between the words that are the elements of each basic structure and the words that are the elements of other basic structures
  • the connection matrix will be described.
  • connection adjacency matrix for linking basic structures is a connection adjacency matrix that represents the relationship between an arbitrary basic structure and a basic structure that includes a word that can be the starting word of a word belonging to it. You can see that there is. Because, as shown in the directed graph, since there is only a relationship between words from the start word to the end word, the relationship between basic structures is also similar to that from the basic structure including the start word to the end word. This is because there is only a relationship toward the containing basic structure, and no inverse relationship (the intersection matrix for such a relationship between the basic structures has all intersections at 0).
  • Equation 4 is a connection adjacency matrix F C1 that indicates a relationship from the basic structure B S 1 (input) (start word) to the basic structure B S 2 & B S 3 (end word).
  • the adjacency matrix FC 1 is composed of words a and b, which are elements of BS 1 (input), when words e and f, which are elements of the basic structure BS 2 & B S 3, are placed as end-point words.
  • Word c, word d, and word are used as starting words, indicating the relationship between the two basic structures.
  • the word e and the word f use the word c, the word d, and the word xr as starting words. Therefore, in FC1 , the intersection of the line of the end word e and the end word f with the start words c, d, xr is "1", and the intersection with the other start words is "0".
  • Equation 5 represents an adjacency matrix FC2 indicating a relationship from the basic structure BS L (input) and the basic structure BS 2 & B S 3 (start word) to the basic structure BS 1 (output) (end word).
  • the adjacency matrix FC 2 is obtained by arranging a word g, which is an element of the basic structure BS 1 (output), as an end word, BS appearing before that in the directed graph: (input), words a , elements of BS 2, BS 3, Words Word c, Word d, Word xr Word e , and the state where words are used as the starting words, indicating the relationship between the two durps.
  • word g uses words e and f as the starting words. Therefore, in FC2, the intersection between the line of the end word g and the start words e and f is “1”, and the intersection with the other start words is “0”.
  • connection adjacency matrix that has meaning in the links between the basic structures that make up the system of Example 1.
  • connection adjacency matrix that has meaning in the links between the basic structures that make up the system of Example 1.
  • Equation 6 is a connection adjacency matrix F C 3 that indicates that there is no relationship between the basic structure BS 2 & BS 3 (start word) and the basic structure BS 1 (input) (end word).
  • Equation 7 is a connection adjacency matrix F C4 indicating that there is no relationship between the basic structure B S I (output) (start word) and the basic structure BS (input) (end word).
  • Equation 8 is a connection adjacency matrix FC5 indicating that there is no relationship between the basic structure BS 1 (output) (start word) and the basic structure BS 2 & B S 3 (end word).
  • Equation 9 represents the example system as one adjacency matrix F.
  • 1001 is F1
  • 1002 is F2
  • 1003 is F3
  • 1004 is FC1
  • 1005 is FC2.
  • a joint adjacency matrix in which all the intersections of the matrices are 0 constitutes 1006 for FC3, 1007 for FC4, and 1008 for FC5.
  • one system composed of two or more basic structures can be represented by one adjacency matrix.
  • the entire system can be represented by one adjacency matrix. Therefore, the adjacency matrix of this system is subjected to the topological sort disclosed in Patent Document 6 by the same applicant, and all the words are determined. Word-based programs are rearranged in an optimal order so that the state of the value is determined with the minimum number of executions (ie, generation of all output words is completed).
  • the adjacency matrix F of the system in Example 1 As shown in Fig. 6, the starting word whose value is 1 The intersections of are all within the lower left triangle (1 3 0 1). As mentioned in Chapter I, this means that the words are in optimal order. Therefore, the adjacency matrix F of 3 ⁇ 49 has already been topologically sorted, and given the initial state vector of words, the order of words that can complete output word generation with the minimum number of executions becomes It can be said that there is.
  • Word-based programs arranged in the optimal execution order by topological sorting can generate the values of all output words in one round.
  • minimum number of executions This is because, when viewed as a whole system, there may be cases where the same calculation formula needs to be used repeatedly by placing a temporary storage area, such as aggregation processing.
  • "repetition” in this case is not a wasteful repetition.
  • the number of data to be aggregated minus 1 is the minimum number of repetitions.
  • Such an aggregation process can also be expressed in one adjacency matrix using a joint adjacency matrix.
  • a topological sort has been described as an example of the search technique, but other search techniques may be used.
  • the definition of the adjacency matrix is included in this paper to facilitate understanding, but is not an essential step. In other words, it is within the scope of the present invention that the definition of the relationship between declarations, directly or through the creation of a directed graph, leads to a search for topological 'sorting' without defining an adjacency matrix. The goal can be achieved.
  • the adjacency matrix F of the system shown in the previous section functions as a function to generate output word values, and is topologically sorted, so that all output words can be generated with a minimum number of executions. Completion is verified by a calculation operation that applies the state vector of a word disclosed in Patent Document 6 by the same applicant. If the value of the output word g is determined, it can be said that the adjacency matrix F functions as a function.
  • the system of Example 5 does not include the repetition processing such as the above-described aggregation processing, and thus, if the state of the value of the output word g is determined in one round processing, it can be said that the processing has been completed with the minimum number of executions.
  • Equation 1 0 The adjacency matrix F of Equation 9 (that is, the system of Example 1) is multiplied by the state vector X of Equation 10 (that is, input to the system of Example 1). The state of the value of the word that changes by the FX calculation processing will be described for each end-point word.
  • a 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null
  • the calculation of the end word b during the first round processing is as follows because the state of the value of the word in Table 2 is used.
  • words a and b are the two alternate instruction buttons on the screen, so that when either one is selected, the state of both values is determined.
  • the calculation of the end word c during the first round processing uses the state of the value of the word in Table 3 and is as follows.
  • the calculation of the end point word d during the first round processing is as follows because the state of the value of the word in Table 4 is used.
  • (+1) + (+1) + (+1) + (+1) + (+1) + (+1) + (+1) + (+1) + (+1) + (+1) + (+1) (+1)
  • the calculation of the end word Xr during the first round processing is as follows because the state of the value of the word in Table 5 is used.
  • Word x r word a which the start word, b, c, the value of d states have already established, Sunawa Chi, definition equation execution conditions of the word x r is a routing action elements shown in Table 1 (1) and because (2) is satisfied, it changes the value of a word x r state from null Committed to (+1). As a result, the state of the value of each word after completion of the word X r rows in one round processing is as shown in Table 6 below.
  • the calculation of the end word e during the first round processing is as follows because the state of the value of the word in Table 6 is used.
  • the calculation of the end word f during the first round processing uses the state of the value of the word in Table 7 and is as follows.
  • the execution conditions of words e and f are alternatives, so if either condition is confirmed as true, the other condition is confirmed as false and both The state of the value will be determined.
  • the calculation of the end point word g during the first round processing is as follows because the state of the value of the word in Table 8 is used.
  • the adjacency matrix F is arranged so that word-unit programs are executed in the optimal order by topological sorting, the state of the values of all words is determined by executing one round of calculation processing. The output word g was satisfied.
  • the execution condition of the path action element is equal to the condition for executing the definition formula of the set (consisting of one or more) of all the words belonging to the basic structure specified by the path action element. This is because all of the words of the basic structure are executed when the condition of the path action element is satisfied. Therefore, the execution condition of the route action element can be transferred to the condition of the word belonging to the basic structure specified by the route action element.
  • the path action element simply indicates that the condition for executing the next basic structure is satisfied (the input words c and d have values and the buttons a or b are pressed). It only makes sense. This means that removing the route action element does not change the meaning of the system. Therefore, after performing the operation of replacing the execution condition of the path action element with the execution condition of the word of the basic structure specified by the satisfaction of the condition, the path action element can be removed from the adjacency matrix of the entire system.
  • Fig. 7 shows the relationship between words in the system of Example 1 in a directed graph with the path action element removed.
  • word x r is a routing action element
  • the relationship between the word e and the word f and start word is shown in accordance with definition equation execution conditions defined defined expressions Table 1 1 above.
  • the word e is defined as the starting words
  • word a definition expression execution condition “Execution button a was pressed”
  • Equation 12 If the system of Example 1 with the path action element removed is represented in an adjacency matrix according to the directed graph of FIG. F 1 ′ in Equation 12 is the adjacency matrix of the basic structure BS 1 (input). The word that is a path action element has been removed from the element.
  • Number 1 3 F 2 ' is the adjacency matrix of the basic structure BS 2 & B S 3 c
  • Equation 14 is an adjacency matrix t of the basic structure BS (output).
  • FC 1 in Equation 15 is a connection adjacency matrix indicating the relationship from the basic structure BS 1 (input) to the basic structures BS 2 & BS 3. Since the path action element is removed, the word X r has been removed as an element of the starting point word. Word e and word f have new words a and b as the starting words, respectively, by changing the execution condition of the path action element as shown in Table 11. Therefore, the end word e has an intersection with the word a in addition to the start words c and d. The end point word ⁇ has an intersection with the word b in addition to the start point words c and d.
  • FC 2 ′ in Equation 16 is a connection adjacency matrix indicating a relationship from the basic structure BS 2 & B S 3 to the basic structure BS 1 (output). Since the path action element is removed, the word X r has been removed as an element of the starting point word.
  • FC4 'in Equation 18 is a connection adjacency matrix indicating that there is no relationship from the basic structure BS 1 (output) to the basic structure BS 1 (input). Since the path action element is removed, the word X r has been removed as an element of the starting point word.
  • FC5 in Equation 19 is a connection adjacency matrix indicating that there is no relationship from the basic structure BS (output) to the basic structure BS2 & BS3.
  • the adjacency matrix F of the system can be represented by the adjacency matrix F 'shown in Equation 20 below, by replacing the condition of the path action element and deleting the path action element.
  • Fl ', F2, F3', FC1, FC2 'and 0 show how the adjacency matrix of the basic structural unit and the joint adjacency matrix are integrated to represent the entire system.
  • the adjacency matrix is composed of a, b, c, d, e, f, and g on the right side of the matrix.
  • Fl ', F2, F3, FC1, FC2, FC3', FC4, FC5 are integrated to form F.
  • Figure 8 shows this. In FIG.
  • the portion 1201 'is Fl, 1202 is F2, 1203 is F3', 1204 is FC1, and 1205 is FC2 '.
  • the joint adjacency matrix in which the intersections of the matrices are all 0 is FC3, 1206, FC4 'is 1207, and FC5 is 1208.
  • one system consisting of two or more basic structures can be represented by one adjacency matrix, excluding the path action element.
  • the adjacency matrix F ' which shows the structure of the system excluding the path effect element shown in the previous section, has the same function and function as the adjacency matrix F, which is the structure before the path effect element is eliminated.
  • F ' is a function that functions the same as F. It is also verified that the output word generation can be completed with a minimum number of executions by performing the topological sort. If the state of the value of word g is determined in one round, the system F 'in Example 1 can be executed with the minimum number of executions.
  • Equation 21 the initial value of the state vector of a word is “null (undecided)” for all elements.
  • the adjacency matrix F 'of Equation 20 (that is, the system of Example 1) is subjected to a calculation process using the state vector X' of Equation 20 (that is, input to the system of Example 1).
  • the state of the value of the word, which is changed by the calculation of F'X, will be described for each end-point word.
  • a 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null + 0-null
  • the state of the value is determined and changes from null to (+1). That is, this indicates that the value has been determined by the input.
  • the state of the value of each word after completion of the word a during the one round process is as shown in Table 12 below.
  • the state of the value of the word in Table 12 is used in the calculation processing, so the calculation of the end word b during the first round processing is as follows.
  • the state of the value is determined and changes from null to (+1).
  • the state of the value of each word after completion of the word a during the one round process is as shown in Table 13 below.
  • the state of the value of the word in Table 14 is used in the calculation processing, so the calculation of the end point word d during the first round processing is as follows.
  • the calculation of the end word f during the first round processing is as follows.
  • the state of the value of the word in Table 17 is used in the calculation processing, so the end point g during the first round processing
  • the calculation of the point word g is as follows.
  • the adjacency matrix F ′ is arranged so that word-unit programs are executed in the optimal order by topological sorting, so that all word values are determined by executing one round of calculation processing.
  • the value of the output word g was established.
  • the adjacency matrix F 'excluding the words of the path action element is given the initial value of the state vector (by inputting), so that the state of all the word values is determined in the same way as the adjacency matrix F. It can be seen that the value of the output word g was generated. Therefore, it was verified that the adjacency matrix F, a system with a path action element, and the adjacency matrix F, a system without a path action element, have equivalent processing functions as a system.
  • L yee Provide each level of performance when applying software autonomous development technologies such as registered trademark. For example, if this is not integrated and has a plurality of basic structures as they are, performance as high as that obtained by the invention of the present application cannot be obtained. The performance according to the invention according to (1) cannot be obtained.
  • Any program can be described only in a recursive way. Any program written in a procedural programming language (eg, C, Java, etc.) can be written with a whi1e program that performs the same role as a recursive program. This shows that while programs can theoretically do anything.
  • a procedural programming language eg, C, Java, etc.
  • word-based programming cannot use itself as the starting word.
  • a structural action element Vector of Clear is defined for the tally.
  • an action element is generally a kind of word with a predicate structure.
  • the structure of the program code is the same as a word.
  • the main difference from words is that they deal with two or more words at the same time. Its meaning is due to external interface and control structure Clear the route and area.
  • the adjacency matrix of the program (the matrix of the whole program) is integrated into one matrix using the divided adjacency matrix and the connection matrix that merely transfers states.
  • the connection matrix indicates that words on other groups are used as the starting words.
  • Example 2 The value of each record of a certain word in the file; ⁇ , is summed in order from the beginning, and the totaled result is totaled into words 3 and 7 .
  • the adjacency matrix (one path matrix) of the part of the program to be reused in FIG. 10 is shown below.
  • F2 ⁇ 4 [ ⁇ 0 1 1: connection matrix from x t , x 2 , x s to 4 F 5 " ⁇
  • F3 x 6 0 connection matrix from x 4 to x Sf x 6, x 7 7 L 0 - a connection matrix to the mx lt x 2, x 3.
  • F3 is the connection matrix to x 5, x 6> from x 4.
  • / ⁇ Is understood as the action element for the output from to ⁇ , the power to F 3 X 4 or X 5 .
  • Lyee's specification is expressed in word system, Lyee's specification is expressed as follows.
  • B is called a chain if the nonempty subset 8 of the ordered set (A, ⁇ ) is a totally ordered set under ⁇ , and B is an anti-chain if any two of B are incomparable.
  • F is monotonic because one iteration defines more endpoints than the starting point on the right side is defined. Therefore, by repeating F, iterative sequence generated one after another [0 1 2 9]
  • k is the number of iterations.
  • the minimum number of iterations is the maximum chain size.
  • a partially ordered set can be split into antichains by the following theorem.
  • A is split into n disjoint disjoint chains.
  • An is the set of maximal elements.
  • the program generated by the method of., Which has one basic structure and rearranges words, has the following structure.
  • control area flag and the input / output action element flag need to be cleared, and are left as they are.
  • Words and input / output action elements that belonged to the same basic structure have the same execution condition because the execution condition for the path action element of the basic structure is expanded equally, so that they are united even after sorting. Create a group.
  • the basic elements are regrouped according to the execution condition of the route, and within the group, the basic elements are arranged in the order of execution from the top.
  • the requirements in this example are for a student performance management system.
  • the general affairs officer can register the student's name
  • the teacher can register the student's score for each test, and can register a comprehensive evaluation at the end of the semester.
  • This system consists of three screens: the “initial screen” shown in Fig. 11, the “student registration screen” shown in Fig. 12 and the “grading management screen” shown in Fig. 13, and the ID and password of the administrator and teacher.
  • Registered "ID & password file” "Student name file” in which student names and IDs are registered
  • "Student grade file” in which scores for each test are registered
  • the "Comprehensive Evaluation File” in which is registered consists of four files.
  • the initial screen is the screen displayed when the grade management system is started. Press the Exit button to exit the system.
  • the system refers to (reads) the entered data and the data registered in the ID & password file, and the entered data is handled by the general affairs bureau. Judge whether it belongs to the teacher, the teacher, or neither. As a result of the judgment, if the ID and password are those of the administrator, the student registration screen is displayed. If the ID and password are for the teacher, the grade management screen is displayed. Otherwise, the initial screen is displayed.
  • the student registration screen is where the general affairs staff registers the student name and student ID number. This screen is displayed when the ID and password determined on the initial screen are those of the person in charge of general affairs.When displayed, the system refers to the student name file and reads the registered student data. Is displayed in the student list field. After the screen is displayed, enter the student name and student ID number in the newly registered fields and press the register button. Is registered (written) in the file. Press the back button to return to the initial screen. [0 1 3 1]
  • the grade management screen is a screen for registering and referring to student scores and overall evaluations for each test. Displayed when the ID and password determined on the initial screen are for the teacher.
  • the system refers to the student name file and prepares a list of student names and student ID numbers assigned by the accessing teacher as a selection candidate list that can be displayed in the student name text box.
  • the system refers to the grade file for each test and enters the data. Calculate and display the student's test results and the average score of the test results.
  • the comprehensive evaluation is displayed by referring to the comprehensive evaluation file.
  • To register a new test result enter the data of the selected student in the test result registration field and press the register button.
  • the system registers the new data in the grade file for each test, updates and displays the contents of the test result field to include the new data, and recalculates and displays the average score.
  • To register an overall evaluation enter the overall evaluation of the selected student in the overall evaluation registration field and press the register button.
  • the system registers the comprehensive evaluation data in the comprehensive evaluation file and simultaneously displays the data registered in the comprehensive evaluation field. Press the back button to return to the initial screen.
  • Figure 14 shows the requirements of this performance management program and the processing path diagram that shows the structure when this program is divided into the conventional basic structure.
  • the language used is C ++, only the screen uses C ++ functions, and the rest are described using only C grammar.
  • the database 'management system is Access 97 with DO A.
  • the following is a comparison between the Lyee structure program generated with the basic structure divided and the new program based on the Lyee methodology.
  • the number of execution steps and the time Select one of them and display the results of 5 exams.
  • CPU process time is a value that does not include database access time
  • Total process time is the total time that includes database access time. The processing time was determined by adding a time stamp function to the program and calculating the difference between the start and end times.
  • the reduction in executable code is mainly due to the smaller word structure and the unification of the basic structure.
  • the main changes are
  • the predicate structure consists of approximately 21 lines. This is usually only a generation expression consisting of one line of an assignment expression.
  • the action element of the path is one IF statement.
  • the input and output elements remain almost unchanged.
  • One basic structure requires about 24 KB, excluding words and action elements. In this case, the nine basic structures become one.
  • the reduction in the number of execution steps and the execution time is mainly due to the reduction in repetition.
  • the main changes are:
  • the execution condition of a word can be regarded as the execution condition of the action of the process definition, and the design difficulty in the conventional Lyee is reduced.
  • Lyee's advantage declaratively capturing specifications, is realized in the new program by defining processes and words. Therefore, in the new program, the procedure for control is realized by the process definition, and there is no need to design the program.
  • the conventional method requires some design based on the specifications.
  • the program generated by the tool based on the Lyee methodology is a specification that was split at the time of design and expanded into program modules in a split state. Indeed, utilizing the ordering information that is explicitly expressed in the requirements in the design can improve the design accuracy and efficiency.
  • the Lyee-structured program dynamically solves problems that can be solved statically before execution, so the code size is large and the processing speed is slow. There is room for improvement here.
  • a program can be generated without changing the meaning of the program and without dividing it into a basic structure from the beginning while taking advantage of the efficiency of design. By doing so, the whole word becomes one area. Therefore, if the correct order of the whole words is determined by the topological sort on the directed graph in which the relation between words is created, the repetition for ensuring the order becomes unnecessary (see Patent Document 6).
  • creating a processing path diagram that is, capturing requirements in a divided manner, is very useful for accurately capturing system requirements.
  • Creating a processing path diagram is to capture words that have common elements in output conditions in units of logical entities. Assigning common elements of conditions to path action elements has significant advantages for efficiently defining user requirements.
  • Path action elements are also subject to topological sorting, and the requirements are defined in terms of words as in the case of logical elements that define the relationships between words. In other words, it defines what condition is satisfied (the execution condition of the definition formula) and which basic structure is to be executed (the definition formula).
  • the path action element is eliminated by adding the execution condition of the definition formula of the path action element to the execution condition of the module belonging to the basic structure specified by the path action element when the condition is satisfied.
  • Topological 'sorting is performed on the group of declaration execution modules (not including path action elements) of the entire unified program obtained in this way, and the group of declaration execution modules is rearranged in the optimal order. This makes it possible to avoid unnecessary repetition and execute the program with the minimum number of executions.
  • the present invention is not limited to the above-described embodiments and examples, and various modifications are possible within the scope of the technical idea of the present invention.
  • the present invention can be implemented not only as a method, as software having such functions, but also as an apparatus or tool (including software itself) on which the software is installed, or as a system. Of course, it can be realized.
  • FIG. 16 shows a program (software) for producing “software to be developed”, a program generation device, a program processing device, and a tool (both as a device or as software) as another embodiment of the present invention.
  • FIG. 2 is a functional block diagram showing a configuration provided as a function when implementing the present invention as one of a software development device, a software development support device, and a software development management device. [0 1 3 8]
  • the overall control unit 1601 is composed of this program (software), program generation device, program processing device, tool (including both as a device and software), software development device, software development support device, or software development. It has a function to control the operation, timing, and input / output of the entire management device.
  • Figure 17 shows a program (software), program generation device, program processing device, tool (including both as a device or software), software development device, software development support device, or software development management having the above configuration.
  • 4 is a flowchart showing the operation of the present invention implemented as any of the devices.
  • the processing of the declaration execution module for generating output data in the program including the word-based declaration execution module is completed with a minimum number of executions by eliminating useless repetition.
  • the program size can be reduced.
  • a program (software), a program generation device, a program processing device, a tool (including both as a device or software), a software development device for producing “software to be developed” as different embodiments of the present invention.
  • the software development support device and the software development management device define the user requirements to be implemented as one program for each logical entity with access conditions, for each word on the logical entity, for the word name, definition formula, and definition.
  • L2 processing input word attribute check processing
  • L processing output word
  • I2 processing logical input processing
  • 04 processing logical output processing
  • the present invention is further realized as software produced by the above-described “method of producing software to be developed”, and as a recording medium on which the software is mounted or an apparatus (hardware) on which the software is mounted.
  • the user requirements to be implemented as one program are defined for each logical entity with an access condition, for each word on the logical entity, a word name, a definition formula, and the execution of the definition formula.
  • L2 processing input word attribute check processing
  • L processing output word processing
  • I2 processing I2 processing
  • the execution unit of the declaration of the processing is arranged by topological sorting performed based on the (half) order relation defined from the requirements declared in word units. According to the permuted sequence, it can be configured as a given code sequence based on the applicable Lyee methodology.
  • the present invention provides software as a template of software code used for producing software by the above-mentioned “method of producing software to be developed”, and a recording medium or a recording medium on which the software is mounted. It is also realized as a device (hardware) on which the software is installed.
  • the present invention provides a method of extracting information (document (paper, data)) extracted from the requirements according to the above-described “method of producing software to be developed”, and information (document (document (data)) extracted by the extraction method. Paper, data)), as a method of using the extracted information, or as an information recording medium on which such information is mounted, or a method of extracting the information z software in which the method of use is coded,
  • the information may be realized as information extracted from software development requirements including information to be associated which can be realized.
  • directed graphs for example, breadth-first search (B readth-first search), iterative deepening (iterative deeping), heuristic search (heuristic search) hill 'climbing (hi11climb) ing), best-priority search (Best-first search), Euler (Eu1er) one-stroke writing, Dijkstra method, and other various search techniques may be combined for sorting.
  • B readth-first search iterative deepening
  • heuristic search hill 'climbing (hi11climb) ing
  • best-priority search Best-first search
  • Euler Eu1er
  • the fundamental idea of the present invention may be realized by combining the various search techniques.
  • an automatic development device for computer software an automatic development program, a recording medium on which the automatic development program is recorded, a transmission medium, and a paper medium.
  • an automatic development device for computer software
  • an automatic development program a recording medium on which the automatic development program is recorded
  • a transmission medium a transmission medium
  • a paper medium a paper medium.
  • it can be realized and used in categories such as devices and client / server types that execute automatic development programs.
  • the present invention is not limited to a computer system having a single processor, a single hard disk drive, and a single roll memory, but may include any plural or combination of port processors or storage devices as an option of the system. Also suitable for. Computer systems include sophisticated calculators, palm-type computers, laptop / notebook computers, minicomputers, mainframe computers, and supercomputers, and combinations of these processing system networks. It can be replaced by any suitable processing system that operates in accordance with the principles of the present invention, and can be used in combination therewith.
  • the technical idea according to the present invention can be applied to all kinds of programming languages. Further, the technical idea according to the present invention can be applied to application software of all types and functions.
  • the present invention allows various modifications, additions, substitutions, enlargements, reductions, and the like within the scope of the same and equivalent technical ideas. Further, even if software produced using the invention of the present application is registered as a secondary product and commercialized, the value of the present invention is not reduced at all.
  • preprocessing for eliminating repetition is automatically performed, and a target program is automatically generated by the Lyee (registered trademark) methodology based on the preprocessed word-based program thus obtained.
  • Lyee registered trademark
  • FIG. 1 is a conceptual diagram for explaining a concept of a cell according to an embodiment of the present invention.
  • FIG. 2 is an explanatory diagram of a screen of a system of Example 1 according to one embodiment of the present invention
  • FIG. 3 is an explanatory diagram showing words of the system of Example 1 in a basic composition unit according to an embodiment of the present invention.
  • FIG. 4 is a directed group representing a relationship between words in the system of Example 1 according to an embodiment of the present invention. It is rough.
  • FIG. 5 is a diagram for explaining a process of expressing the entire system of Example 1 by one adjacency matrix F according to an embodiment of the present invention.
  • FIG. 6 is a diagram for explaining that an adjacency matrix F according to an embodiment of the present invention has been topologically sorted.
  • FIG. 7 is a directed graph showing a relationship between words when a path action element is deleted from the structure of the system of Example 1 according to an embodiment of the present invention.
  • FIG. 8 is a diagram for explaining a process of expressing the entire system by one adjacency matrix F ′ when a path action element is deleted from the structure of the system of Example 1 according to one embodiment of the present invention.
  • FIG. 9 is a diagram for explaining that an adjacency matrix F ′ according to an embodiment of the present invention has been topologically sorted.
  • FIG. 10 is a directed graph of Example 2 according to one embodiment of the present invention.
  • FIG. 11 is a diagram illustrating an “initial screen” of Example 2 according to an embodiment of the present invention.
  • FIG. 12 is a diagram illustrating a “student registration screen” of Example 2 according to an embodiment of the present invention.
  • FIG. 13 is a diagram showing a “performance management screen” of Example 2 according to an embodiment of the present invention.
  • FIG. 14 is a processing path diagram showing requirements of a grade management program of Example 2 according to an embodiment of the present invention, and a structure in a case where the program is divided into a conventional basic structure. .
  • FIG. 15 is a part of an integrated new program code according to an embodiment of the present invention.
  • FIG. 16 As another embodiment of the present invention, a program (software) for producing “software to be developed”, a program generation device, a program processing device, and a tool (including both as a device or as software)
  • FIG. 3 is a functional block diagram showing a configuration provided as a function when implementing the present invention as one of a software development device, a software development support device, and a software development management device.
  • FIG. 17 shows a program (software), a program generation device, a program processing device, a tool (including both as a device or software), a software development device, and a program having the above configuration according to an embodiment of the present invention.
  • 5 is a flowchart showing the operation of the present invention implemented as either a software development support device or a software development management device.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)
  • Devices For Executing Special Programs (AREA)

Description

【書類名】 明細書
【発明の名称】 ソフトゥ ア生成方法 【技術分野】
【0 0 0 1】 本発明は、 数学的考え方にたったソフトウェア生成方法に係り、 特に、 隣接行列、 ト ポロジカノレ .ソートを L y e e方法論に用いたソフトウェア生成方法に関する。 【背景技術】 【0 0 0 2】
( 1 ) ソフトウェア開発の課題 高い品質を持つソフトウェアを容易に迅速に製造することは、 ソフトウェア開発研究 分野の基本的な関心事である。 ソフトウェア開発の生産性、 保守性、 品質を向上するた めの種々の方法論およぴ技術が考案され提案されてきたが、 いまだにこれらの課題を本 質的に解決できたものはない。 その理由の 1つは、 ソフトウェア自身が複雑なものであ り、 捕らえにくいものであるからであり、 もう 1つの理由は、 現在の方法論に限界があ るからである。 実際、 提案されたほとんどすべての方法論は、 明快に理解でき、 修正可 能なシステムの製造に失敗しているのみならず、 それらは、 非常に広範囲の能力、 技術 および知識を持つ専門家にしか利用できないものといまだに見なされている。 そのため、 ^件費や維持費が高いものになり、 ソフトウェア上で実行させるためには広範なチエツ クが必要になる。 従来のソフトウエア開発手法の概要と課題をまとめると以下のように なる。
( 2 ) 手続き型プログラミング
一般に、 手続型プログラミングは、 その記述言語の扱いやすさから、 業務システム開 発とその実装において効果を発してきた。 し力 し、 いまだ要件を正確に実装することの 困難性、 生産性や保守性の向上という重大な課題が残されている。
( 3 ) 宣言型プログラミング
—方、 要件定義そのものである宣言によってプログラミングを行う宣言型のプロダラ ミングは、 人工知能、 エキスパートシステムをはじめ論理的証明 (logical reasoning)、 推論 (inference) 、 ユーザ情報収集 (user intelligence gathering ) など、 非計算系 のアプリケーシヨン分野で使用されている。 宣言型プロダラミングは、 制御手順でなく、 要件定義されているデータ間の関係を宣言し、 その宣言に基づいてプログラミングを行 うので、 そのメリットは、 制御手順などの手続きを明示的に指定する必要がある手続き 型プログラミングと異なり、 要件を正確に実装できるということである。
【0 0 0 3】
し力 し、 宣言型プログラミングにも、 実行制御の構造上、 実行時の効率が良くないと いう問題がある。 また、 宣言型プログラミングを行うための言語は使いこなすのが難し いという欠点がある。 宣言型プログラミングを行うための言語には、 論理式を用いる論 理型言語 (たとえば P R O L O G) や対象の状態を数学的な関数として記述する関数型 言語 (たとえば L I S P ) がある。 宣言しただけでは値は生成されないから、 値を生成 するためには、 宣言型言語は、 宣言を実行するための手続きの論理メカニズムを持って いる。 これらの手続きの論理メカニズムには、 あらゆる宣言を実行できるようにするた めに多くの条件があり、 数学や論理学の知識も必要で、 使いこなすのが難しい。 このた めに、 プログラミング言語として普及していない。 人間の自然言語に近い構造を持つ手 続き型言語による、 手続き型プログラミングの方が普及しているゆえんである。
( 4 ) オブジェクト指向プログラミング
データとそれを操作する手続き (メソッドと呼ぶ) をオブジェクトと呼ばれるひとま とまりの単位として一体化し、 オブジェクトの組み合わせとしてプログラムを記述する プロダラミング技法として、 オブジェクト指向プロダラミングがある。 オブジェクトと いう独立性の高いモジュールによってプログラムが構成されるため、 変更 ·修正の影響 の範囲が限定され、 またオブジェクトの単位で再利用がしゃすくなるなどのメリットが ある。
【0 0 0 4】
し力 し、 要件を、 どのような単位のオブジェクトによって実装するのか、 さらに、 構 成要素をどのように組み立てるかについては厳格な規則はなく、 また、 構造化設計アブ ローチのような実行順序についての規制もない。 実際の開発の場においては、 オブジェ クト間の関係が完全に一貫性を持って適用されず、 多くの場合、 開発成果物に大量のォ ブジェクトが生成されていても、 作成者自身を除けば誰もそれを理解していないという ことになる。 すなわち、 完成したソフトウェアは規則性のない機能のかたまりとなり、 最終的に解体したり、 再使用したりするのが困難になる傾向が強い。
【特許文献 1】
国際公開第 9 7 / 1 6 7 8 4号パンフレット
【特許文献 2】
国際公開第 9 8 / 1 9 2 3 2号パンフレツ ト
【特許文献 3】 国際公開第 99/49387号パンフレツト
【特許文献 4】
国際公開第 00/79385号パンフレツト
【特許文献 5】
国際公開第 02ノ42904号パンフレツト
【特許文献 6】
国際公開第 2004/68342号パンフレツト
【特許文献 7】
特開 2002— 202883号公報
【非特許文献 1】
ダリン ' ウィンスケル著、 「プログラミング言語の公式意味論」 、 MI Tプレス、 1 993年
【非特許文献 2}
ハンネ · リース ·ニーノレソン、 フレミング 'ニーノレソン著、 「アプリケーション についての 意味論 公式紹介」 、 ジョン · ワイリー 'アンド 'サンズ 、 1992年
【非特許文献 3】
根来 文生著、 「Lyeeソフトウェアの原理」 、 21世紀 ( IS2000 ) における情 報社会についての国際会議会報、 日本、会津、 2000年 1 1月 5日- 8日、 pp441 - 446
【非特許文献 4】
根来 文生著、 「ソースコード生成についての高密度処理方法」 、 システミタス、 サイバネティクス及びインフォマテイクスについての第 5回世界多極会議会報、
( SCI2001 ) 、 米国、 オーランド、 2001年 7月 22日— 25日
【発明の開示】
【発明が解決しょうとする課題】
【0005】
( 1 ) Ly e e開発方法論
最¾1、 Lyee g o v e r nme n t a ju me t h o d o l o g y f o r s o i t w a r E p r o v i d e n c Eの語尾をとつたもの。 「リー」 と読む。 発明者は根 来文生。 ) と呼ばれる新しく、 非常に有望な方法論が提案された。 Lyeeは、 要件からソ フトウェアを自動的に開発する新しい方法である。
【0 0 0 6】
L y e eの場合、 宣言型でありながら、 宣言を実行するための特別な論理メカニズム を必要とせず、 宣言の実行は、 手続き型プログラミングと同じく、 単純な値の代入とい う手続きである。 従って、 使用する言語は一般に普及している手続き型言語でよい。 つ まり、 Lyeeは要件を正確に実装できるという宣言型の利点と、 記述が容易な手続き型言 語を使用できるという手続き型の利点をあわせ持っているのである。
【0 0 0 7】
L y e e開発方法の概要については、 本願の出願人による特願 2 0 0 4 - 2 7 2 4 0 0および特許文献 6を引用し、 これを開示の一部となす。 以下に概要を述べる。
( 2 ) Lyeeにおける宣言とは
Lyeeにおいては、 宣言する抽象化の対象は変数である。 宣言された変数を、 L y e e では単語と呼ぶ。 一般的に、 仕様が宣言的であるとは、 宣言される抽象化の単位は記述 の順序性が排除されることと、 等式として表現され右辺から左辺、 左辺から右辺への双 方向性があることである。 Lyeeでは、 単語は記述の順序性が排除されるが、 双方向性を もたず、 このことによって、 枠組みが簡潔になっている。 ,
【0 0 0 8】
単語の宣言の主な要素は、 単語名、 定義式、 定義式の計算条件、 入出力属性、 値の属 性などである。 定義式とは、 他の単語との関係を示す関係式である。 たとえば、 単語 a は定義式 a=b+cのように宣言できる。 そして、 この宣言の実行は、関係式を代入式として 実行するだけである。 たとえば、単語 aの宣言 a= b + cを実行するには(aの値を求めるに は) 、 右辺の変数 bおよび cに値を代入すればよい。
( 3 ) 手続き型の枠組みで宣言を実行するメカニズム
手続き型言語の枠組みで、 実装していながら、 宣言の記述の順序性排除を実現してい るのは、 L y e eが提供する定型構造のプログラム構造である。 プログラムを処理する コンピュータが、 現在使われている、 命令をシーケンシャルに処理するノイマン型であ る限り、 手続き型言語であれば、 なんらかの方法で順序性の問題を解決しなければなち ない。 他の宣言型プログラミングは、 宣言型言語がそれを解決している。 手続き型言語 を用いる Lyeeは、 プログラム構造によって解決している。
【0 0 0 9】
そのプログラム構造は、単語単位の宣言を実行する定型構造のモジュール(以下、 「宣 言実行モジュール」 と呼ぶ。 ) からなり、 それらのモジュールは、 パレットと呼ぶ単位 で集合化されている。 パレット内の、 宣言実行モジュールの実行順序は、 いかなる配列 でもよい。 パレット内の実行制御モジュールが、 パレット内の全ての宣言実行モジユー ルの実行が完了するまで (すなわち、 値が生成できまるで) 宣言実行モジュールの実行 を繰り返すよう実行を制御する。
【00 1 0】
パレットは、 入力単語の宣言実行のための W02パレット、 出力単語の宣言のうち計 算条件を実行するための W03パレツト、 出力単語の宣言のうち定義式実行と出力を実 行するための W04パレットがある。 これらの 3種類のパレットが 1組となって、 基本 構造という集合単位を成している。 すなわち、 Lyee構造のプログラムは、 基本構造単位 に分割され、 その基本構造は 3種類のパレットに分割され、 パレットは宣言実行モジュ ールに分割される、 という構造をとつているのである。 基本構造は、 出力論理体 (すな わち同時に同じ媒体に出力される単語のグループ) の単位につくられる。 Lyeeプロダラ ムのこの分割構造を図示したのが、 処理経路図 (PRD: Process Route Diagram) である。
【00 1 1】
Ly e eによるプログラム全体は、 単語単位の宣言を実行する定型構造の宣言実行モ ジュールによつて構成され、 しかもそれら宣言実行モジュールでプログラム全体を構成 する方法も定型化されている。 従って、 この定型構造の宣言実行モジュールに、 単語単 位の要件の宣言を代入すれば、 自動的にプログラムを生成することも可能である。
【00 1 2】
L y e eによるプログラムの自動生成は、 「Ly e eALL」 と呼ばれるツー ルによって実現されている。 Ly e eALLは、 いわば、 定型構造の宣言実行モジユー ルのコード ( 「テンプレート」 と呼ぶ。 テンプレートはひな形の意。 ) の所定の空欄に、 要件の宣言を自動的に代入し、 それらの宣言実行モジュールを所定の方法に従って構成 して 1つのプログラムを構築するツールである。
【00 1 3】
Ly e e方法論によるソフトウェア開発では、 技術者は 2つのグループに分かれ、 そ れぞれ特ィ匕した 2種類の仕事を行うことになる。 1つのチームは、 OS、 ミドノレウェア、 データベースなど、 Ly e e構造プログラムが動く外部環境に係わる技術に習熟し、 L y e e構造プログラムのテンプレートに、 外部環境ごとのパラメータを設定する。 もう 1つのチームは、 ユーザ要件定義を行い、 要件を Ly e e構造プログラムのテンプレー トに実装するために、 Ly e e方法論に従った要件の宣言を行う。 このような分業制に よる開発が可能になるため、 Ly e e方法論の開発においては、 プログラマ全員が広範 な外部環境に係わる技術を持つ必要がなく、 そのようなスキルを持つ人材不足の問題も 解消できる。 ( 4 ) 従来の Lyee構造の課題
上述のように、 要件の正確な実装、 コード生成の自動化、 保守の容易性など、 大きな メリツトがある Lyee方法論であるが、 その繰り返しと分割の構造には課題もある。 繰り 返し処理のために、 実行速度が遅く、 分割構造のためにプログラムサイズが大きい、 と 言われている。
【0 0 1 4】
一方、 Lyeeでは、 基本構造と呼ぶ単位に、 要件を分割して仕様を捉える。 画面の遷移、 データベースのキーの関係などの実行順序に関する明白な情報を単語のグループ
(record) を単位として捉え、 そのグループに属す単語の実行条件をまとめて把握する。 現状の Lyee構造は、 この分割構造を、 そのままコード化しているため、 プログラムサイ ズが大きく、 実行速度も遅くなつている。
【0 0 1 5】
L y e e構造を、 その宣言的プログラミングの利点をそのままに、 要件的意味を変更 せずに維持しながら、 不要な反復がなく、 よりサイズが小さく、 効率的処理速度のプロ グラムに改善することは重要な課題である。
【0 0 1 6】
不要な繰り返しをなく して、 実行速度の改善をはかる方法としては、 トポ ジカル' ソートによって、 宣言実行モジュールの配置順序を自動的に最適化する (1巡で宣言実 行が完了する順序化) 方法がすでに提案されている (P C TZ J P 0 3 / 0 9 5 9 1 ) 。 パレツト内のモジュールにトポロジカル'ソートを行って、パレツト内の無駄な繰り返し を排除することができる。
【0 0 1 7】
し力 し、 Lyeeの分割構造の枠組みをそのままにしてトポロジカル' ソートを行っただ けでは、 その効果には限界がる。 なぜなら、 ノ レット間、 基本構造間にも繰り返しがあ り、 パレット内のトポロジカル'ソートによる最適順序化により、 繰り返し回数は最小 限になるもの、 全ての の生成が 1巡では完了しないからである。 また、 分割構造その ものが、 プログラムサイズを大きくしている一因である。
【0 0 1 8】
従って、 繰り返しと分割の構造を持った Lyeeプログラムのサイズと処理速度の問題を、 さらに大きく改善するためには、 パレットおよび基本構造という分割単位をなくし、 1 本のプログラムとして実装する要件の範囲の宣言を実行するモジュールに対してトポロ ジカル.ソートを行うことが有効と思われる。
【0 0 1 9】 本発明は、 従来の Lyee構造プログラムの分割単位をなくし、 プログラム全体に対して トポロジカル'ソートを行う方法に関するものである。 これにより、 L y e e方法論に よるソフトウェアの実行速度の向上、 プログラムサイズの改善を実現することを目的と する。
【課題を解決するための手段】
【0 0 2 0】
力かる課題を解決するために本発明は、 1つのプログラムとして実装するユーザ要件 を、 アクセス条件を伴う論理体ごとに、 該論理体上の単語ごとに、 単語名、 定義式、 該 定義式の実行条件、 入出力属性、 単語の値の属性によって宣言された単語単位の宣言か ら、 要件充足に必要な全ての、 L 2処理 (入力単語の属性チェック処理) 、 L処理 (出 力単語の値生成処理) 、 I 2処理 (論理体入力処理) 、 0 4処理 (論理体出力処理) の いずれかの宣言の実行単位を規定する第 1のステップと、
前記に規定された、 全ての L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力 単語の値生成処理)、 I 2処理(論理体入力処理)、 0 4処理(論理体出力処理) の(半) 順序関係を定義する第
前記ステップによって定義された (半) 順序関係で規定される前記 L 2処理、 L処理、 I 2処理、 O 4処理に対してトポロジカル'ソートを行う第 3のステップと、
前記第 3のステップによって並び替えられた宣言の実行単位の順序列にしたがって該 宣言実行単位に該当する L y e e方法論に基づく所与のコード列を配置する第 4のステ ップと
を具備する。
【0 0 2 1】
力かる構成を有する本願発明によれば、 第 1のステップによって規定された単語単位 の宣言を、 L 2処理(入力単語の属性チェック処理)、 L処理(出力単語の値生成処理)、 I 2処理 (論理体入力処理) 、 0 4処理 (論理体出力処理) 、 の単位で、 最短順序で実 行するプログラムが作成されることとなり、 L y e e方法論を用いたソフトウェア生成 がより効率化する。 つまり、 これらの各ステップの機能は総て自動化できるので、 結局 繰返し処理の排除→ソフトウェア生成まで一貫して自動処理が可能となり、 ソフトゥェ ァ生産速度、 効率は各段に向上する。
【0 0 2 2】
ここで、 「全ての L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力単語の値 生成処理) 、 I 2処理 (論理体入力処理) 、 0 4処理 (論理体出力処理) の (半) 順序 関係を定義する」 とは、 宣言で用いられる単語に着目して相互の順序関係をたとえば有 向グラフで表すことをいう。 順序関係としては半順序及び全順序が考えられる。 「有向 グラフ」 とは、 ソフトウェア開発要望者であるユーザの発する要件に含まれるそれぞれ の宣言実行単位をノードによって表し、 a ≤b (aから bが作られることを意味する記号 として 「≤」 を定義する。 以下同じ。 )という始点と終点の間の半順序関係 (または全順 序関係〉 を矢印によって表したものをいう。 例えば、 こうした機能をプログラム化した ソフトウエアとしてもよいし、或いは当該ソフトウエアをコード化したものを ROM(R e a d O n 1 yMemo r y) に書きこんだものであってもよい。
【0023】
また、 「トポロジカル ' —ト」 とは、 上記で得られた有向グラフに対して (後述の) 深さ優先探索を行い、 行きついたところから探索経路を戻るときにノードを取得してゆ くことでノード列 (数列) を整列する機能をいう。 例えば、 こうした機能をプログラム 化したソフトウエアとしてもよいし、 或いは当該ソフトウエアをコード化したものを R
OM (Re a dOn l yMemo r y) に書きこんだものであってもよい。 このトポロ ジカル ·ソートに際しては、 上記で得られた有向グラフを隣接行列で表し、 これに深さ 優先探索を行い、 零冪行列を生成するように動作させてもよい。
【0024】
ここで、 「深さ優先探索」 とは、
( 1 ) 始点であるノードを出発してノード間の連結がとれているノ一ドを訪問が重複 しないように進み、
(2) 行く場所がなくなったら行く場所のあるノードまで戻り (再帰) 、
(3) 戻ったノードから再ぴ (1) の要領で進み、
(4) 進むところがなくなったら終了する、
というァノレゴリズムをいう。
【0025】
「探索」 とは、 上記の深さ優先探索 (De p t h— F i r s t S e a r c h) のほ 力、、 幅優先探索 (B r e a d t h— F i r s t S e a r c h) 、 反復深化法 ( I t e r a t i v e De e p i n g) 、 発見的探索 (He u r i s t i c S e a r c h) 、 ヒル.クライミング (H i 1 1 C 1 i mb i n g) 、 最適優先探索 (B e s t— F i r. s t S e a r c h) s オイラー (Eu 1 e r) の一筆書き、 ダイクストラ (D i j k s t r a) 法等を含む各種アルゴリズムをいう。 例えば、 こうした機能をプログラム 化したソフトウエアとしてもよいし、 或いは当該ソフトウェアをコード化したものを R OM (R e a dOn 1 yMemo r y) に書きこんだものであってもよい。
【0026】
また、 ここで用いる 「ソフトウェア」 とは広義の意である。 即ち、 ユーザからの開発 要望及び当該要望にあった目的プログラムの双方を包含する概念である。
【0 0 2 7】
上記のような構成を備えることにより、 本願発明では、 操返しを回避するので、 より 高効率、 高速、 高パフォーマンスを備えたソフトウェア開発を実現することが可能とな る。 さらに、 繰返しをなくす前処理を自動で行い、 こうして得られた前処理済の宣言実 行単位のプログラムをもとに L y e e (登録商標) 方法論により自動的に目的プログラ ム生成を fi1う。 つまり、 ユーザ要件の洗練化 (整列) から目的プログラムの生成に至る まで自動化することが可能となる。 これにより、 ソフトウェア生産の大幅な効率向上、 生産性向上、 品質向上等、 ソフトウエア産業上に大きな効果をもたらす。
【0 0 2 8】
本発明の異なる実施体としての 「開発対象のソフトウェア」 を生産するためのプログ ラム (ソフトウェア) 、 プログラム生成装置、 プログラム処理装置、 ツール (装置とし て或いはソフトウェアとしての双方を含む) 、 ソフトウェア開発装置、 ソフトウェア開 発支援装置、 ソフトウェア開発管理装置は、 1つのプログラムとして実装するユーザ要 件を、 アクセス条件を伴う論理体ごとに、 該論理体上の単語ごとに、 単語名、 定義式、 該定義式の実行条件、 入出力属性、 単語の値の属性によって宣言された単語単位の宣言 から、要件充足に必要な全ての、 L 2処理(入力単語の属性チェック処理) 、 L処理(出 力単語の値生成処理) 、 I 2処理 (論理体入力処理) 、 0 4処理 (論理体出力処理) の いずれかの宣言の実行単位を規定する手段と、 前記に既定された、 全ての L 2処理 (入 力単語の属性チェック処理) 、 L処理 (出力単語の値生成処理) 、 I 2処理 (論理体入 力処理) 、 0 4処理 (論理体出力処理) の (半) 順序関係を定義する手段と、 前記ステ ップによって定義された (半) 順序関係で規定される前記 L 2処理、 L処理、 I 2処理、 0 4処理に対してトポロジカル'ソートを行う手段と、 前記第 3のステップによって並 び替えられた宣言の実行単位の順序列にしたがって該宣言実行単位に該当する L y e e 方法論に基づく所与のコード列を配置する手段とを具備するように構成することもでき る。
【0 0 2 9】
本発明はさらに、 上述の 「開発対象のソフトウェアを生産する方法」 によって生産さ れたソフトウェア、 及び当該ソフトウェアが搭載された記録媒体或いは当該ソフトゥェ ァが搭載された装置 (ハードウェア) としても実現されるが、 この場合の本発明は、 1 つのプログラムとして実装するユーザ要件を、 アクセス条件を伴う論理体ごとに、 該論 理体上の単語ごとに、 単語名、 定義式、 該定義式の実行条件、 入出力属性、 単語の値の 属性によって宣言された単語単位の宣言から規定された、 要件充足に必要な全ての、 L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力単語の値生成処理) 、 I 2処理
(論理体入力処理) 、 0 4処理 (論理体出力処理) の宣言の実行単位が、 単語単位に宣 言された要件から定義した (半) 順序関係に基づいて行われるトポロジカル■ソートに よって並ぴ替えられた順序列にしたがって、 該当する L y e e方法論に基づく所与のコ 一ド列として構成されることもできる。
【0 0 3 0】
またさらに本発明は、 上述の 「開発対象のソフトウェアを生産する方法」 によってソ フトウエアを生産するために用いられるソフトウエアコードの雛型としてのソフトゥェ ァ、 及び当該ソフトウェアが搭載された記録媒体或いは当該ソフトウェアが搭載された 装置 (ハードウェア) としても実現される。
【0 0 3 1】
さらに、 本発明は、 上述の 「開発対象のソフトウェアを生産する方法」 による、 要件 から抽出した情報 (ドキュメント (紙、 データ) ) の抽出方法として、 またかかる抽出 方法によって抽出された情報 (ドキュメント (紙、 データ) ) として、 さらには当該抽 出された情報の使用方法として、 或いは、 これらの情報が搭載された情報記録媒体とし て、 または情報の抽出方法/使用方法がコード化されたソフトウェア、 当該ソフトゥェ ァが搭載された記録媒体/装置 (ハードウェア) として、 いずれも実現ずることができ る関連づける情報とを備えるソフトウェア開発要件から抽出した情報として実現しても よい。
【0 0 3 2】
なお、 論理体については、 同一出願人による特願 2 0 0 4 - 2 7 2 4 0 0を参照し、 これを引用し、 開示の一部とする。
【発明の効果】
【0 0 3 3】
本発明によれば、 単語単位の宣言実行モジュールからなるプログラムにおける、 出力 データを生成するための宣言実行モジュールの処理を、 無駄な繰り返しを排除して最少 実行回数で完了し、 力つ、 プログラムサイズを小さくすることが可能となる。 より具体 的には、 下記の点が可能になる。
【0 0 3 4】
プログラムの要件を単語単位に宣言した宣言から、 実行すべき単語単位の宣言実行単 位を決定し、 それらの単語単位の宣言実行単位の半順序関係を定義することが可能とな る。
【0 0 3 5】
最適順序化によつて不要となる単語単位の宣言実行単位、 たとえば経路作用要素は削 除する。 要件の意味を維持するために実装することが必要な順序情報である経路作用要 素の実行条件については、 他の単語単位の宣言実行単位の半順序関係定義に反映するこ とによって、 要件の意味を保持することができる。
【0 0 3 6】 こうして得られた単語単位の宣言実行単位群 (経路作用要素を含めない) に対して、 トポロジカル ·ソートを行って、 単語単位の宣言実行単位群を最適順序に並び替える。 これにより、 無駄な繰返しを回避し、 最少実行回数でプログラムを実行することが可能 となる。
【発明を実施するための最良の形態】
【0 0 3 7】
本発明は、 従来の Lyee構造プログラムの分割単位をなくし、 プログラム全体に対して トポロジカル. ソートを行うことによって、 前述の従来技術の問題を改善するものであ る。 本発明によって、 L y e e方法論によって開発されるソフトウェアの実行速度の向 上、 プログラムサイズの改善を実現する。 以下、 図面を参照しながら、 本願の発明の具 体的な実施形態について説明する。 Lyee構造プログラムに対してトポロジカル ·ソート を行う技術については同一出願人による特許文献 6を引用し、 これを開示の一部となす。
【0 0 3 8】
I章では、 本発明の統合の対象である Lyeeソフトウェアの分割構造がどのようなもの 力 \ 概要を説明する。 I I章では、 基本構造を統合する具体的な方法を述べる。 I I I 章では、 本発明を用いて基本構造を統合するプログラムの事例とその効果を述べる。
< 1章 Lyeeソフトウェアの分割構造のしくみ >
分割構造をもった従来の Lyee構造プログラムを統合するためには、 まず、 その分割構 造のしくみについて理解する必要がある。 基本構造への分割は、 単語がどのようなダル ープ単位にどのような条件で出力されるべきなのか、 という要件を捉えて宣言したもの である。 単語単位の宣言の要素に入出力属性という項目があつたが、 入出力の区別の他 に、 各単語がどの入力または出力グループ (論理体) に属するのか、 その入出力グルー プがどのような条件で入出力されるのか、 も宣言されるべき要件である。 様々な処理を 表わす要件定義から、 この入出力に関する要件情報を、 どのように正確に取り出すかに ついての詳細は、 同一出願人による特願 2 0 0 4 - 2 7 2 4 0 0を引用しこれを開示の 一部とする。 ここでは、 基本構造への分割の意味について、 本発明の説明に必要と思わ れる概要のみを述べる。
1 . 基本構造への分割の意味 '
分割構造の意味
Lyeeソフトウエアの分割構造は、最小単位のモジュールである宣言実行モジュールが、 一定の規則に従って、グループ化されている、 という構造である。その構造を、図 1 (a) 及び (b) に示す。
1 ) 同期範囲 プログラムを構成するモジュールは、 まず、 図 1 (a) で 「同期範囲」 と示した単位 にグループ化されている。 同期範囲とは、 ユーザによるプログラムへの処理実行指示で あるイベント (たとえばボタンを押す、 メニューを選択する、 などのコマンド) によつ て、 コンピュータが実行するように要件で定められているひとまとまりの処理の範囲の ことである。 言い換えれば、 同期範囲とは、 同じイベントを実行条件として実行される モジュールのグループである。 L y e eでは、この同期範囲の処理が完了することを「同 期」 と呼ぶ。 同期範囲の処理が完了するとは、 イベントに対して要件で定められている 出力単語の生成と出力を全て完了することである。
2 ) 基本構造
次に、 同期範囲内のモジュールは、 図 1 (a) の 1 0 1に示すように、 基本構造単位 にグループ化されている。 コンピュータの入出力処理は、 データ単位ではなく、 データ の集合単位に行われるが、 同時に同一の定義体に対して入力または出力処理される単語 の集合を L y e eでは論理体と呼んでいる。 論理体とは、 画面、 ファイル、 帳票、 電文 など、 単語の値を保持する単位である。 同一の出力論理体に関与するモジュールをダル ープ化したものが基本構造である。 プログラムの役割は、 ユーザによるイベントが指定 する出力単語の値を生成、 出力することであるが、 1つのイベントによる同期範囲の中 で行う出力は 1つとは限らない。 単語の値の生成結果を画面に表示 (出力) する以外に、 生成結果をファイルへ保存 (出力) する、 などのように、 多くの場合、 1つの同期範囲 内で 2つ以上の出力論理体が出力され、 同期範囲は複数の基本構造にグループ化される。
3 ) パレット
、 基本構造内のモジュールは、 その種類別に 3つにグループィ匕される。 造内のモジユーノレのグノレープを、 L y e eではパレットと呼んでいる。 3つのパレット を、 それぞれ W02パレッ ト、 W03パレット、 W04パレッ トと呼ぶ。 W02パレットは、 入力単 語の入力にかかわるモジュールの集合である。 W03パレツトは出力単語の定義式の計算条 件の判定にかかわるモジュールの集合である。 W04パレツトは出力単語の定義式の実行に よる値の生成と、 値の出力にかかわるモジュールの集合である。
【0 0 3 9】
次に基本構造の実行順序について説明する。
1 ) 同じ同期範囲内 '
基本構造間には端点始点関係がある。 従って、 深さ優先探索で次に実行すべき基本構 造が決まる。 同じ同期範囲内の宣言実行モジュールに対してトポロジカルソートを実行 すれば実行順序が決まる。
2 ) 同期範囲の実行順序
どの同期範囲が実行されるかは、 どのイベントがユーザによって発せられたかによる。 たとえば、 画面に処理 Aを実行するポタンと、 処理 Bを実行するポタンがあり、 ユーザ がこれらのボタンのいずれか 1つを押下することによって、 プログラムが実行する処理 内容 (すなわち、 同期範囲) が決定する。 このように、 プログラム全体は、 異なるィべ ントを実行条件にする複数の同期範囲によって構成されているので、 プログラム全体の 宣言実行モジュールに対して、 単純にトポロジカルソートを行うことができない。 I I 章で、 2つのイベントによる 2つの同期範囲を持つ仕様を例に用いて、 異なる同期範囲 の宣言実行モジュールに対して統合してトポロジカルソートを行う方法を説明する。
2 . トポロジカルソートの対象
トポロジカルソートによって最適順序化する、 その対象は、 Lyeeソフトウェアの構成 要素である宣言実行モジュールが実行している処理である。 宣言実行モジュールは、 2 つの種類があり、 1つは論理要素で、 単語の値を成立させるためのモジュールである。 もう 1つは作用要素で、 入出力処理など、 値の成立以外の処理を行うモジュールである。
【0 0 4 0】
同一出願人による特許文献 6は、 値を成立させる論理要素を有向グラフおよび隣接行 列の要素として取扱い、 数学的モデルによって表わし、 トポロジカルソートの実施形態 を開示している。 作用要素も、 論理要素と同じく、 有向グラフおょぴ隣接行列の要素と して取扱うことができ、 トポロジカルソートの対象とすることができる。 論理要素と作 用要素の大きな違いは、 論理要素は 1つの単語のみに作用 (値の生成という作用) する 力 作用要素は同時に 2つ以上の単語に対して作用する点だけである。 たとえば、 経路 作用要素 (次に実行する基本構造を指定する) は、 基本構造という単語の集合に対して 作用し、 出力作用要素 (出力単語を出力する) は、 出力論理体という単語の集合に対し て作用する。
【0 0 4 1】
以下に、 宣言実行モジュールを順次考察しながら、 トポロジカルソートの対象にする 方法を述べる。
「論理要素」
L 2は、 入力単語の属性が要件に合致するかのチェックを行う宣言実行モジュールで ある。 いかなる条件下にあっても、 L 2の処理が実行できる条件は、 入力単語の値が、 媒体からメモリ領域内に取り込まれている (入力済みである) ことである。 従って、 ト ポロジカルソートの対象とする L 2処理は、 始点が L 2の値の入力を行う I 2だと考え ば良い。
【0 0 4 2】
イベントのコマンド (ボタンやメニュー) も入力単語の 1つとして扱う。 【0 0 4 3】
『L 3および L 4』
現状の Lyeeソフトウェア構造では、 出力単語の生成処理は、 L 3 (計算条件式の実行) と L 4 (定義式の実行) の 2つのモジュールによって実現している。 さらに、 出力単語 aが複数の定義式を持つ場合 (このような場合の単語を等価単語と呼ぶ) は、 定義式と 計算条件の組の数だけ、 L 3および L 4を設ける。
【0 0 4 4】
出力単語 aが複数の定義式を持ち (このような場合の単語を等価単語と呼ぶ) 、 下記 のように宣言されているとする。
【0 0 4 5】
<定義式> ぐ計算条件 >
( 1 ) b + c e > 1 0
( 2 ) b - d e≤ 1 0
等価単語は複数の定義式を持っているが、 出力単語に必ず 1つだけ値が与えられなけ ればならない。 従って、 等価単語の定義式の計算条件は、 排他的かつ完備でなければな らない。
【0 0 4 6】
いかなる条件下にあっても、 単語 aの生成処理が実行できる条件は、 単語 aの全ての 定義式と計算条件式に用いられている全ての始点単語、 が決定ずみであれば良い。 すな わち、 トポロジカルソートの対象は、 単語 b、 c、 d、 eの定義式が先に実行されてい れば良い。
【0 0 4 7】
従って、 トポロジカルソートの対象となるのは、 出力単語ごとの、 L 3および L 4処 理の組の全てで、 始点は、 それらの定義式と計算条件に始点として用いられている入力 単語の L 2処理、 および、 出力単語の L 4と L 3処理の組である。
「作用要素」
『入力作用要素 I 2』
I 2は、 媒体からメモリ内へ値を取り込む (入力) 処理を行うモジュールである。 従 つて、 いかなる条件下においても、 I 2の処理が実行できる条件は、 無条件である (す なわち、 他の処理に依存しない) 。 トポロジカルソートの対象となる I 2処理は、 始点 をもたない。 (ただし、 ファイルからの入力の場合は、 ファイルにアクセスするための キーとなるキー単語の値が成立している必要がある)
『出力作用要素 0 4』
O 4は、 Lyeeソフトゥェァ領域からメモリ上の出カバッファへ単語の値を書き込む(出 力) 処理を行うモジュールである。 従って、 いかなる条件下においても、 O 4の処理が 実行できる条件は、 出力対象の出力単語の、 値が成立済み (すなわち、 1つの L 4が実 行済み) であることである。 トポロジカルソートの対象となる O 4処理は、 始点が出力 対象の出力単語だと見なせる。
【0 0 4 8】
『構造作用要素 S 4』 .
S 4は、 単語の値を記録する領域と、 処理の結果 (たとえば、 出力が正常に完了した、 出力が正常に完了しなかったなど) を記録する領域を初期化 (初期値を記録する) する 処理を行うモジュールである。 従来の繰り返し構造をもつ Lyeeにおける、 単語の値の領 域への上書き禁止と初期化は、 繰り返し構造のメカニズムのための手段であった。 従つ て、 プログラム全体にトポロジカルソートを行って、 最適順序化した Lyee構造において は、 単語の値の領域の初期化は不要となる。
【0 0 4 9】
一方、 処理結果の記録領域の初期化は、 繰り返し構造のメカニズムのための処理では ないので、 統合 Lyee構造にも必要な処理である。
【0ひ 5 0】
『経路作用要素』
経路作用要素は、 次に実行するパレットを指定する処理を行うモジュールである。 経 路作用要素は、 プログラムの分割単位である、 パレット、 およびそのパレットの集合で ある基本構造を、 リンクする役割を果たしている。
【0 0 5 1】
〈基本構造内のパレット間遷移を行う経路作用要素〉
〈基本構造間の遷移を行う経路作用要素〉
以下に例を上げて、 基本構造から別の基本構造の実行を指定する経路作用要素の意味 を説明する。
(例 1 )
図 2は、 あるシステムの画面で、 ユーザがデータ項目 cおよびデータ項目 dにデータ を入力して実行ボタンの aまたは bを押すことによって、 データ項目 gに値を得るため のシステムである。 7 0 1はデータ項目 cの入力データフィールド、 7 0 2はデータ項 目 dの入力データフィールド、 7 0 3はデータ項目 gの出力データフィールド、 7 0 4 は実行ポタン a、 7 0 5は実行ボタン bである。 実行ボタン aが押されるときは、 gの 値は定義式 c + dで計算され、 実行ボタン bが押されるときは、 gの値は定義式 c X d によって計算される。 実行ボタンの aおよび bは、 両方が同時に押されることはないの で、 gの値の生成のための 2つの定義式のどちらが実行されるかの条件となっている。
【0 0 5 2】
図 2の画面のプログラムを、 基本構造の分割単位に表すと図 3のようになる。 図 3の B S 1、 B S 2、 B S 3はそれぞれ基本構造である。 基本構造 B S 1は、 図 2に示した 画面への出力論理体の基本構造である。 B S 1は、 実行ポタンである入力単語 aと入力 単語 b、 入力データ項目である入力単語 bと入力単語 c、 出力データ項目である出力単 語 g、 経路作用要素 X rを含んでいる。
【0 0 5 3】
基本構造 B S 2は、 実行ボタン aが押されたとき、 出力データ項目 gの値を式 c + d によって計算するための基本構造 (媒体がファイル) である。 式 c + dの結果を記録す る単語 eを含んでいる。 基本構造 B S 3は実行ポタン bが押されたとき、 出力データ項 目 gの値を式 c X dによって計算するための基本構造 (媒体がファイル) である。 式 c X dの計算結果を記録する単語 ίを含んでいる。
【0 0 5 4】
画面にユーザがデータを入力した (B S 1が実行された) 後に、 出力単語 gの値を計 算するための基本構造は B S 2または B S 3であるが、 どちらが実行されるべきかを指 定するのが経路作用要素 X rである。 2つの基本構造に所属する単語は、 それぞれボタ ン aと bのどちらが押されたかによつて実行が決まるので、 経路作用要素 X rは、 実行 ボタン aが押された場合 (単語 a =真、 値がある) は B S 2を、 実行ポタン bが押され た場合 (単語 b =真、 値がある) は B S 3を、 次に実行する基本構造として指定する。 また、 実行が次の基本構造に移るのは入力データがそろったときであるので、 単語 cお よび単語 dに値があることも、 経路作用要素 X rの実行条件となる。
【0 0 5 5】
基本構造 B S 2または B S 3の実行によって、 出力単語 gの値が単語 eまたは単語 f に成立する。 出力データを画面に出力するための基本構造 B S 1の出力単語 gは、 単語 eに値が成立したとき (e =真) は g = e、 単語 f に値が成立したとき ( f =真) は g =f、 と定義される。
【0 0 5 6】
上記のような単語の定義を整理すると下記の表 1のとおりである 【0 0 5 7】
【表 1】
Figure imgf000019_0001
『制御モジュール』
従来の Lyee構造は、 分割構造があり、分割単位に繰り返し処理が行われていたために、 パレツト内の各モジュールをコールして実行させるパレツト関数 (パレツトの数だけ設 置) と、 それらのパレット関数自体をコールして実行させるパレット連鎖関数 (プログ ラムに 1つ) 、 の 2種類の制御モジュールが必要であった。
【0 0 5 8】
トポロジカルソート後は、 プログラム全体が統合され、 順序化されるので、 プロダラ ム全体に 1つ、 プログラム内のモジュールをコールする制御モジュールがあれば良い。
I I章 基本構造の統合とトポロジカルソート
例 1の要件を用いて、 トポロジカルソートの具体的手順を説明する。
1 . 基本構造の隣接行列
図 4は、 図 3の単語の関係を有向グラフによって示した図である。 基本構造 B S 1に 属する入力単語である単語 a、単語 b、単語 c、 単語 dは、有向グラフによって表される 単語のネットワークの最端始点となる。 同じく基本構造 B S 1に属する経路作用要素で ある単語 X rは、 上記表 1に示したとおり、 値が成立 (次に実行する基本構造決定の真 偽判定が成立) するためには、 単語 aまたは単語 bと単語 cと単語 dが必要であるので、 これらの 4つの単語を始点とする矢印によって 4つの単語とリンクされる。 基本構造 B S 2に属す単語 e、 および、基本構造 B S 3に属す単語 fは、値が成立するために、単語 c、 単語 dおよび単語 X rが必要であるので、 これらの 3つの単語を始点とする矢印によ つて各々 3つの単語とリンクされる。 基本構造 B S 1に属す出力単語 gは、 値が成立す るために、 単語 eまたは中間単語 ίが必要であるので、 これらの 2つの単語を始点とす る矢印によって 2つの単語とリンクされる。
【0 0 5 9】
次に、 図 4で有向グラフで示した例 1のシステムを隣接行列を用いて表す。 最初に図 4の、 入力単語を扱った基本構造 B S 1 ( 9 0 1 ) を表した隣接行列 F 1を下記の数 1 に示す。
基本構造 B S 1 (入力単語) の隣接行列 -
【0 0 6 0】
【数 1】
a b ec d xr
a 「0 0 0 0 0
b 0 0 0 0 0
Fl = c 0 0 0 0 0
d 0 0 0 0 0
i 1 1 1 0
B S 1 (入力単語) の要素は単語 a、 単語 b、 単語 c、 単語 d、 単語 x rであるから、
F 1の行列はこれらの要素によって構成される。 入力単語である単語 a、 単語 b、 単語 c、 単語 dは、 始点単語を持たないので、 終点単語 a、 b、 c、 dのそれぞれの横列 (始 点単語 a、 b、 c s d、 x rとの交点) は総て始点単語として用いないことを示す 「0」 となる。 経路作用要素である単語 x rは、 図 4の有向グラフに示したとおり、始点として 単語 a、 単語 単語 単語 dを持つので、 終点単語 x rの横列は、 これらの始点単語 との交点は始点であることを示す 「 1」 となる。
【0 0 6 1】
次に、 基本構造 B S 2および B S 3 (以下、 基本構造 B S 2 & B S 3と記す) を合わ せたものを表す隣接行列 F 2を下記の数 2に示す。
基本構造 B S 2 & B S 3の隣接行列
【0 0 6 2】
【数 2】 e f
B S 2 & B S 3の要素は単語 eと単語 f のみであるので、 F 2の行列はこれら 2つの 要素で構成される。 単語 eと単語 f はお互いに独立している (すなわち、 どちらの単語 も始点単語としてもう一方の単語を用いていない) ので、 いずれの交点も 「0」 となる。
【0 0 6 3】
基本構造 B S 1の出力単語を扱った集合の隣接行列 F 3を、 下記の数 3に示す。
基本構造 B S 1 (出力単語) の隣接行列
【0 0 6 4】
【数 3】
g
F3: g[ ]
B S 3の要素は単語 gのみであるので、 F 3の行列は単語 g 1つのみで構成される。 単語 gは始点として自身を用いないので、 交点は 「0」 となる。
【0 0 6 5】
以上で、 例 1のシステムを構成する基本構造単位に、 同一基本構造内の要素間の関係 を隣接行列に表した。
2 . 結合隣接行列による基本構造の統合
次に、 これらをシステム全体として 1つの隣接行列として表すために、 各基本構造の 要素である単語と他の基本構造の要素である単語との関係を示すことによつて基本構造 をリンクする結合隣接行列 (connection matrix) について説明する。
【0 0 6 6】
任意の基本構造の単語と他の基本構造の単語の関係は、 図 4に示したように終点単語 と始点単語の関係によって表わされている。 基本構造同士は、 それに属する単語の関係 によってリンクされていると言える。 図 4から以下のことが分かる。
1 ) 基本構造 B S 1 (入力) の単語を終点単語としたとき、 いずれの他の基本構造の単 語も、 B S 1 (入力) の単語より後に現れるので、 始点単語となりえない。
2 ) 基本構造 B S 2 & 3の単語を終点単語としたとき、 B S 2 & 3の単語より前に現れ る B S 1 (入力) の単語は始点単語となりえるが、 BS 1 (出力) の単語は始点単 語となりえない。
3) 基本構造 BS 1 (出力)の単語を終点単語としたとき、 BS 2 & 3および BS 1 (入 力) のいずれの単語も、 BS 1 (出力) の単語より前に現れるので、 始点単語とな りえる。
【0067】
上記の考察の結果、 基本構造をリンクするための結合隣接行列として重要なのは、 任 意の基本構造と、 それに属す単語の始点単語になりえる単語を含む基本構造との関係を 表す結合隣接行列であることがわかる。 なぜなら、 有向グラフで示されるように、 単語 間の関係は始点単語から終点単語へと向かう関係のみが存在するがゆえに、 基本構造間 の関係も、 それと同様に始点単語を含む基本構造から終点単語を含む基本構造へと向か う関係のみが存在し、 逆の関係は存在しない (そのような基本構造間の関係を表す結合 隣接行列は、 すべての交点が 0となる) からである。
【0068】
以下に、 例 1の基本構造をリンクする (始点単語を含む基本構造から終点単語を含む 基本構造へと向かう関係を表す) 結合隣接行列を 1つづつ考察する。
【0069】
数 4は、 基本構造 B S 1 (入力〉 (始点単語) から基本構造 B S 2 &B S 3 (終点単 語) への関係を示す結合隣接行列 F C 1である。
【0070】
【数 4】
a b c d X r
e 0 0 1 1 1
f 0 0 1 1 1 隣接行列 F C 1は、 基本構造 B S 2 &B S 3の要素である単語 eと単語 f を終点単語 においたとき、 BS 1 (入力) の要素である単語 a、 単語 b、 単語 c、 単語 d、 単語 が始点単語として用いられる状態を表し、 2つの基本構造の関係を示している。 図 4で 示したように、 単語 eおよび単語 f は、 は単語 c、 単語 d、 単語 xrを始点単語に用いる。 従って、 FC 1において、 終点単語 eおよび終点単語 f の行と、 始点単語 c、 d、 xr との交点は 「1」 となり、 その他の始点単語との交点は 「0」 となる。
【0071】 数 5は、 基本構造 BS L (入力) および基本構造 B S 2&B S 3 (始点単語) から、 基本構造 B S 1 (出力) (終点単語) への関係を示す隣接行列 F C 2を表している。
【0072】
【数 5】
a b c a e /
Figure imgf000023_0001
隣接行列 F C 2は、 基本構造 B S 1 (出力) の要素である単語 gを終点単語においた とき、 有向グラフにそれ以前に現われる B S: (入力) 、 BS 2、 B S 3の要素である 単語 a、 単語 単語 c、 語 d、 単語 xr単語 e、 単語 が始点単語として用いられ る状態を表して、 2つのダル プの関係を表している。 図 4で示したように、 単語 gは、 単語 eと単語 f を始点単語に用いる。 従って、 FC2において、 終点単語 gの行と、 始 点単語 eおよび f との交点は 「1」 となり、 その他の始点単語との交点は 「0」 となる。
【0073】
以上が、 例 1のシステムを構成する基本構造間のリンクに意味を持つ結合隣接行列で あった。 システム全体として 1つの隣接行列へ統合する過程の説明を簡便にするために、 下記に、 関係が存在しない基本構造間の結合隣接行列も示す。 数 6は、 基本構造 BS 2 &BS 3 (始点単語) から基本構造 BS 1 (入力) (終点単語) の関係がないことを示 す結合隣接行列 F C 3である。
【0074】
【数 6】
Figure imgf000024_0001
数 7は、 基本構造 B S I (出力) (始点単語) 力 ら基本構造 BS (入力) (終点単 語) の関係がないことを示す結合隣接行列 F C 4である。
【0075】
【数 7】
Figure imgf000025_0001
数 8は、 基本構造 B S 1 (出力) (始点単語) から基本構造 B S 2 &B S 3 (終点単 語) の関係がないことを示す結合隣接行列 F C 5である。
【0076】
【数 8】
Figure imgf000025_0002
上記に示した隣接行列 F 1から F 3、 結合隣接行列 FC 1から FC 5を用いて、 例 のシステムを 1つの隣接行列 Fとして表したものが数 9である。
【0077】
【数 9】 a b c d xp e f g
Figure imgf000026_0001
上記数式で、 「F=」 の右辺に示された、 F l、 F 2、 F 3、 FC 1、 FC 2と 0 (行 列の交点が総て 0である隣接行列で、 FC 3、 FC4、 FC 5に相当する) で構成され た行列は、 基本構造単位の隣接行列と結合隣接行列がどのように統合されてシステム全 体を表わすかを示している。 次に、 それらの要素を単語に変えたものが、 その右辺にあ る a、 b、 c、 d、 x r e、 f 、 gを行列の要素とする隣接行列である。 F l、 F 2、 F 3、 FC 1、 FC 2、 FC3、 FC4、 F C 5がどのように統合されて Fを構成する のか、 さらにわかりやすく示したのが図 5である。 図 5の 1001の部分が F 1、 10 02が F 2、 1003が F 3、 1004が FC 1、 1005が F C 2である。 行列の交 点が総て 0である結合隣接行列は、 FC3が 1006、 FC4が 1007、 FC 5が 1 008を構成する。
【0078】
以上のようにして、 2つ以上の基本構造から成る 1つのシステムは、 1つの隣接行列 で表すことができる。
【0079】
以上でシステム全体を 1つの隣接行列で表わすことができたので、 このシステムの隣 接行列に対して、 同一出願人による特許文献 6で開示されるトポロジカルソートを行つ て、 総ての単語の値の状態が最少実行回数で確定 (すなわち総ての出力単語の生成が完 了) するような最適順序に単語単位のプログラムの並び替えを行う。
【0080】
例 1のシステムの隣接行列 Fをみれば、 図 6に示すように、 値が 1である始点単語と の交点は総て左下三角形 (1 3 0 1 ) の内にある。 I章で述べたように、 これは単語が 最適順序に並んでレ、ることを意味する。 従って、 ¾ 9の隣接行列 Fは、 すでにトポロジ カルソート済みであって、 初期値の単語の状態ベクトルを与えれば、 最少実行回数で出 力単語の生成を完了することができる単語の順序になっているといえる。
【0 0 8 1】
ここで、 トポロジカルソートを施す効果について補足する。 トポロジカルソートによ つて最適実行順序に並んだ単語単位のプログラムは、 1巡処理で総ての出力単語の値を 生成することができる。 し力 し、 システム全体に対して言及する場合には、 より正確に は 「最少実行回数」 で実現できるということが適切である。 なぜなら、 システム全体で みたときには、 集計処理のように、 一時的記録領域を置くことによって同じ計算式を繰 り返し利用する必要がある処理を含む場合があるからである。もちろん、この場合の「繰 り返し」 は、 無駄な繰り返しではない。 集計するデータの数マイナス 1が最少繰り返し 数になる。 このような集計処理も、 結合隣接行列を用いて 1つの隣接行列に表わすこと ができる。
【0 0 8 2】
なお、 ここでは探索技法の一例としてトポロジカル ·ソートを例にとり説明したが、 他の探索の技法を用いても良い。 また、 隣接行列定義については、 本稿では理解の容易 さを助けるために入れたが、 本質的には必須のステップではない。 つまり、 隣接行列を 定義することなく、 宣言間関係の規定から、 直接に、 或いは有向グラフ作成を介して、 トポロジカル'ソート等の探索に至ることも本発明の思想の範囲内であり、 本発明の目 的とするところを実現し得る。
3 . プログラムの隣接行列の検証
本セクションでは、 前セクションで示したシステムの隣接行列 Fが、 出力単語の値を 生成する関数として機能し、 しかも、 トポロジカル ·ソート済みであるので、 最少実行 回数で総ての出力単語の生成を完了できることを、 同一出願人による特許文献 6で開示 される単語の状態べクトルをかける計算操作によって検証する。 出力単語 gの値が決定 されれば、 隣接行列 Fは関数として機能すると言える。 また、 例 5のシステムは、 前述 の集計処理のような繰り返し処理を含まないので、 1巡処理で出力単語 gの値の状態が 確定すれば、 最少実行回数で処理が完了したと言える。
【0 0 8 3】
例 1のシステムにおいて、 ユーザが入力を行う前の単語の値の状態、 すなわち単語の 状態べクトル Xの初期値は、 同一出願人による特許文献 6で開示されるように総ての要 素が 「null (未決定) 」 で、 下記の数 1 0のようになる。
【0 0 8 4】
【数 1 0】
Figure imgf000028_0001
数 9の隣接行列 F (すなわち例 1のシステム) に、 数 10の状態べクトル Xをかける 計算処理を施す (すなわち、 例 1のシステムに入力を行う) 。 FXの計算処理によって 変化する単語の値の状態を 1つの終点単語ごとに追って説明する。
(1) 1巡目処理中の終点単語 aの計算
1巡目処理中の終点単語 aの計算は、 次のようになる。
a =0-null + 0-null + 0-null +0-null + 0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 aは始点単語を持たないので、どのような値の状態をかけても値の状態が確定 し、 nullから(+1)へ変化する。 すなわち、 これは入力によって値が確定したことを表わ している。 その結果、 1巡処理中の単語 a行完了後の各単語の値の状態は、 以下の表 2 のとおりである。
【0085】
【表 2】
Figure imgf000029_0001
(2) 1巡目処理中の終点単語 bの計算
1巡目処理中の終点単語 bの計算は、 表 2の単語の値の状態を用いるので次のように なる。
b =0· (+l)+0-null + 0-null +0-null + 0-null+0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 bも始点単語を持たないので、 どのような値の状態をかけても値の状態が確 定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 b行完了後の各単語の値 の状態は、 以下の表 3のとおりである。
【0086】
【表 3】
Figure imgf000029_0002
例 1のシステムでは、 単語 aと単語 bは画面上の 2者択一の指示ボタンであるので、 どちらか一方が選択されることによって、 双方の値の状態が確定することになる。
(3) 1巡目処理中の終点単語 cの計算
1巡目処理中の終点単語 cの計算は、 表 3の単語の値の状態を用いるので次のように なる。
c =0· (+l)+0-(+l)+0-null +0-null + 0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 cも始点単語を持たないので、 どのような値の状態をかけても値の状態が確 定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 c行完了後の各単語の値 の状態は、 以下の表 4のとおりである。
【008 7】
【表 4】 a b c d e f g 値の状態 +1 +1 +1 mil 1 null null null null
(4) 1巡目処理中の終点単語 dの計算
1巡目処理中の終点単語 dの計算は、 表 4の単語の値の状態を用いるので次のように なる。
d =0. (+1)+0· (+1)+0· (+1) +0-null + 0-nulH-0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) = (+1)
入力単語 dも始点単語を持たないので、 どのような値の状態をかけても値の状態が確 定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 d行完了後の各単語の値 の状態は、 以下の表 5のとおりである。
【0088】
【表 5】
Figure imgf000030_0002
(5) 1巡目処理中の終点単語 xrの計算
1巡目処理中の終点単語 X rの計算は、 表 5の単語の値の状態を用いるので次のよう になる。
r =1· (+1)+1·(+1)+1·(+1) +1· (+l)+0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 x rの始点単語となる単語 a、 b、 c、 dの値の状態がすでに確定した、 すなわ ち、 表 1に示した経路作用要素である単語 x rの定義式実行条件 (1) および (2) が 満たされたので、 単語 xrの値の状態も nullから確定済みの(+1)へ変化する。 その結果、 1巡処理中の単語 X r行完了後の各単語の値の状態は、 以下の表 6のとおりである。
【008 9】
【表 6】
Figure imgf000030_0001
(6) 1巡目処理中の終点单語 eの計算
1巡目処理中の終点単語 eの計算は、 表 6の単語の値の状態を用いるので次のように なる。
e =0· (+1)+0· (+D+1- (+1) +1· (+D + 1- (+l)+0-null + 0-null + 0-null
= (+1) + (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 eの始点単語となる単語 c、 dおよび X rの値の状態がすでに確定済みであるの で、 すなわち、 定義式 c + dの始点単語の値が決定済み、 かつ経路作用要素 xrが次に 実行する基本構造を指定したので、 単語 eの値の状態も nullから確定済み (+1)へ変化す る。 その結果、 1巡処理中の単語 e行完了後の各単語の値の状態は、 以下の表 7のとお りである。
【00 90】
【表 7】
Figure imgf000031_0001
(7) 1巡目処理中の終点単語 f の計算
1巡目処理中の終点単語 f の計算は、 表 7の単語の値の状態を用いるので次のように なる。
f =0· (+1)+0· (+1)+1· (+1) +1· (+D + 1- (+D+0- (+l)+0-null+0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 f の始点単語となる単語 C、 dおよび X rの値の状態がすでに確定済みであるの で、 単語 f の値の状態も nullから(+1)へ変化する。 その結果、 1巡処理中の単語 f行完 了後の各単語の値の状態は、 以下の表 8のとおりである。
【00 9 1】
【表 8】
Figure imgf000031_0002
例 1のシステムでは、 単語 eと単語 f はそれぞれの実行条件が 2者択一の条件である ので、 どちらか一方の条件が真と確定すれば、 他方の条件は偽と確定し、 双方の値の状 態が確定することになる。 たとえば、 B S 2が指定されれば、 単語 eの定義式実行条件 =真が確定して単語 eに値が与えられることによって値の状態が確定する。 一方、 単語 f は、 定義式実行条件 =偽が確定して単語 f に値が与えられないことによって値の状態 が確定する。 従って、 経路作用要素がどちらか一方の基本構造を指定したとき、 単語 e も単語 f も値の状態が確定済みとなるのである。
(8) 1巡目処理中の終点単語 gの計算
1巡目処理中の終点単語 gの計算は、 表 8の単語の値の状態を用いるので次のように なる。
g =0·(+1)+0· (+1)+0·(+1) +0 · (+1) +0 · (+1) + 1 - (+1) + 1 - (+1) +0 · null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 gの始点単語となる単語 eおよび f の値の状態がすでに確定済みであるので、 単 語 gの値の状態も nullから(+1)へ変化する。 その結果、 1巡処理中の単語 g行完了後の 各単語の値の状態は、 以下の表 9のとおりである。
【009 2】
【表 9】
Figure imgf000032_0001
以上で隣接行列 Fの総ての単語行の計算処理が 1巡したことになる。 従って、 表 9が FXの結果となる。 下記の数 1 1の状態べクトル X が FXの結果である。
【009 3】
【数 1 1】
Figure imgf000033_0001
以上のように、 隣接行列 Fは、 トポロジカルソートによって単語単位プログラムが最 適順序で実行されるように並んでいるので、 1巡の計算処理の実行で総ての単語の値の 状態が確定し、 出力単語 gの値を成立することができた。
4 . 経路作用要素の排除
経路作用要素の実行条件は、 経路作用要素によって指定される基本構造に属する全単 語の集合 (1つ以上からなる) の定義式を実行するための条件と等しい。 なぜなら、 そ の基本構造の単語の総ては、 その経路作用要素の条件が満されたときに実行されるから である。 従って、 経路作用要素の実行条件は、 経路作用要素によって指定される基本構 造に属す単語の条件に移すことができる。
【0 0 9 4】
例 1のシステムの場合で具体的に述べると次のようになる。 まず、 経路作用要素であ る単語 X rと、 単語 eおよび単語 f の定義式と定義式実行条件は下記の表 1 0の通りで めった。
【0 0 9 5】
【表 1 0】 ■φ-RR 定義式 疋载式実 tr条件
X c B S 2を指定 (1) a=真 (ボタン aが押され、 aに値がある) かつ、 :=真ぉょぴ<^ 真
B S 3を指定 {2) b=真 (ボタン bが押され、 bに値がある) かつ、 。=真ぉょぴ(3=真
e c + d X §BS 2を指定
f d X d が833を指定 従って、 Xrの条件 (1) 「a=真かつ、 0=真ぉょぴ(1=真」 を、 この条件が成立 するとき指定する基本構造 B S 2に属する単語 eの実行条件 「XrがBS 2を指定」 と 置き換え、 条件 (2) 「b=真かつ、 c=真および d=真」 をこの条件が成立するとき 指定する基本構造 BS 3に属する単語 f の実行条件 「 ]:が833を指定」 と置き換え る、 ということになる。 この結果、 単語 eおよび単語 f の定義式、 定義式実行条件は下 記の表 1 1のようになる。
【0096】
【表 1 1】
Figure imgf000034_0001
表 1 1のように、 経路作用要素の実行条件を、 指定先の基本構造の単語の実行条件に 置き換えると、 B S 1と B S 2および B S 3のリンクは、 B S 2および B S 3の単語の 実行条件によって成立するので、 経路作用要素は単に、 次の基本構造の実行に移る条件 が整ったこと (入力単語 cおよび dに値があり、 かつポタン aまたは bが押された) を 示すだけの意味しか持たなくなる。 これは、 経路作用要素を取り除いてもシステムの意 味に変化が生じないことを意味する。 従って、 経路作用要素の実行条件を、 その条件の 成立によって指定される基本構造の単語の実行条件に置き換える操作を行った後、 シス テム全体の隣接行列から、 経路作用要素を除くことができる。
【0097】
図 7は、 経路作用要素を取り除いて、 例 1のシステムの単語の関係を有向グラフで表 したものである。 図 7では、 経路作用要素である単語 xrがなくなり、 単語 eおよび単語 f と始点単語との関係は、 上記の表 1 1で定義された定義式と定義式実行条件に従って 示されている。 すなわち、 単語 eは、 始点単語として単語 a (定義式実行条件「実行ボタ ン aが押された」 ) 、 単語 cおよび単語 d (定義式 「c + d」 および、 定義式実行条件 「。=真ぉょぴ(1=真」 ) を持つ。 単語 f は、 始点単語として単語 b (定義式実行条件 「実行ボタン bが押された」 ) 、 単語 cおよび単語 d (定義式 「c + dj および、 定義 式実行条件 「c =真および d=真」 ) を持つ。 単語 eおよび単語 f から単語 gへの関係 は図 4と変らない。
【0098】
経路作用要素を取り除いた例 1のシステムを、 図 7の有向グラフに従って隣接行列に 表わせば、 以下のようになる。 数 12の F 1'は、 基本構造 BS 1 (入力) の隣接行列で ある。 経路作用要素である単語 が要素から削除されている。
【0099】
【数 12】
Figure imgf000035_0001
Figure imgf000035_0002
数 1 3の F 2'は、 基本構造 B S 2&B S 3の隣接行列である c
【0100】
【数 13】 : /
Figure imgf000036_0001
数 1 4の F 3 'は、 基本構造 B S (出力) の隣接行列である t
【0 1 0 1】
【数 1 4】
Figure imgf000036_0002
数 1 5の F C 1,は、基本構造 B S 1 (入力) から基本構造 B S 2 & B S 3への関係を 示す結合隣接行列である。 経路作用要素が削除されたので、 始点単語の要素として単語 X rが削除されている。 単語 eおよび単語 f は、 表 1 1に示したように経路作用要素の 実行条件を移したことで、 それぞれ新たに単語 a、 単語 bを始点単語として持つことに なった。 従って、 終点単語 eは、 始点単語 cおよび dの他に単語 aとの交点が 1となつ ている。 終点単語 ίは、 始点単語 cおよび dの他に単語 bとの交点が 1となっている。
【0 1 0 2】
【数 1 5】 a b c a
Figure imgf000036_0003
数 16の FC 2'は、 基本構造 B S 2&B S 3から基本構造 B S 1 (出力) への関係を 示す結合隣接行列である。 経路作用要素が削除されたので、 始点単語の要素として単語 Xrが削除されている。
【0103】
【数 16】 翁 & € d f JF f
Figure imgf000037_0001
1J 数 1 7の FC 3,は、 基本構造 B S 2&B S 3から基本構造 B S 1 (入力) への関係が ないことを示す結合隣接行列である。 経路作用要素が削除されたので、 始点単語の要素 として単語 Xrが削除されている。
【0104】
【数 1 7】
Figure imgf000037_0002
数 18の FC4'は、 基本構造 BS 1 (出力) から基本構造 BS 1 (入力) への関係が ないことを示す結合隣接行列である。 経路作用要素が削除されたので、 始点単語の要素 として単語 Xrが削除されている。 【0105】
【数 18】 g
Figure imgf000038_0001
数 19の F C 5,は、 基本構造 B S (出力) から基本構造 BS 2 &B S 3への関係が ないことを示す結合隣接行列である。
【0106】
【数 19】
Figure imgf000038_0002
システムの隣接行列 Fは、 経路作用要素の条件の置き換えと経路作用要素の削除を行 うと、 下記の数 20に示す隣接行列 F'で表わすことができる。
【0107】 【数 20】
b c d e J f ff
Figure imgf000039_0001
上記数式で、 「F, =」 の右辺に示された、 F l'、 F 2,、 F 3'、 FC 1,、 FC 2'と 0 (行列の交点が総て 0である隣接行列で、 FC 3'、 FC4,、 FC 5,に相当する) で 構成された行列は、 基本構造単位の隣接行列と結合隣接行列がどのように統合されてシ ステム全体を表わすかを示している。 次に、 それらの要素を単語に変えたものが、 その 右辺にある a、 b、 c、 d、 e、 f、 gを行列の要素とする隣接行列である。 F l'、 F 2,、 F 3,、 FC 1,、 FC 2,、 F C 3 '、 F C 4,、 F C 5,がどのように統合されて F, を構成するのか、 さらにわかりやすく示したのが図 8である。 図 8の 1201'の部分が F l,、 1202が F 2,、 1203が F 3'、 1204が FC 1,、 1205が FC 2'で ある。 行列の交点が総て 0である結合隣接行列は、 FC3,が 1206、 FC4'が 12 07、 FC 5,が 1208を構成する。
【0108】
以上のようにして、 2つ以上の基本構造から成る 1つのシステムを、 経路作用要素を 排除して、 1つの隣接行列で表わすことができる。
【0109】
次に、 このシステムの隣接行列に対して、 トポロジカルソートを行って、 総ての単語 の値の状態が最少実行回数で確定 (すなわち総ての出力単語の生成が完了) するような 最適順序に単語単位のプログラムの並び替えを行う。 隣接行列 F,をみると、図 9に示す ように、 値が 1である始点単語との交点は総て左下三角形 (1601) 内にある。 同一 出願人による特許文献 5で示されるように、 これは単語が最適順序に並んでいることを 意味する。 従って、数 20の隣接行列 F,は、すでにトポロジカルソート済みであって、 初期値の単語の状態べクトノレを与えれば、 最少実行回数で出力単語の生成を完了するこ とができる単語の順序になっているといえる。 5. 経路作用要素を排除した構造の検証
このセクションでは、 前セクションで示した、 経路作用要素を排除したシステムの構 造を示す隣接行列 F'が、経路作用要素を排除する前の構造である隣接行列 Fと同じ関数 機能を持つことを検証する。以下に、隣接行列 F'に単語の状態べクトルを与えて出力単 語 gの値を求める過程を示す。 m回目の計算処理の結果、 単語の状態べクトル Xmの値 が総て確定済みとなれば、 F'も Fと同等に機能する関数だと言える。 また、 トポロジカ ルソートを施したことによって、 最少実行回数で出力単語の生成を完了できることも検 証する。 例 1のシステムである F'も、 1巡処理で単語 gの値の状態が確定すれば、 最少 実行回数で実行できたと言える。
【01 10】
前述したように、 単語の状態ベクトルの初期値は総ての要素が 「null (未決定) 」 で あるので、 F'に最初に与えるべき単語の状態べクトル X'は下記の数 21のようになる。
【01 1 1】
【数 21】
X、
Figure imgf000040_0001
数 20の隣接行列 F' (すなわち例 1のシステム) に、 数 20の状態ベクトル X'をか ける計算処理を施す (すなわち、 例 1のシステムに入力を行う) 。 F'X,の計算処理に よって変化する単語の値の状態を 1つの終点単語ごとに追って説明する。
(1) F'l巡目処理中の終点単語 aの計算 終点単語 aは、計算処理に X,の単語の値の状態を用いるので、 1巡目処理中の終点単 語 aの計算は、 次のようになる。
a =0-null + 0-null + 0-null +0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 aは始点単語を持たないので、 値の状態が確定し、 nullから(+1)へ変化する。 すなわち、 これは入力によって値が確定したことを表わしている。 その結果、 1巡処理 中の単語 a行完了後の各単語の値の状態は、 以下の表 12のとおりである。
【01 12】
【表 12】
Figure imgf000041_0001
(2) F'l巡目処理中の終点単語 bの計算
終点単語 bは、 計算処理に表 12の単語の値の状態を用いるので、 1巡目処理中の終 点単語 bの計算は、 次のようになる。
b =0· (+l)+0-null + 0-null +0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 bも始点単語を持たないので、 値の状態が確定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 a行完了後の各単語の値の状態は、 以下の表 13のとおり である。
【01 13】
【表 13】
Figure imgf000041_0002
(3) F'l巡目処理中の終点単語 cの計算 終点単語 cは、 計算処理に表 13の単語の値の状態を用いるので、 1巡目処理中の終 点単語 cの計算は、 次のようになる。
c =0· (+D+0- (+l)+0-null +0-null + 0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 cも始点単語を持たないので、 値の状態が確定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 c行完了後の各単語の値の状態は、 以下の表 14のとおり である。
【01 14】
【表 14】
Figure imgf000042_0001
(4) F'l巡目処理中の終点単語 dの計算
終点単語 dは、 計算処理に表 14の単語の値の状態を用いるので、 1巡目処理中の終 点単語 dの計算は、 次のようになる。
d =0· (+D+0- (+D+0- (+1) +0-null+0-null + 0-null+0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
入力単語 dも始点単語を持たないので、 値の状態が確定し、 nullから(+1)へ変化する。 その結果、 1巡処理中の単語 d行完了後の各単語の値の状態は、 以下の表 15のとおり である。
【01 15】
【表 1 5】
Figure imgf000042_0002
(5) F'l巡目処理中の終点単語 eの計算 終点単語 eは、 計算処理に表 15の単語の値の状態を用いるので、 1巡目処理中の終 点単語 eの計算は、 次のようになる。
e =1· (+1)+0· (+1) + 1· (+1) +1· (+1) +0-null + 0-null + 0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 eの始点単語である単語 a、 c、 dの値の状態が確定しているので、 単語 eの値 の状態も nullから(+1)へ変化して確定する。 その結果、 1巡処理中の単語 e行完了後の 各単語の値の状態は、 以下の表 16のとおりである。
【01 16】
【表 16】
Figure imgf000043_0001
(6) F'l巡目処理中の終点単語 f の計算
終点単語 f は、 計算処理に表 16の単語の値の状態を用いるので、 1巡目処理中の終 点単語 f の計算は、 次のようになる。
f =0· (+1)+1· (+1)+1· (+1) +1· (+D+0- (+l)+0-null + 0-null
= (+1) +(+1) + (+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 f の始点単語である単語 b、 c、 dの値の状態が確定しているので、 単語 f の値 の状態も nullから(+1)へ変化して確定する。 その結果、 1巡処理中の単語 f行完了後の 各単語の値の状態は、 以下の表 17のとおりである。
【01 17】
【表 1 7】
Figure imgf000043_0002
(7) F'l巡目処理中の終点単語 gの計算
終点単語 gは、 計算処理に表 17の単語の値の状態を用いるので、 1巡目処理中の終 点単語 gの計算は、 次のようになる。
g =0·(+1)+0·(+1)+0'(+1) +0· (+1) +1· (+1) +1· (+1) +0-null
= (+1) +(+1) +(+1) +(+1) +(+1) +(+1) +(+1)
= (+1)
単語 gの始点単語である単語 e、 f の値の状態が確定しているので、 単語 gの値の状 態も nullから(+1)へ変化して確定する。 その結果、 1巡処理中の単語 g行完了後の各単 語の値の状態は、 以下の表 18のとおりである。
【01 18】
【表 18】
Figure imgf000044_0002
以上で隣接行列 F,の総ての単語行の計算処理が 1巡したことになる。従って、表 18 の単語の値の状態が F,X,の結果となる。下記の数 22の状態べクトル X, F,X,の結 果である。
【01 1 9】
【数 22】
Figure imgf000044_0001
以上のように、隣接行列 F 'は、 トポロジカルソートによって単語単位プログラムが最 適順序で実行されるように並んでいるので、 1巡の計算処理の実行で総ての単語値が確 定し、 出力単語 gの値を成立することができた。
【0 1 2 0】
また、経路作用要素の単語を除いた隣接行列 F 'も、状態べクトルの初期値を与える(入 力を行う) ことで、 隣接行列 Fと同様に総ての単語の値の状態が確定し、 出力単語 gの 値が生成できたことがわかる。 従って、 経路作用要素のあるシステムである隣接行列 F と、経路作用要素のないシステムである隣接行列 F,は、システムとして同等の処理機能 を持つことが検証できた。
【0 1 2 1】
上記で述べたように、 全体システムが複数の基本構造を有する場合に、 これを統合し、 さらに当該統合されたものに対して (例えばトポロジカルソートのような) 探索を施す ことで、 L y e e (登録商標) 等のソフトゥ アの自律的開発技術の適用に際して各段 のパフォーマンスを提供する。 これが例えば、 統合されずに複数の基本構造をそのまま 有する場合には、 本願に係る発明によるほどのパフォーマンスは得られず、 また、 トポ 口ジカルソート等の探索技法によって整序しなかった場合には本願に係る発明によるほ どのパフォーマンスは得られない。
6 . プログラムの再利用
プログラムの再利用が必要な処理は、 トポロジカルソートを行っても繰り返しが行わ れる。
どんなプログラム (アルゴリズム) でも再帰的な方法だけによつて記述することがで きる。 手続き型のプログラミング言語 (例えば、 C、 Java など) によって書かれたど んなプログラムでも、再帰プログラムと同じ役割を果たす whi 1 eプログラムによって書く ことができる。 このことは、 whileプログラムは理論的には、なんでもできることを示し ている。
しかしながら、 単語を基礎とするプログラム法では、自分自身を始点単語として使用 することができない。 例えば、 a = a + を 単語を基礎とする プログラムでは使うこ とはできない。 なぜなら、 aは、 一度決定 (decided)になると aの値は変化しないからで ある。 したがって、 再帰的使用のためには、 一時的に aの値を保持する領域とクリアす る方法が必要となる。 保持された値を始点として使用する。 この目的のために一時的に 内容が保持される領域を持つことが必要である。 この領域を一時的な単語と呼ぶ。 タリ ァするために構造作用要素 (Vector of Clear)が定義される。
Lyeeでは一般に、 作用要素は述語構造を持つ一種の単語である。 プログラムコードの 構造は単語と同じである。 単語との主な相違は同時にふたつあるいはもっと多くの単語 を扱っていることである。 その意味は外部とのインターフェースおよぴ制御構造のため の経路や領域のクリアである。
【0 1 2 2】
プログラムの隣接行列 (プログラム全体の行列) は分割された隣接行列とただ状態を 移すだけの接続行列とを使って、 1つの行列に統合化される。 接続行列は、 他のグルー プ上の単語を始点単語として使うことを示している。 したがって、 単語を基礎とするプ ログラムの数学的なモデルを使うことが可能である。 それによつて、手続き型の言語で 表現することができるすべての通常のアルゴリズムは、 単語を基礎とするプログラムの 構造で表現することができる。
【0 1 2 3】
次に、 前述の a=a+bのような、 一時的な単語を必要とする集計処理の例である(例 2 ) を用いて、 接続行列による隣接行列の統合を説明する。
(例 2 ) ファイルのある単語のそれぞれのレコード;^、 の値は先頭から順番に合計 し、 集計結果を単語 37に集計する。
【0 1 2 4】
Lyeeでは、一度決定した値は上書きできないので、 3= +; ^のように記述しこれを 再利用する。 は前回の の値を代入するための単語である。 JT3の値は、次の再利用時 に に代入するために、 一時的な領域 に転送される。 「一時的な単語」 と呼ぶ。 この 例 2を有向グラフに表すと図 1 0に示すようになる。 単語 、 x2、 は、 x4に転送 されたときにクリアされる。 単語 、 単語 、 単語 7は、 それぞれ単語 、 単語 、単 語 の再使用である。
【0 1 2 5】
図 1 0の再使用されるプログラムの部分の隣接行列 (one path matrix)は以下に示す である。
【0 1 2 6】
【数 2 3】
1,5 x2t6 ¾7 xlf5 0 0 0
Fl = 2,6 0 0 0 : one patii matrix x3t7 1 1 0 を再利用するため、 /^と再利用された/ ^とを統合する接続行列 (connection matrix)が と F3Vある。 これらは状態を伝達するだけの機能を有するものである c それぞれの終点単語が、 始点単語としてどの単語を'使用するかを示す。
【0 1 2 7】
【数 2 4】
X. X. X .
F2 = χ4 [θ 0 1 1 : connection matrix from xt , x2 , xs to 4 ふ 5 "Γ
F3 = x6 0 connection matrix from x4 to xSf x6, x7 7 L 0 - m xlt x2, x3から への接続行列である。 F3は x4から x5, x6> への接続行列 である。 /^は から ^への出力、 F 3 X 4か X 5.への カ、 のための作用要素として 理解される。 F1を再利用する全体プログラムの隣接行列が ある。
【0 1 2 8】
【数 2 5】 χΛ
Λ\ A
ΛΊ
Λ1 ο η ο ο η 0一
π η
x2 リ ο ο 0 π ο V
1
1 1 1 π η V π π
Λ
Γ — V π υ 1
1 υ π υ リ : entire system matrix 5 0 0 0 1 0 0 0 χ6 0 0 0 0 0 0 0 χΊ 0 0 0 0 1 1 0 全体プログラムの隣接行列は一巡行列と接続行列とを使って表現される。 したがって、 単語を基礎とするプログラムの数学的なモデルを使うことが可能である。 それによつて、 手続き型の言語で表現されることができるすべての通常のアルゴリズムは、 単語に基礎 とするプログラミングによって、 その構造で実現することができる。
I I I章 本発明を用いた具体例
< トポロジカルソートの数学的アルゴリズム >
具体的方法を示す前に、 半順序集合の元を要素とする配列が与えられたとき、 それを トポロジカルソートするひとつのアルゴリズムを示す。
Lyeeの仕様を単語の系で表現すると、 Lyeeにおける仕様は以下のように表現される。
X = F ( x) (式 2-1 - 3)
ここで、 汎関数 Fは以下で定義されたものである。
F (x) (i) = ( x (l) , x (2) , ..., x (n) ) , i = l,2, ..., n (式 2 - 1—2)
順序集合 (A,≤) の空でない部分集合 8が≤の下で全順序集合であるとき Bを鎖といい、 Bのどの2元も比較不能であるとき Bを反鎖という。 1回の反復処理で、右辺の始点が定義 されている数以上の端点が定義されるため、 Fは単調である。 したがって Fを繰り返すこ とによって、 次々に生成される反復列 【0 1 2 9】
【数 2 6】
Figure imgf000049_0001
は鎖である。 ここで、 kは反復の回数である。最小の反復の回数は最大の鎖のサイズであ る。 一般に、 以下の定理によって、 半順序集合は、 反鎖に分割できる。
t定理 3
半順序集合(A,≤) の最大の鎖のサイズを nとすると、 Aは n個の互いに素な反鎖に分割 される。
この定理は、 数学的帰納法によって証明される。 この定理を半順序集合である全単語 に適用すると、 以下のことが言える。 すなわち、 全単語は、 その中では順序がない n個 の単語の集合に分割される。 反復列 (数 2 6 ) の長さ (サイズ) nは単語の始点と端点 の関係から求まる鎖のうち最大のもの、 すなわち、 同期するまでに必要な最小の反復回 数を示す。
この定理の証明は、 半順序集合の元を要素とする配列が与えられたとき、 それをトポ ロジカルソートするひとつのアルゴリズムを与えている。 すなわち、 Anを反鎖とすると、 入力側から、 A1, A2,を An+1=0となるまで次々と求め、 Anの元を適当な順序で並べ、 その後 に An— の元を適当な順序で並べ、 最後に の元を適当な順序で並べれば、 昇順にトポロ ジカルソートできる。 ここで Anは極大元の集合である。 ここでは、 すなわち、 出力側に 一番近い単語の集合である。 このように並べた単語は (入力側) から実行すれば、 1 度の処理で、 すべての単語が次々と成立する。
1 . 分割構造を統合する方法
基本構造を 1つとし、 単語の並べ替えを行う, .の方法によつて生成されるプロダラ ムは以下の構造を持つ。
1) 値の生成のための W04論理要素は W03へ置く。
2) W03論理要素と W04論理要素とを統合した単語とする。等価単語はひとつの単語に統合 したものとする。
3) スタート画面の W04にすベての基本構造上の単語を置く。 このとき、 経路の作用要素 についている実行条件はそれぞれの単語に展開する。経路の作用要素は、展開しない。
4)すべての単語と入出力作用要素に対して、その始点と基本要素との関係を有向グラフ (Directed Graph)で表現し、 上記の方法で、 トポロジカルソートして順序を決め配置 する。 パレット内の反復は不要となるため設置しない。 パレット領域のクリアも、 不 要となり、 設置しない。
5) Control Areaのフラグ、 入出力の作用要素のフラグは、 クリアが必要であり、 そのま ま置く。
この結果、
1)同じ基本構造に属していた単語と入出力作用要素は、 その基本構造の経路作用要素に ついていた実行条件が等しく展開されるので、 同一の実行条件を持ち、 従って、 ソート 後もひとまとまりのグループを作り出す。
2)結果的に、 経路の実行条件により、 基本要素が再グループ化され、 そのグループの中 では、 基本要素は上から実行順に並ぶ。
2 . 事例の仕様
この例題の要件は、 生徒の成績管理システムの事例である。 このシステムでは、 総務 担当者が生徒の名前を登録し、 先生が生徒のテストごとの点数を登録、 学期末には総合 評価を登録することができる。 このシステムは、 図 1 1に示す 「初期画面」 、 図 1 2に 示す 「生徒登録画面」 、 図 1 3に示す 「成績管理画面」 の 3つの画面と、 管理者と先生 の IDとパスワードが登録された「ID&パスワードファイル」、生徒の名前や IDが登録され ている 「生徒名ファイル」 、 生徒別テストごとの点数が登録されている 「テスト別成績 ファイル」 、 生徒ごとの学期末総合評価が登録されている 「総合評価ファイル」 、 の 4 つのファイルから構成されている。
初期画面は、 成績管理システムを起動したときに表示される画面である。 Exitボタン を押すとシステムは終了する。 IDとパスワードのフィールドに入力して、 0Kボタンを押 すと、システムは、入力されたデータと ID&パスヮードファイルに登録されているデータ を参照 (読み込み) し、 入力されたデータが総務担当者のものか、 先生のものか、 ある いは、 そのいずれでもないか、 を判定する。 判定の結果、 IDとパスワードが管理者のも のならば、 生徒登録画面を表示、 先生のものなら成績管理画面を表示、 いずれのもので もない場合は、 初期画面を表示する。
【0 1 3 0】
生徒登録画面は、 総務担当者が生徒名、 生徒 ID番号を登録する画面である。 初期画面 で判定した IDとパスワードが、 総務担当者のものであった場合に表示される画面で、 表 示のときには、 システムは、 生徒名ファイルを参照して、 すでに登録済みである生徒の データを生徒一覧のフィールドに表示する。 画面が表示された後、 新規登録のフィール ドに生徒名と生徒 ID番号を入力し、 登録ボタンを押すと、 入力したデータが生徒名ファ ィルに登録 (書き込み) される。 戻るボタンを押すと、 初期画面に戻ることができる。 【0 1 3 1】
成績管理画面は、 生徒のテストごとの点数と総合評価の登録、 参照を行う画面である。 初期画面で判定した IDとパスヮードが先生のものであったとき表示される。 画面表示の ときには、 システムは、 生徒名ファイルを参照して、 アクセスしている先生が担当する 生徒名と生徒 ID番号の一覧を、 生徒名のテキストボックスに表示可能な選択候補リスト として用意する。 総務担当者が、 テキストボックスの右端のボタンを押して、 生徒名リ ストを表示させ、 参照したい生徒名と ID番号を選択 (入力) すると、 システムはテスト 別成績ファイルを参照して、 入力された生徒のテスト結果と、 テスト結果の平均点を計 算して表示する。 総合評価がすでに登録されている場合は、 同時に、 総合評価ファイル を参照して、 総合評価を表示する。 新たなテスト結果を登録するときには、 テスト結果 登録フィールドに、 選択されている生徒のデータを入力し、 登録ボタンを押す。 システ ムは、 新規データをテスト別成績ファイルに登録し、 同時に、 テスト結果フィールドの 内容を新規データも含めた内容に更新して表示し、 平均点も再計算して表示する。 総合 評価を登録するときには、 総合評価登録フィールドに、 選択されている生徒の総合評価 を入力し、 登録ボタンを押す。 システムは、 総合評価のデータを総合評価ファイルに登 録し、 同時に、 総合評価フィールドに登録したデータを表示する。 戻るボタンを押すと、 初期画面に戻ることができる。
この成績管理プログラムの要件、 および、 このプログラムを、 従来の基本構造に分割 した構造にする場合の構造を表わした処理経路図を図 1 4に示す。
1人の学生に対して試験別成績の一覧を表示するような、同じ処理の部分的繰り返しゃ、 平均点の算出のための、 集計計算を含んでおり、 上に述べた基本的な的な処理を網羅し ている。
3.事例の実装手順
使用言語は、 C++、 画面部のみ C++の機能を用い、残りは、 Cの文法のみで記述している。 データベース 'マネージメントシステムは、 Access 97 with DO Aである。
設計時、 9基本構造に分割した要件を 1基本構造のプログラムに統合した形で、実装し た。 プログラムの生成は、 LyeeALL2 (Lyee構造プログラムのコード自動生成ツール) を 用い、そのテンプレート(基本要素および制御プログラムの雛形)を基本構造統合型 Lyee プログラム用に製作変更して、 コード自動生成した。 図 1 5は、 統合型新プログラムコ ードの一部である。新プログラムの 7行目は、経路の実行条件、すなわちプロセス定義に おける実行条件であり、 基本要素はこれによって再びグループ化している。 W02パレツ トにあった基本要素は、 ソート後の順序に並んでいる。 単語は、 11,12,13,14行のように 生成式のみが残る。
基本構造を分割した状態で生成した Lyee構造のプログラムと、 Lyee方法論による新プ ログラムと比較すると以下の通りである。 この実行ステップ数と時間は、 「7人の学生か らひとりを選ぴ、 5試験の成績を表示させる」 という要件のプログラムのときのものであ る。 CPUプロセス時間はデータベースのアクセス時間を含まない値、 Totalプロセス時間 はデータベースのアクセス時間を含む全時間である。 処理時間は、 プログラムにタイム スタンプの機能を付カ卩し、 開始、 終了との差として求めた。
4.結果と評価
1) 結果
【0132】
【表 19】
Figure imgf000052_0001
実行コードの減少は主に、単語の構造が小さくなったことと、基本構造が 1つになつ たことによる。 主な変化点は、
1. 述語構造はおおよそ 21行から成る。 これが、 通常、 代入式 1行から成る生成式の みとなる。
2. W03の生成条件と W04の生成式とは 1つに統合される。
3. 作用要素については、 経路の作用要素は一つの IF文となる。 入出力の作用要素はほ ぼそのまま残る。
4. 80%のクリアの作用要素は取り除かれる。
5. 一つの基本構造ば単語や作用要素を除いて約 24KBを必要とする。 この事例では、 9個の基本構造が 1つになる。
【0133】
実行ステップ数の減少と実行時間の減少は主に繰り返しが減ったことによる。 主な変 化点は、
1. すべてのパレットは最低 2回繰り返され、 基本構造は最低 3回繰り返される。 これ 力 S、 1回になる。
2. プログラム ·コードは、 31%に削減される。
3. しかし全プロセス時間は、 それほど減少しない。 データベースのアクセス時間が支 配的であるためである。
4. データベース処理を用いないリアルタイム処理、 たとえばビル監視システムのよう なプロセス制御では、 CPU時間が支配的である。 従って、 新方法は、 プログラムの大 きさ、 処理時間とも、 プロセス制御の場合に効果が大きい。 2 ) 評価
従来の構造型プログラミングによるプログラムと比較すると、 以下のことが、 言える であろう。 現時点で、 この仕様に基づく従来の構造型プログラミングによるプログラム は、 課題を残すものであり、 また、 従来法はプログラマの技量によるため、 定性的比較 に留める。
1 ) プログラムの設計
単語の実行条件は、 プロセス定義のアクションの実行条件として、捉えることができ、 従来の Lyeeにおける設計上の困難が減少する。 Lyeeの利点である、宣言的に仕様を捉え ることは、 新プログラムではプロセス定義と単語の定義で実現される。 従って、 新プロ グラムでは、 プロセス定義によって制御のための手続きが実現されるため、 プログラム の設計は必要ない。 従来法では、 仕様を基に何らかの設計が必要である。
2 ) プログラムのサイズ
従来の構造型プログラミングによるプログラムと比較し、 新プログラムにおいて、 構 造上明らかに増加しているコードは、 ない。
3 ) 実行速度
新プログラムでは、 操り返しの回数は必要最小な数に限られるため、 従来型プログラム に比べて実行速度が遅くなる理由はない。
I V章 むすび
現状では、 Lyee方法論に基づくツールによって生成されるプログラムは、 設計時点で 分割した仕様を、 分割した状態でプログラムモジュールに展開したものである。 確かに、 要件に明白に表されている順序に関する情報を設計に活用することは、 設計の精度をあ げ、 効率化に役立つ。 し力 し、 Lyee構造のプログラムは、 実行前に、 静的に解決できる 問題点を、 実行時点で動的に解決しているため、 コードのサイズは大きぐ、 処理速度も 遅い。 ここに改善の余地がある。 設計の効率化の効果を生かしつつ、 プログラムの意味 を変えずに、 初めから基本構造に分割せずに、 プログラムを生成することが出来る。 そ うすることによって、 単語全体は 1つの領域となる。 したがって、 単語の関係が作り出 す有向グラフ上のトポロジカルソートで、 単語全体の正しい順序が決定されると、 順序 性を確保するための繰り返しは不要となる (特許文献 6参照) 。
したがって、 処理経路図を作成すること、 すなわち要件を分割してとらえることは、 システムの要件を正確にとらえるために非常に有用である。 処理経路図を作成すること は、 出力条件に共通要素を持つ単語を論理体の単位でとらえることである。 条件の共通 要素を経路作用要素に割り当てることは、 効率的にユーザ要件を定義するためには大き なメリットがある。
【0 1 3 4】
一方、 プログラムのコードを生成し、 実行する時点では、 基本構造に分割したシステ ムを統合することが有用である。 なぜなら、 システム全体の単語単位のプログラムの実 行順序を、 最少実行回数で出力単語の生成を完了できる順序に並べることができるから である。
【0 1 3 5】
本明細書では、 単語単位の宣言実行モジュールからなるシステムにおける、 出力デー タを生成するための宣言実行モジュールの処理を、 無駄な繰り返しを排除して最少実行 回数で完了し、 かつ、 プログラムサイズを小さくすることを課題として、 以下の手段で 解決することについて述べた。
1 ) 同じ出力条件を持つ単語の集合 (論理体) を、 1つの基本構造として、 システム全 体を処理経路図でとらえる。 これによつて、 同じ基本構造に属する宣言実行に共通する 実行条件 (経路作用要素がその基本構造を指定する条件) を的確にとらえることができ る。
2 ) 経路作用要素もトポロジカルソートの対象とし、 単語の関係を定義している論理要 素と同じく、 その要件を単語の関係で定義する。 すなわち、 どのような条件が成立した とき (定義式の実行条件)、 どの基本構造の実行を指定するか (定義式)、 を定義する。
3 ) この経路作用要素の定義式実行条件を、 その条件が成立するときに経路作用要素が 指定する基本構造に属するモジュールの実行条件に加えることによって、 経路作用要素 を排除する。 経路作用要素の実行条件を、 指定先の基本構造のモジュールの実行条件に 置くことによって、 経路作用要素を削除しても、 基本構造間のリンク (すなわち単語間 のリンク) が成立するので、 プログラム全体を 1つにまとめることが可能になる。
4 ) こうして得られた単一化されたプログラム全体の宣言実行モジュール群 (経路作用 要素を含めない) に対して、 トポロジカル 'ソートを行って宣言実行モジュ ル群 を最適順序に並ぴ替える。 これにより、 無駄な繰返しを回避し、 最少実行回数でプ ログラムを実行することが可能となる。
【0 1 3 6】
なお、 本発明は、 上述した実施形態および実施例には限定されず、 本発明の技術思想 の範囲内で様々な変形が可能である。 たとえば、 ビジネス 'メソッド、 ソフトウェア開 発装置、 ソフトウエア開発支援装置、 ソフトウェア開発管理装置、 あるいはこれらの機 能をコンピュータに実現するためのソフトゥエア並びに該ソフトウェアを搭載した記録 媒体,専用機、 などとしてもそれぞれ実現することが可能である。 さらに、 上記で説明 したように本発明は、 方法としても、 或いはかかる機能を備えるソフトウェアとしても、 該ソフトウェアが搭載される装置 ·ツール (ソフトウェア自体の場合も含む) としても、 さらにはシステムとしても、 実現され得るのはもとよりである。
【0 1 3 7】
例えば図 1 6は、 本発明の異なる一実施形態として、 「開発対象のソフトウエア」 を 生産するためのプログラム (ソフトウェア) 、 プログラム生成装置、 プログラム処理装 置、 ツール (装置として或いはソフトウェアとしての双方を含む) 、 ソフトウェア開発 装置、 ソフトゥ ア開発支援装置、 或いはソフトウェア開発管理装置のいずれかとして 本発明を実施する場合に機能として備える構成を示した機能プロック図である。 【0 1 3 8】
全体制御部 1 6 0 1は、 本プログラム (ソフトウェア) 、 プログラム生成装置、 プロ グラム処理装置、 ツール (装置として或いはソフトウェアとしての双方を含む) 、 ソフ トウエア開発装置、 ソフトウェア開発支援装置、 或いはソフトウェア開発管理装置の全 体の動作制御、 タイミング制御、 入出力制御等を行う機能を有しており、 当該機能を持 つ専用チップ、 専用回路、 または当該機能をコンピュータに果たさせるためのソフトゥ エア (ツールとしてのソフトウェアも含む) 、 或いは該ソフトウェアを記録した記録媒 体、 当該記録媒体を搭載した処理装置 ·管理装置 ·ツールとして実現される。
【0 1 3 9】
図 1 7は、 上記の構成を備えるプログラム (ソフトウェア) 、 プログラム生成装置、 プログラム処理装置、 ツール (装置として或いはソフトウェアとしての双方を含む) 、 ソフトウェア開発装置、 ソフトウェア開発支援装置、 或いはソフトウエア開発管理装置 のいずれかとして実施される本発明の動作を示したフローチャートである。
【0 1 4 0】
両図の説明は省略する。
【0 1 4 1】
上記のような構成を備える本発明によれば、 単語単位の宣言実行モジュールからなる プログラムにおける、 出力データを生成するための宣言実行モジュールの処理を、 無駄 な繰り返しを排除して最少実行回数で完了し、 かつ、 プログラムサイズを小さくするこ とが可能となる。
【0 1 4 2】
本発明の異なる実施体としての 「開発対象のソフトウェア」 を生産するためのプログ ラム (ソフトウェア) 、 プログラム生成装置、 プログラム処理装置、 ツール (装置とし て或いはソフトウェアとしての双方を含む) 、 ソフトウェア開発装置、 ソフトウェア開 発支援装置、 ソフトゥヱァ開発管理装置は、 1つのプログラムとして実装するユーザ要 件を、 アクセス条件を伴う論理体ごとに、 該論理体上の単語ごとに、 単語名、 定義式、 該定義式の実行条件、 入出力属性、 単語の値の属性によって宣言された単語単位の宣言 から、要件充足に必要な全ての、 L 2処理(入力単語の属性チェック処理) 、 L処理(出 力単語の値生成処理) 、 I 2処理 (論理体入力処理) 、 0 4処理 (論理体出力処理) の いずれかの宣言の実行単位を規定する手段と、 前記に既定された、 全ての L 2処理 (入 力単語の属性チェック処理) 、 L処理 (出力単語の値生成処理) 、 I 2処理 (論理体入 力処理) 、 0 4処理 (論理体出力処理) の (半〉 順序関係を定義する手段と、 前記ステ ップによって定義された (半) 順序関係で規定される前記 L 2処理、 L処理、 I 2処理、 0 4処理に対してトポロジカル · ソートを行う手段と、 前記第 3のステップによって並 ぴ替えられた宣言の実行単位の順序列にしたがって該宣言実行単位に該当する L y e e 方法論に基づく所与のコード列を配置する手段とを具備するように構成することもでき る。
【0 1 4 3】
本発明はさらに、 上述の 「開発対象のソフトウェアを生産する方法」 によって生産さ れたソフトウェア、 及び当該ソフトウェアが搭載された記録媒体或いは当該ソフトゥェ ァが搭載された装置 (ハードウェア) としても実現されるが、 この場合の本発明は、 1 つのプログラムとして実装するユーザ要件を、 アクセス条件を伴う論理体ごとに、 該論 理体上の単語ごとに、 単語名、 定義式、 該定義式の実行条件、 入出力属性、 単語の値の 属性によって宣言された単語単位の宣言から規定された、 要件充足に必要な全ての、 L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力単語の値生成処理) 、 I 2処理
(論理体入力処理) 、 0 4処理 (論理体出力処理) の宣言の実行単位が、 単語単位に宣 言された要件から定義した (半) 順序関係に基づいて行われるトポロジカル■ソートに よって並び替えられた順序列にしたがって、 該当する L y e e方法論に基づく所与のコ ード列として構成されることもできる。
【0 1 4 4】
またさらに本発明は、 上述の 「開発対象のソフトウェアを生産する方法」 によってソ フトウエアを生産するために用いられるソフトウエアコードの雛型としてのソフトウェ ァ、 及び当該ソフトウェアが搭載された記録媒体或いは当該ソフトウェアが搭載された 装置 (ハードウェア) としても実現される。
【0 1 4 5】
さらに、 本発明は、 上述の 「開発対象のソフトウェアを生産する方法」 による、 要件 から抽出した情報 (ドキュメント (紙、 データ) ) の抽出方法として、 またかかる抽出 方法によって抽出された情報 (ドキュメント (紙、 データ) ) として、 さらには当該抽 出された情報の使用方法として、 或いは、 これらの情報が搭載された情報記録媒体とし て、 または情報の抽出方法 z使用方法がコード化されたソフトウェア、 当該ソフトゥェ ァが搭載された記録媒体/装置 (ハードウェア) として、 いずれも実現することができ る関連づける情報とを備えるソフトウェア開発要件から抽出した情報として実現しても よい。
【0 1 4 6】
本発明は当該技術分野における通常の知識を有する者にとつて修正おょぴ改変が容易 に数多くなし得るので、 図示および記述されたものと寸分違わぬ構成および動作に本発 明を限定することは望ましくないことであり、 従って、 あらゆる適切な改変体および等 価体は本発明の範囲に含まれるものと見なされうる。 前述の本発明に係る実施の具体的 形態の説明および例示によって詳細に記述されたが、 本願の特許請求の範囲のみならず 本発明に係る開示事項全体に定義された本発明の範囲から逸脱することなしに、 修正、 置換、 および、 変更が数多く可能である。 【0147】
また、 本願に係る発明は、 その適用において、 上記の記述において説明される力 \ 或 いは、 図面に示された要素の詳細な解釈及ぴ組み合わせに限定されるものではない。 本 発明は、 他の実施形態が可能であり、 種々の方法で実用および実施可能である。 また、 ここで用いられた語法および用語は記述を目的とするものであり、 限定的に働くものと みなされてはならない。
【0148】
従って、 当該技術分野における通常の知識を有する者は、 本開示の基調となる概念は、 本発明の幾つかの目的を実施するための他の構造、 方法、 及ぴ、 システムを設計するた めの基礎として容易に利用され得ることを理解するはずである。 従って、 本発明の趣旨 および範囲から逸脱しない限り、 本願の特許請求の範囲にはそのような等価な解釈が含 まれるものと見なされるものである。
【0149】
上記の詳細な説明では、 有向グラフ表記、 隣接行列算出、 トポロジカル'ソート、 並 び替えという順序で本発明の思想を実現する方法について述べた。 し力 しこれらはどれ も絶対不可欠な要素というものではなく、 例えば、 有向グラフ表記の表記を経ないで直 接隣接行列算出→トポロジカル ·ソ一ト→並び替えという順序で本発明の思想を実現し てもよい。
【0150】
さらに、 有向グラフに対して、 例えば幅優先探索 (B r e a d t h— F i r s t S e a r c h) 、 反復深化法 (I t e r a t i v e De e p i n g) 、 発見的探索 (H e u r i s t i c S e a r c n) ヒル'クライミング (H i 1 1 C l i mb i n g) 、 最適優先探索 (B e s t一 F r s t S e a r c h) 、 オイラー (E u 1 e r ) の一筆書き、 ダイクストラ (D i j k s t r a) 法等の各種探索技法を組み合わせるこ とで並び替えてもよい。
【0151】
或いは、 隣接行列算出のあとを、 -れらの各種探索技法を組み合わせることで本発明 の根本思想を実現してもよい。
【0152】
また、 本発明に係る技術思想は、 例えばコンピュータソフトウェアの自動開発装置、 自動開発プログラム、 自動開発プログラムを記録した記録媒体、 伝送媒体、 紙媒体とし ても、 また、 自動開発プログラムを登載したコンピュータ '装置、 自動開発プログラム を実行するクライアント ·サーバ形式等といったカテゴリーにおいても実現、 利用可能 であることはいうまでもない。 【0 1 5 3】
さらに本発明は、 単一プロセッサ、 単一ハードディスクドライブ、 及び、 単一ロー力 ルメモリを備えたコンピュータシステムに限らず、 当該システムのオプションとして、 任意の複数または組み合わせプ口セッサ又は記憶デパイスを装備するにも適している。 コンピュータシステムは、 精巧な計算器、 掌タイプコンピュータ、 ラップトップ/ノー トプックコンピュータ、 ミニコンピュータ、 メインフレームコンピュータ、 及び、 スー パーコンピュータ、 ならびに、 これらの処理システムネットワーク組合わせを含む。 本 発明の原理に従って作動する任意の適切な処理システムによって代替されうるし、 また、 これらと組合せて用いることも可能である。
【0 1 5 4】
また、 本発明に係る技術思想は、 もとよりあらゆる種類のプログラミング言語に対応 可能である。 さらに本発明に係る技術思想は、 あらゆる種類 ·機能のアプリケーション ソフトウエアに対しても適用可能である。
【0 1 5 5】
またさらに本願発明は、 その技術思想の同一及び等価に及ぶ範囲において様々な変形、 追加、 置換、 拡大、 縮小等を許容するものである。 また、 本願発明を用いて生産される ソフトウェアが、 その 2次的生産品に登載されて商品化された場合であっても、 本願発 明の価値は何ら減ずるものではない。
【産業上の利用可能性】
【0 1 5 6】
上記で規定される本発明では、 繰返しをなくす前処理を自動で行い、 こうして得られ た前処理済の単語単位のプログラムをもとに L y e e (登録商標) 方法論により自動的 に目的プログラム生成を行う。 つまり、 ユーザ要件の洗練化 (整列) から目的プロダラ ムの生成に至るまで自動化することが可能となる。 これにより、 ソフトウェア生産の大 幅な効率向上、 生産性向上、 品質向上等、 ソフトウェア産業上に大きな効果をもたらす。
【図面の簡単な説明】
【0 1 5 7】
【図 1】 本発明の一実施形態に係るセルの概念を説明するための概念図である。
【図 2】 本発明の一実施形態に係る例 1のシステムの画面の説明図である
【図 3】 本発明の一実施形態に係る例 1のシステムの単語を基本構図単位に示した 説明図である。
【図 4】 本発明の一実施形態に係る例 1のシステムの単語の関係を表わした有向グ ラフである。
【図 5】 本発明の一実施形態に係る例 1のシステム全体を 1つの隣接行列 Fで表わ す過程を説明するための図である。
【図 6】 本発明の一実施形態に係る隣接行列 Fがトポロジカルソート済みであるこ とを説明するための図である。
【図 7】 本発明の一実施形態に係る例 1のシステムの構造から経路作用要素を削除 したときの、 単語の関係を表わした有向グラフである。
【図 8】 本発明の一実施形態に係る例 1のシステムの構造から経路作用要素を削除 したとき、 システム全体を 1つの隣接行列 F 'で表わす過程を説明するための図である。
【図 9】本発明の一実施形態に係る隣接行列 F 'がトポロジカルソート済みであるこ とを説明するための図である。
【図 1 0】 本発明の一実施形態に係る例 2を有向グラフである。
【図 1 1】 本発明の一実施形態に係る例 2の 「初期画面」 を表した図である。
【図 1 2】 本発明の一実施形態に係る例 2の 「生徒登録画面」 を表した図である。
【図 1 3】 本発明の一実施形態に係る例 2の 「成績管理画面」 を表した図である。
【図 1 4】 本発明の一実施形態に係る例 2の成績管理プログラムの要件、 および、 このプログラムを、 従来の基本構造に分割した構造にする場合の構造を表わした処理経 路図である。
【図 1 5】 本発明の一実施形態に係る統合型新プログラムコードの一部である。
【図 1 6】 本発明の異なる一実施形態として、 「開発対象のソフトウェア」 を生産 するためのプログラム (ソフトウェア) 、 プログラム生成装置、 プログラム処理装置、 ツール (装置として或いはソフトウェアとしての双方を含む) 、 ソフトウェア開発装置、 ソフトウェア開発支援装置、 或いはソフトウエア開発管理装置のいずれかとして本発明 を実施する場合に機能として備える構成を示した機能プロック図である。
【図 1 7】 本発明の一実施形態に係る上記の構成を備えるプログラム (ソフトゥェ ァ) 、 プログラム生成装置、 プログラム処理装置、 ツール (装置として或いはソフトゥ エアとしての双方を含む) 、 ソフトウェア開発装置、 ソフトウェア開発支援装置、 或い はソフトウェア開発管理装置のいずれかとして実施される本発明の動作を示したフロー チヤ一トである。
【符号の説明】 101 同期範囲
1 101 基本構造 B S 1 (入力 }
1 102 基本構造 B S 2
1 103 基本構造 B S 3
1 104 基本構造 B S 1 (出力)
1 201 隣接行列 F 1'
1 202 隣接行列 F 2'
1203 隣接行列 F 3'
1 204 結合隣接行列 FC 1'
1205 結合隣接行列 FC 2'

Claims

【書類名】 請求の範囲
【請求項 1】
1つのプログラムとして実装するユーザ要件を、 アクセス条件を伴う論理体ごとに、 該論理体上の単語ごとに、 単語名、 定義式、 該定義式の実行条件、 入出力属性、 単語の 値の属性によって宣言された単語単位の宣言から、 要件充足に必要な全ての、 L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力単語の値生成処理) 、 I 2処理 (論理 体入力処理) 、 0 4処理 (論理体出力処理) のいずれかの宣言の実行単位を規定する第 前記に規定された、 全ての L 2処理 (入力単語の属性チェック処理) 、 L処理 (出力 単語の値生成処理)、 I 2処理(論理体入力処理)、 O 4処理(論理体出力処理) の(半) 順序関係を定義する第 2のステップと、
前記ステップによって定義された (半) 順序関係で規定される前記 L 2処理、 L処理、 I 2処理、 0 4処理に対してトポロジカル ·ソートを行う第 3のステップと、
前記第 3のステップによって並び替えられた宣言の実行単位の順序列にしたがって該 宣言実行単位に該当する L y e e方法論に基づく所与のコード列を配置する第 4のステ ップと
を具備することを特徴とするソフトゥエア生成方法。
PCT/IB2004/003266 2003-10-06 2004-10-06 ソフトウェア生成方法 WO2005043271A2 (ja)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2005515082A JPWO2005043271A1 (ja) 2003-10-06 2004-10-06 ソフトウェア生成方法
US10/574,703 US20070169006A1 (en) 2003-10-06 2007-01-29 Software generation method

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2003-346442 2003-10-06
JP2003346442A JP2005115498A (ja) 2003-10-06 2003-10-06 ソフトウェア開発前処理方法、ソフトウェア制御方法、ソフトウェア開発方法並びにソフトウェア開発装置

Publications (3)

Publication Number Publication Date
WO2005043271A1 WO2005043271A1 (ja) 2005-05-12
WO2005043271A2 true WO2005043271A2 (ja) 2005-05-12
WO2005043271A3 WO2005043271A3 (ja) 2005-09-01

Family

ID=34539362

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/IB2004/003266 WO2005043271A2 (ja) 2003-10-06 2004-10-06 ソフトウェア生成方法

Country Status (3)

Country Link
US (1) US20070169006A1 (ja)
JP (2) JP2005115498A (ja)
WO (1) WO2005043271A2 (ja)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007018295A1 (ja) * 2005-08-05 2007-02-15 Catena Corporation プログラム実行順序決定装置および方法
JP2014081934A (ja) * 2012-10-12 2014-05-08 Boeing Co データ依存型制約管理システムにおける計算計画のためのシステムおよび方法
US10339458B2 (en) 2012-10-12 2019-07-02 The Boeing Company System and method for rapid and robust uncertainty management during multidisciplinary analysis
US10339459B2 (en) 2012-10-12 2019-07-02 The Boeing Company System and method for rapid and robust uncertainty management during multidisciplinary analysis

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110288931A1 (en) * 2010-05-20 2011-11-24 Google Inc. Microsite models
JP5630863B2 (ja) 2010-11-26 2014-11-26 インターナショナル・ビジネス・マシーンズ・コーポレーションInternational Business Machines Corporation 構造化文書に含まれるノードの全順序関係を、ログ情報に基づいて決定して可視化する方法、装置及びコンピュータプログラム
US8893074B2 (en) 2011-03-11 2014-11-18 Hewlett-Packard Development Company, L.P. Software development requirements recording
CN117311678B (zh) * 2023-08-04 2024-06-04 四川大学 用于ai系统的程序模块序化组接功能合成的等效嵌入方法

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002202883A (ja) * 2000-12-28 2002-07-19 Isd Kenkyusho:Kk ソフトウェアの実現(インプリメンテーション)方法及び処理生産装置

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO1997016784A1 (fr) * 1995-10-30 1997-05-09 Fumio Negoro Procede de production de logiciels, processeur et support d'enregistrement
US6532586B1 (en) * 1995-10-30 2003-03-11 Information System Development Institute Software producing method, processor, processing method and recording medium
KR20010041783A (ko) * 1998-03-20 2001-05-25 네고로 후미오 소프트웨어의 생성장치 및 소프트웨어의 생성방법
US6292938B1 (en) * 1998-12-02 2001-09-18 International Business Machines Corporation Retargeting optimized code by matching tree patterns in directed acyclic graphs
US7100164B1 (en) * 2000-01-06 2006-08-29 Synopsys, Inc. Method and apparatus for converting a concurrent control flow graph into a sequential control flow graph
US7299458B2 (en) * 2002-10-31 2007-11-20 Src Computers, Inc. System and method for converting control flow graph representations to control-dataflow graph representations

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002202883A (ja) * 2000-12-28 2002-07-19 Isd Kenkyusho:Kk ソフトウェアの実現(インプリメンテーション)方法及び処理生産装置

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
ARAI O AND FUJITA H: 'The Mathematical Structurre model of a Word-unitbased Program.' INTERNATIONAL CONFERENCE ON ADVANCES IN INFRASTRUCTURE FOR ELECTRONIC BUSINESS, SCIENCE, AND EDUCATION ON THE INTERNET, [Online] 2002, pages 1 - 7, XP002994351 Retrieved from the Internet: <URL:URL:http:// web.archive.org/web/20030605184900/www.ssgr r.it/en/ssgrr2002s/papers/154.pdf> [retrieved on 2005-06-09] *
ARAI O. ET AL: 'A Word-unit-based Program: Its Methematical Structure model a nd actual application.' NEW TRENDS IN SOFTWARE METHODOLOGIES, TOOLS AND TECHNIQUES. 2002, pages 63 - 74, XP002994350 *
'Lyee Update<<2003.1 Gatsu>>' THE INSTITUTE OF COMPUTER BASED SOFTWARE METHODOLOGY AND TECHNOLOGY., [Online] 03 January 2003, pages 1 - 10, XP002998319 Retrieved from the Internet: <URL:URL:http://www.lyee.co.jp/jp/lyeeupdat e/docs/vol004lyeeupdate.PDF> *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007018295A1 (ja) * 2005-08-05 2007-02-15 Catena Corporation プログラム実行順序決定装置および方法
JP2014081934A (ja) * 2012-10-12 2014-05-08 Boeing Co データ依存型制約管理システムにおける計算計画のためのシステムおよび方法
US10339458B2 (en) 2012-10-12 2019-07-02 The Boeing Company System and method for rapid and robust uncertainty management during multidisciplinary analysis
US10339459B2 (en) 2012-10-12 2019-07-02 The Boeing Company System and method for rapid and robust uncertainty management during multidisciplinary analysis

Also Published As

Publication number Publication date
JP2005115498A (ja) 2005-04-28
JPWO2005043271A1 (ja) 2007-05-10
US20070169006A1 (en) 2007-07-19
WO2005043271A3 (ja) 2005-09-01

Similar Documents

Publication Publication Date Title
CN108319456B (zh) 一种免编程深度学习应用的开发方法
Giaglis A taxonomy of business process modeling and information systems modeling techniques
Dávid et al. Foundations for streaming model transformations by complex event processing
Saeki Embedding metrics into information systems development methods: An application of method engineering technique
CA3153937A1 (en) Visually creating and monitoring machine learning models
US20070169006A1 (en) Software generation method
Han et al. FAME: A UML-based framework for modeling fuzzy self-adaptive software
Johansson Lemma discovery for induction: a survey
Hassan et al. A framework of software project scope definition elements: An ISM-DEMATEL approach
Sause et al. Object-oriented approaches for integrated engineering design systems
JPH04227544A (ja) 複雑な情報交換システムを通じるデータ流れの分析方法及び装置
Delen et al. Towards a truly integrated enterprise modeling and analysis environment
JP2801931B2 (ja) 論理設計処理装置および回路変換ルール翻訳装置ならびに回路変換ルール翻訳方法
Lerchner et al. An open S-BPM runtime environment based on abstract state machines
Lee et al. Scheduling analysis of FMS: An unfolding timed Petri nets approach
Fan et al. Dual workflow nets: Mixed control/data-flow representation for workflow modeling and verification
Siriweera et al. Constraint-driven complexity-aware data science workflow for AutoBDA
JPWO2004068342A1 (ja) ソフトウェア開発前処理方法、ソフトウェア制御方法、ソフトウェア開発方法並びにソフトウェア開発装置
Schruben Building reusable simulators using hierarchical event graphs
Peña-Mora et al. Design rationale and design patterns in reusable software design
Broll et al. Deepforge: An open source, collaborative environment for reproducible deep learning
Spanoudakis et al. The agent systems methodology (aseme): A preliminary report
WO2006038303A1 (ja) ソフトウェア生成方法
Arena Towards semantics-driven modelling and simulation of context-aware manufacturing systems
Sciavicco et al. Mining CSTNUDs significant for a set of traces is polynomial

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A2

Designated state(s): AE AG AL AM AT AU AZ BA BB BG BR BW BY BZ CA CH CN CO CR CU CZ DE DK DM DZ EC EE EG ES FI GB GD GE GH GM HR HU ID IL IN IS JP KE KG KP KR KZ LC LK LR LS LT LU LV MA MD MG MK MN MW MX MZ NA NI NO NZ OM PG PH PL PT RO RU SC SD SE SG SK SL SY TJ TM TN TR TT TZ UA UG US UZ VC VN YU ZA ZM ZW

AL Designated countries for regional patents

Kind code of ref document: A2

Designated state(s): BW GH GM KE LS MW MZ NA SD SL SZ TZ UG ZM ZW AM AZ BY KG KZ MD RU TJ TM AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HU IE IT LU MC NL PL PT RO SE SI SK TR BF BJ CF CG CI CM GA GN GQ GW ML MR NE SN TD TG

121 Ep: the epo has been informed by wipo that ep was designated in this application
WWE Wipo information: entry into national phase

Ref document number: 2005515082

Country of ref document: JP

122 Ep: pct application non-entry in european phase
WWP Wipo information: published in national office

Ref document number: 10574703

Country of ref document: US