Nash - Scientific Computing with PCs, страница 14

PDF-файл Nash - Scientific Computing with PCs, страница 14 Численные методы (763): Книга - 6 семестрNash - Scientific Computing with PCs: Численные методы - PDF, страница 14 (763) - СтудИзба2013-09-15СтудИзба

Описание файла

PDF-файл из архива "Nash - Scientific Computing with PCs", который расположен в категории "". Всё это находится в предмете "численные методы" из 6 семестр, которые можно найти в файловом архиве . Не смотря на прямую связь этого архива с , его также можно найти и в других разделах. .

Просмотр PDF-файла онлайн

Текст 14 страницы из PDF

To this end,we use our own small program (Pdate.pas) that displays the date and time in a format we findconvenient. That is, we like to see:Current date & time: 1991/7/216:46:30.36Note that the date and time follow the ISO forms yyyy/mm/dd and hh:mm:ss.xx where xx is inhundredths of seconds. The clock in many computers is not capable of 1/100 second precision, butconversion of the fractions of a second to this form is convenient.We often use redirection to put a time stamp on diskettes. For example, we can use the command5: FILE MANAGEMENT35pdate >A:timedate.dskto put the current date and time line above into a file called TIMEDATE.DSK on the diskette in drive A.Few computers have operating systems with integrated file management, where the catalog iscontinuously on line and dynamically updated.

(The only one we have used was the GEORGE 4 operatingsystem of the ICL 1906A computer in the early 1970s.) This reflects not only a limit on the physicalresources - the size of the catalog of files may be too large to be kept continuously available ("on-line")— but also the organizational difficulty of registering changes to volumes that are not attached to thesystem. Users may take disks to other machines and add, delete or modify files there. How can we controlor monitor such activity?Operating systems do, however, provide the user with the capability to list the contents of a singledirectory on individual storage volumes (disks). How, then, can a consolidated catalog of a number ofdisks be made? Clearly, each filename must first be associated with the volume (we will use disk andvolume interchangeably) on which the file resides, so disks must each be given a unique name or number.We may also want to note the subdirectory in which a file is found.Thus the contents of each disk must be read, directory names extracted, filenames extracted and linkedto directory names to make a full filename, and the unique disk identifier attached to each full filename.This list of extended filenames must then be sorted and displayed, with the short filename being the mostlikely sort key.This task may present the user with several obstacles.

First, the individual disks or tapes may have nounique identifiers if users omit to label disks or else supply non-unique names. Second, there may be noeasy-to-use mechanism that allows the directory of an individual disk to be read as data by a programsuch as a cataloguing utility. In our own work we have made use of the operating system DIR insidebatch command files rather than develop hand assembled machine code calls within programs. Once thedata has been collected, the filename sorting and display must be done carefully so that duplicate namesare easily recognizable.To complicate matters, a single computer may be operated under several operating systems, each of whichuses different conventions for storing the catalog directory of a disk.

For example, both IBM PC class andApple Macintosh family machines can be operated under variants of the UNIX operating system as wellas their own flavors of system software. If we are running two different operating systems, we are forcedto fragment our catalog.

Unless there are very strong reasons for running more than one operating system,we recommend that only compatible operating systems and compatible versions be used within a singlegroup of machines.Our mention of versions raises "within family" differences. On the Macintosh, the System 7 FINDER onthe Macintosh is different from previous versions.

On IBM PCs, there are both generic (MS-DOS) andproprietary (e.g., PC-DOS, Compaq DOS) variants, and these all have a variety of versions.We have felt strongly enough about catalogs to have developed two cataloging utilities, one for North StarDOS (Anderson and Nash, 1982) and one for MS-DOS machines (Nash J C and Nash M M, 1989).Programs that purport to do similar tasks exist in collections of shareware, but we have not seen anymajor commercial catalog program.We note that a major reason for listing all files (with attributes such as length and time stamp) is that wewish to eliminate duplicate files where possible.

Special programs exist that are designed to help in thistask, but the catalog is a good starting point, since duplication may occur in the name rather than the filecontents. Only the user can decide what files are to be eliminated and what ones kept. In some case wemay need to run file comparisons to decide where the differences lie.

We note that saving a file to thewrong directory is a frequent cause of multiple versions of a single file.Catalogs of files take time to build, especially if we include all the removable volumes that accompany36Copyright © 1984, 1994 J C & M M NashNash Information Services Inc., 1975 Bel Air Drive, Ottawa, ON K2C 0X1 CanadaSCIENTIFIC COMPUTING WITH PCsCopy for:Dr. Dobb’s Journala computer or group of computers. In our own work we have found our use of catalogs decreasing withthe linking of our machines into a network, since this simplifies our storage of files.

One and only onemachine is used to hold each group of files, for example, the material for this book lives on a machineidentified as JOHN on a particular fixed disk drive and in a special directory. All faxes live on a machinecalled FAX.5.4BackupWe try to maintain two backup diskettes for each directory containing our own files. About four timesa year we do a complete backup to tape to preserve the files and associated directory structure.

This isa form of insurance against accidental loss of the information we are likely to want to use again. Somecauses of loss of information are discussed in Section 5.7. Unfortunately, the fear of information loss leadsmany PC users to make too many copies of the same material. (We are culprits too!) During programdevelopment, one may save trial versions of programs, thus keeping several similar, but not identical,program files. Data files, too, may exist in multiple versions, for example, the manuscript of this book asit is being revised and edited. Later we consider version control methods.

Here we concentrate purely onbackup.The first requirement for the security of copies of files is that they be somehow physically distinct. Forfloppy disks, this means two disks. For fixed disks, copies may be made to a sequence of removable disksor tapes. It should be noted that many PC systems have a single physical fixed disk that is partitionedinto more than one logical disk for organizational convenience. We do this ourselves to let part of ourdata to be write-protected.Once a file exists on two separate physical objects, we need to think where we are going to keep them.For safety against fire, flood and other perils, the two copies should be in different locations, possibly inspecial containers to protect them against shock, dirt, moisture, heat or stray electromagnetic radiation.Of course, when updates are to be made, we may have a long walk to fetch the disk or tape for revision.In our own work, we usually accept the risk of storing short term backup files in our office.

Originalcopies of our operating and commercial software or data are kept in a relatively inaccessible "master set"of disks out of normal reach. Disks in the "master set" generally have the write-protection mechanismengaged. For files that would be difficult to replicate from other sources of information, we keep a copyin our "security set" in another office at a different location.Some readers may be unfamiliar with the write-protection that exists for practically all magnetic recordingmedia. This is a physical mechanism to prevent writing, though reading is still allowed.

For example, oncassette tapes there are small square tabs that may be broken off to prevent recording. On half-inch tapea write-permit ring must be inserted in a groove in the reel. 5.25 inch floppy disks use a notch that iscovered to write-protect the disk. 3.5 inch disks are protected by opening a slider on a small squarewindow.Carrying out the backup is the most dangerous step, because it may involve having both primary andbackup media (disks, tapes, etc.) in the machine simultaneously. For example, a power failure while bothvolumes are being accessed could cause physical damage to both. There are ways of organizing thebackup to minimize such risks, but at the cost of more complexity for the user.Backup should, where appropriate, be built into programs.

It is easy to add a small amount of code tomost programs that presents the user with a series of instructions to make a backup copy of data files.An example dialog might be:Machine: DO YOU WANT A BACKUP OF YOUR DATA (Y OR N)?User: YMachine: TAKE YOUR DATA DISK OUT OF DRIVE 1, PUT IN BACKUP DISK. ARE YOU READY?User: Y5: FILE MANAGEMENT37Machine: COPY MADESome programs always make a backup copy of a file. This can be a nuisance and fill disk spaceunnecessarily.

Свежие статьи
Популярно сейчас
Почему делать на заказ в разы дороже, чем купить готовую учебную работу на СтудИзбе? Наши учебные работы продаются каждый год, тогда как большинство заказов выполняются с нуля. Найдите подходящий учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
5304
Авторов
на СтудИзбе
416
Средний доход
с одного платного файла
Обучение Подробнее