流程圖的製做

 

一、系統流程製作的意義

通常在進行系統開發時,必須在可能情況下,盡力去計畫出每個可能遭遇的狀況    和動作,而描述系統流程常用的方式就是「流程圖」(flowchart)。

   「流程圖」就如名字所示,是描述「系統進行流程」的一種圖表。他不僅描寫了系統    由頭至尾的順序,更應盡可能的敘述所有可能的狀況。

   流程圖可促進程式發展。但是,詳細而明確的流程圖是很難做到的,因此,建議發展 流程圖時,可將流程圖發展步驟分成三大部分:(Alessi & Trollip, 1991)

   1. 第一層流程圖(Level-1 Flowchart):通常少於一頁,對於系統的流程和方法,做一個概略的描述。

   2. 第二層流程圖(Level-2 Flowchart):以『第一層流程圖』為依據,加上必要的決策和分支點。

   3. 第三層流程圖(Level-3 Flowchart):以『第二層流程圖』為基礎,再加上說明、計算、條件判斷、資料處理和使用者輸出入控制等。

 

並不是所有系統,都必須達到「第三層流程圖」,使用的時機完全取決於系統的複雜程度。

 在流程圖中,所有的程式邏輯步驟必須用圖表或文字的方式來表達,標準的流程圖符號在西元1960年時,由ANSI(American National Standard Institute) 所公佈,這些標準的圖示仍沿用至今。以下所列舉的是常用的流程圖符號和所代表的意義。   

 

. Flowchart Symbols

There are five basic symbols used to draw program flowcharts. Each corresponds to one of the basic functions of a computer. The symbols represent instructions.

 

1. Termination or beginning symbol: denotes the beginning or end of the program.

流程圖: 替選處理程序: Start
 

 

 

 

 

 


This symbol identifies the starting point in the flowchart.

 

流程圖: 替選處理程序: End
 

 

 

 

 


This symbol denotes the end of processing.

 

 

2. The Processing Symbol: Displays the calculations to be performed.

 

 

 

 

 

 

 


A rectangle is used whenever calculations or computations are to be performed. Replacements statements are used in the processing block to express the computations. A single variable must always be placed on the left hand side of the equal side of the equal sign; this is the memory location into which the value of the expression is stored. Thus 3*X+2 is not a replacement statement since no location is designed to store the result. The statement 3.1=X is invalid since 3.1 is a constant; the left hand side of the equal side of the equal sign must be a variable and not a constant. However, the statement X=3 is a valid way of assigning the value 3 to the variable X. All variables used in an expression must have been previously defined before the expression can be evaluated, otherwise, the results of a statement such as Z=2*X+Y. The equal sign used in a replacement statement must be understood as a replacement sign rather than a mathematical equality. Consider the statement X=X+2. Algebraically there are no values that satisfy this equality. Yet understood as a replacement statement, this statement is quite meaningful. If the value of X is 10 before the statement X=X+2 is processed, the value of X after processing will be 12 since X+2 = 10+2 = 12. The value of the expression replaces whatever value was contained in X previously.

 

3. The Input / Output Block:

 

 

 

 

 

 


The general form of the input/output symbol is the parallelogram. The commands READ, WRITE, INPUT, PRINT, etc., are used in the input/output symbol. Represents an I / O function, which makes data available for processing (input) or for displaying (output) of processed information.

 

 

4. The Decision Block:

 

 

 

 

 

 


Decision symbols provide a means for conditioning branching, i.e., transferring to different blocks depending on certain conditions.

Conditional branches allow for bypassing of certain blocks in the flowchart. In this way a flowchart can exhibit several alternate paths, which may be taken depending on whether or not certain conditions are met. All decisions must ultimately be made in terms of a comparison

between two variables or expressions.

 

 

5. Connector Blocks:

 

 

 

 

 

 


The flowchart above is simple so that all connecting flow lines could be drawn without crossing each other or without being too difficult to follow. To avoid confusion in more complex flowcharts, the connector block is used. The symbol within the connector serves two purposes: (1) to identify a block by a label for future reference, and (2) to indicate the target for a transfer. A transfer is indicated when the flow line points toward the connector block as in the following picture. The point to which transfer is made (an entry point) is indicated by the flow line pointing away from the connector as in the following picture.

流程圖: 接點: A流程圖: 接點: A.

 

 

 

 

 


If a transfer is made to another page of a multi-page flowchart, the         symbol (called an off page connector) may be used to mark transfer and entry points. Any number of transfers may be made to a single entry point; however, each entry point must be uniquely defined.

 

 

三、系統流程製作的方法

      系統流程製作所採用的方法,可由所採用的程式語言、編輯系統和所擁有的資源與工具等因素來決定。另外,也包括了你所能掌握的時間、人力、費用等客觀條件。詳細的編製流程和步驟,如下面敘述:

程序一(Level-1 Flowchart):採用簡單而明瞭的方式來描述一個程序的進行,沒有任何分岐或決策的點,它能讓大部份的人一目了然,無須加上任何細節 。

 

程序二(Level-2 Flowchart):當Level-1流程圖完成之後,若條件上許可的話,下一步就要進行Level-2流程圖之編製。原則上將Level-1流程圖之處理程序(長方形符號),加上說明、解釋和安排。原則上應包括「主要分支」和「主要流程」。

 

程序三(Level-3 Flowchart):對於一般簡單的系統而言,是不需採用到Level-3流程圖的,但是,若程式研發人員採用傳統程式語言來發展的話,那麼Level-3流程圖可能就是必要的了。因為程式設計師必須對系統全部的架構有所瞭解。若採用的是別人已經開發好的元件,Level-3流程圖就不是那麼必要了。

 

 

四、系統流程製作的工具

   (一)人工方式

    利用「流程圖尺」來編製流程圖,但完成之後若要修改的話,可要大費周章了。

   (二)電腦化工具

1. Shapeware公司的VISIO是一套多功能的流程圖編製軟體,操作十分簡便。

2. MicroGrafx公司的ABC Flow Charter此為Windows下一套整合軟體,結合了ABC Flow Charter、ABC Data Analyzer、ABC Snap Graphic三套軟體,是全功能的流程繪製工具,它還支援了Visual Basic的設計,和連接Excel與Word物件的功能。

3. ShapewNovaGraph公司的Chartist軟體,此為一共享軟體(Shareware),雖是共享軟體,但麻雀雖小,卻五臟俱全。

4. Advanced Technology Group公司的Super FLow,能夠在短時間內完成一流程圖。

 

 

. 參考資料

    Alessi S. M. & Trollip S. R.﹙1991﹚, Computer-Based Instruction, New Jersey, Prentice-hall, Inc.