КАТЕГОРИИ: Архитектура-(3434)Астрономия-(809)Биология-(7483)Биотехнологии-(1457)Военное дело-(14632)Высокие технологии-(1363)География-(913)Геология-(1438)Государство-(451)Демография-(1065)Дом-(47672)Журналистика и СМИ-(912)Изобретательство-(14524)Иностранные языки-(4268)Информатика-(17799)Искусство-(1338)История-(13644)Компьютеры-(11121)Косметика-(55)Кулинария-(373)Культура-(8427)Лингвистика-(374)Литература-(1642)Маркетинг-(23702)Математика-(16968)Машиностроение-(1700)Медицина-(12668)Менеджмент-(24684)Механика-(15423)Науковедение-(506)Образование-(11852)Охрана труда-(3308)Педагогика-(5571)Полиграфия-(1312)Политика-(7869)Право-(5454)Приборостроение-(1369)Программирование-(2801)Производство-(97182)Промышленность-(8706)Психология-(18388)Религия-(3217)Связь-(10668)Сельское хозяйство-(299)Социология-(6455)Спорт-(42831)Строительство-(4793)Торговля-(5050)Транспорт-(2929)Туризм-(1568)Физика-(3942)Философия-(17015)Финансы-(26596)Химия-(22929)Экология-(12095)Экономика-(9961)Электроника-(8441)Электротехника-(4623)Энергетика-(12629)Юриспруденция-(1492)Ядерная техника-(1748) |
Program design
Program design is the means by which proper program structure is achieved. It is the technique for going from the initial statement of the requirements of a program, which is generally vague, incomplete and contradictory, to the final structured, tested and approved code. It is a long and difficult process, made more so by the lack of widely-accepted, tested techniques of program design. However, a number of methods of program design do exist, and their use is increasing all the time. In the foreseeable future, it is likely that all software development will be based on а formal technique of program design. The simplest and one of the most popular methods of program design is stepwise refinement. It is based on the use of algorithms, which are written in a language somewhere between English and a programming language such as Pascal. The process itself may be described by an algorithm of this nature: State the overall steps of a program in a brief, top-level algorithm. Repeat Expand each statement of the algorithm as a detailed algorithm which describes the steps required to implement the statement. Until the task has been specified in sufficient detail for the code of the program to be written. Stepwise refinement is a top-down process, with details being added in an orderly fashion as the design progresses. If an algorithm turns out to be incorrect, it can be 'unplugged' and replaced by another without too much effect on the program structure as a whole. Although stepwise refinement can bring about a great improvement in the structure of a program, it is not formal enough for many applications. In particular, there is no guarantee that data structures are left in a consistent state by the various modules. lt is very difficult to prove the correctness of program module developed in this way. A number of more formal methods of program design are coming into use, the most popular being functional decomposition. Like stepwise refinement, functional decomposition is a top-down method, starting with the overall requirements of a program, and adding detail in an orderly way. The difference is that at every stage, the essential properties of the data structures are specified, and each algorithm is expressed as a mathematical function which transforms these data structures. Each algorithm can be tested by various mathematical techniques, in order to prove that the properties of the data structures are not altered by the operations it performs on the data. Functional decomposition is particularly suited to some of the new functional programming languages which are being developed for fifth generation computers.
Дата добавления: 2014-12-24; Просмотров: 505; Нарушение авторских прав?; Мы поможем в написании вашей работы! Нам важно ваше мнение! Был ли полезен опубликованный материал? Да | Нет |