Студопедия Главная Случайная страница Обратная связь

Разделы: Автомобили Астрономия Биология География Дом и сад Другие языки Другое Информатика История Культура Литература Логика Математика Медицина Металлургия Механика Образование Охрана труда Педагогика Политика Право Психология Религия Риторика Социология Спорт Строительство Технология Туризм Физика Философия Финансы Химия Черчение Экология Экономика Электроника

Programming. Multiprogramming





The following items are included in the programming: a) Consideration of the problem. Is the problem completely defined? Can we find a method of solution? Will the method fit the computer we use? Will we have enough time, both to prepare the solution on the computer and to run out the answers? b) Analysis of the problem. Does the algorithm that we can use exist? Are there "canned" routines that we can apply? That is, are there parts of this problem for which we may already have the computer solution? How much accuracy do we want? How well we assure ourselves that the solutions are correct? Can we construct test data to check the computer solution? Thus, programming covers all activities from the start of the job up to the end and including flowcharting.

Even in scientific computations, the most difficult part of programming is not the coding, or actual writing of the instructions for the computer, but the technical analysis of exactly what to be computed and how it is to be computed. To illustrate it, consider the case where a large problem involves, at some state, the solution of a quadratic equation. There are several methods of solving such an equation with the pencil and paper, but what method is preferable on the computer? Preferable in what sense – in the sense of fastest execution time for the calculation, inthe sense of fitting into the least possible amount of core storage; or perhaps in the sense of being easiest to code. The programmer must take these decisions. The programmer does not make all his decisions at once. He usually begins with an overall view of the entire system and the computer is considered as just another unit in the system. As he plans the system, he draws a system flowchart, a graphic and easily understood picture of what happens in the system. He then breaks each part of the system flowchart down into as much detail as needed, producing detailed flowcharts. For the computer processing he draws a special program flowchart, outlining, in general, the essential steps in the computer program. This is refined to produce detailed program flowcharts from which the coding begins. The coder, who may or may not be the same person who did the system analysis, translates each block of the flowchart into one or more instructions for the computer.

One reason for using an operating system is to increase throughout the amount of useful work the computer performs in a given time period. In many jobs, the computer spends most of its time waiting for the completion of input-output operations, particularly printing. If the computer has enough core storage and sufficient input-output devices, it allows for multiprogramming. Multiprogramming means that two or three different and unrelated programs are placed in storage, with each program having its own set of input-output files. The supervisor gives control to the highest priority program and it continues to be executed until it reaches a point where it can go no further until some pending input-output is completed. At this point, the supervisor saves the status of the program and transfers control to the next highest priority program. When input-output operation is completed, the supervisor halts program which was running and returns control to the first program. Processing continues inthis way with the computer entering to wait state only when all programs are waiting. Although the amount of time taken for the computer to complete any one program is increased, the total time for all programs will usually be reduced substantially.







Дата добавления: 2015-09-15; просмотров: 547. Нарушение авторских прав; Мы поможем в написании вашей работы!




Композиция из абстрактных геометрических фигур Данная композиция состоит из линий, штриховки, абстрактных геометрических форм...


Важнейшие способы обработки и анализа рядов динамики Не во всех случаях эмпирические данные рядов динамики позволяют определить тенденцию изменения явления во времени...


ТЕОРЕТИЧЕСКАЯ МЕХАНИКА Статика является частью теоретической механики, изучающей условия, при ко­торых тело находится под действием заданной системы сил...


Теория усилителей. Схема Основная масса современных аналоговых и аналого-цифровых электронных устройств выполняется на специализированных микросхемах...

Понятие и структура педагогической техники Педагогическая техника представляет собой важнейший инструмент педагогической технологии, поскольку обеспечивает учителю и воспитателю возможность добиться гармонии между содержанием профессиональной деятельности и ее внешним проявлением...

Репродуктивное здоровье, как составляющая часть здоровья человека и общества   Репродуктивное здоровье – это состояние полного физического, умственного и социального благополучия при отсутствии заболеваний репродуктивной системы на всех этапах жизни человека...

Случайной величины Плотностью распределения вероятностей непрерывной случайной величины Х называют функцию f(x) – первую производную от функции распределения F(x): Понятие плотность распределения вероятностей случайной величины Х для дискретной величины неприменима...

ТЕОРИЯ ЗАЩИТНЫХ МЕХАНИЗМОВ ЛИЧНОСТИ В современной психологической литературе встречаются различные термины, касающиеся феноменов защиты...

Этические проблемы проведения экспериментов на человеке и животных В настоящее время четко определены новые подходы и требования к биомедицинским исследованиям...

Классификация потерь населения в очагах поражения в военное время Ядерное, химическое и бактериологическое (биологическое) оружие является оружием массового поражения...

Studopedia.info - Студопедия - 2014-2025 год . (0.011 сек.) русская версия | украинская версия