In the past years of soft examination in the afternoon, there are five big questions, respectively, is the design of data flow chart, database design, UML diagram, algorithm and design patterns, starting from today's blog, small series with you to study the afternoon of soft exam related content, including theoretical knowledge and typical examples of the explanation, Hope to give the necessary small partners strong help, prepare for soft test, we can do better, today's small series of the main simple summary of the relevant knowledge of the flow chart, first of all, we look at the following picture:
Then, the small series will follow the mind map of the context, in turn, the soft examinations of the flow chart to explain in detail, there are different views of the small partners welcome to discuss exchanges, first of all, we look at the first basic knowledge points:
basic symbols for streaming diagrams
The data flow DIAGRAM,DFD is a graphical tool for describing data processing, and she describes the transformation process of the flow and processing in the system flow in a graphical way from the point of view of transmission and processing. 。 It reflects the flow of data and the logical process of nature and the necessary logical data storage. Let's take a look at the following table, in the data flow diagram, there are mainly the following symbols:
As we have shown, in the flow chart, usually using four basic flow diagram symbols, in any one of the flow diagram, must contain four basic symbols, indispensable. The first symbolic circle represents the process of processing, in the circle, indicating the name and number of the processing. The second symbol arrow: The name of the above-written data stream, then the same data flow after processing, there may be different processing results, for example, the daily life of flour, after processing, may be processed into steamed bread, may be flour, mainly processing of the function of the data flow has been processed, there is flow into the outflow, On the same data flow chart, there can be no traffic with the same name, if there are more than two data streams pointing to a processing. or a processing, output two data streams, then these data streams, there are often some relationship, the relationship is as follows:
The third kind of symbol: Data storage file: Generally with double horizontal line to represent, but about the data store file representation in a variety of different textbooks on the method of expression, for example, a useful double horizontal line, there is a half-frame, the arrow means to deposit in or take out, indicating the process of reading and writing, Generally write the file name in the middle, the role of the data store file is to save data, can be a database file, or another form of data organization, so her flow can be understood as query files. An outward arrow can be understood to get the desired result.
The fourth symbol: a data source point or sink point, which represents the source of input to the data flow diagram that needs to be processed. In the flow chart, just as a symbol, do not need any software in the way of design and implementation. She is an entity in the outer part of the system, so it is called an external entity. In general, this data source point or meeting point appears only in the top-level diagram of the streaming graph. After learning the basic symbols of the streaming diagram, let's look at the design principles of the streaming diagram:
design principles for streaming diagrams
The design principle of the flow chart in the following typical example, the small part in the short description of how these principles are used flexibly in our examples.
Data Dictionary
Data dictionary refers to the data items, data structure, data flow, data storage, processing logic, external entities and other definitions and descriptions, the purpose is to make a detailed description of the various elements of the data flow diagram. Data dictionary is a directory where users can access the records database and the application's original data. An active data dictionary is a data dictionary whose contents can be automatically updated by the DBMS when modifications are made to the database or application structure. A passive data dictionary is a data dictionary whose contents must be updated manually when modified. Let's take a look at the following picture:
After introduction of the basic theoretical knowledge of the flow chart, we began to combat, in the small part of the simple two examples to consolidate the previous theoretical knowledge, first of all, we look at a January 04 real problem, although the title of 04 has been a certain year, but the soft test of the title is the old, So mastered the basic problem-solving methods and techniques, let him ever-changing, I self-fluent, good, small make up, the topic is as follows:
Typical examples:
The data flow chart is as follows:
The problem is as follows:
Get the topic, we need to seriously read a few times, because this topic test is not difficult, the key is careful, sometimes, the topic of the sentence may be the answer we need, first of all, we look at the first question, the topic said that the data Flow diagram 2 has two streams is wrong, please point out the two data flow end point and the starting point Let us analyze, the top level diagram of the four input management work request, query request information, reader information, the current date in the 0-layer chart is reflected in the next, we look at the output, the output of information has the book situation, the reader situation and illegal request information, in the 0 layers of the map, the book situation and the reader is reflected, But careful observation we will find in the top layer of the output of the illegal request information, in the 0-layer diagram There are two of the illegal management of work requests and illegal query request information, but so we can not determine that this is wrong, the occurrence of such a situation may be in the top-level diagram of an output stream is decomposed in the 0-layer diagram. Let's put it on for a moment. Then we look at the reader file, processing the query request is to write to the reader file a process, register the reader information is to write to the reader file or to say is to take information. We first look at the processing of query requests, from the previous event description, we can see that the processing of query requests including query book situation and reader situation, the output of the results are not wrong, and with the top-level diagram is also the corresponding, in the query process, according to the user's query request information, suppose to check the System analyst continued guide information, Then you will enter the system analyst continue guide, and then output, is the System analyst continued guide the situation of the book, author, Price, publishing house and so on, then where to check it, so there is no input, so for the reader file, she borrowed some information should be from the opposite direction as input, After receiving the query information, from the reader file to take the relevant records to query, the same situation, the third processing, register the reader information, the input is the reader information, no output, illegal data conservation rules, there will be input output. There is input, after processing should have output, that output what nie? Here is the reader information, the function of processing is to register the reader information, where to register, should be registered to the reader file, so it should also be in the opposite direction, as follows:
So the answer to the first question is from 2 to the reader file, from the reader file to 3, which examines the balance principle of the sub-graph and the parent graph. Let's proceed to the second question, as follows:
The third data flow diagram is a refinement of the second processing of the 0-layer graph, the second processing refinement into the reader information query and book information query, then to find out the lack of traffic, we first use the parent and sub-graph balance principle. Let's look at the data flow for the 1-layer and 1-layer graphs.
First look at the input: Query request information, reader file input, output three: book situation, reader situation, illegal query reader request information. The missing should be the internal data flow situation, because the query request information includes two, one is to query the reader request information, the other is to query the book request information, also divided into two, so the data flow with the parent graph is balanced, but the problem is less three, less the three NIE? According to the principle of the balance of the sub-graph and the parent graph, the missing must be between 2.1 and 2.2, or between 2.1 and 2.2 and the file.
So here, we need to follow the description of the question to find the corresponding answer, the question description: The system's information query function mainly includes the reader information query and book information query, in which the reader information query can get the reader's basic information and readers borrow books, Book information query can get basic information and book loan, according to the question description, we are easy to see, the information about the reader, should be used to borrow the document, because it is necessary to borrow books in the case, borrowing the relevant information in the library files, so this needs to query the reader information, Not only to have the reader file also need to borrow a document, so to add an end file to the reader information query of a data flow, the same situation, but also to add a library from the book file to the library information query data flow, book information query out the basic situation of books, but also should include the book lending situation, So she is also in the library file, at the same time, to see the book lending situation, so also from the book catalog files to the library information query data flow, because to query the basic situation of books, the basic situation of books in the book catalog files, so according to the test description to find the missing data stream. Can be determined according to the balance principle of the sub-graph and the parent graph, as well as the description of the question. Next, let's look at the third question, as follows:
The brackets indicate repetition, and the management work consists of four aspects: buying new books, readers borrowing books, readers returning books, book cancellation. When you buy a new book, you need to prepare an inventory for the book. Readers need to fill out a library card when borrowing books. Readers need to fill out the return form when they return the book. You need to fill out the cancellation form when you cancel the book. So her management work request list includes four kinds of situations: Warehousing list, borrowing list, return list, write-off of the four kinds, because four kinds is optional, according to the data flow chart inside the description of the structure, we should use the brackets, the middle with a vertical line to separate. We will look at the storage list: We look at the question description, the contents of the inventory list including the book catalog number, title, author, price, quantity and offerings date, this is not very clear NIE.
Small Series of words: This blog, small series mainly aimed at the soft examinations of the afternoon data flow chart to explain, the main explanation of four aspects of the basic content, the basic symbol of the data flow diagram, the design principles of the flow chart, the dictionary, and then listed a simple example, the previous theoretical knowledge to consolidate, Although the title of the 04 is a bit of a year, but the subject of the soft test is the old, so mastered the basic problem-solving methods and techniques, let him ever-changing, I fluent, for the data flow diagram of such types of questions, the key is careful, from a lot of text description, eyes see we need to answer information, General problem-solving time will use the balance principle of the sub-chart and the parent graph has the principle of data balance, master the skills of understanding the problem, the flow chart is to send points of the problem, believe that their own, certainly no problem. because of the last small series of the mentality of learning, think this time, but the next time, and then God really made a small, it doesn't matter, small series will be more and more brave, once again embrace soft test of small, small series will give small make up their own wonders, let us wait and see, small series to everyone bring wonderful.
Design of---Flow chart in the afternoon of soft examination