Студопедия

КАТЕГОРИИ:


Архитектура-(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)

High level programming languages fortran




UNIT XVII

Ask the questions on the text. Make up the dialogue to the text.

1. Translate the following words, pronounce them correctly:

correspond array reference

several precede whole

notation label range

familiar enable imaginary

orient modular true

item extensive false

general-purpose subset default

feature unspecified emphasis

valid volume framework

facility sensitive neglect

peculiarity

2. Memorize the following word-combinations:

master segment главный сегмент

alphanumeric names буквенно-цифровые имена

data items элементы данных

floating-point representation представление с плавающей

точкой (запятой)

imaginary parts мнимая часть (в комплексном

числе)

truth values истинные значения

executable statements исполнительные операторы

assign(ment) statements операторы присвоения

dummy variables фиктивные переменные

to meet the needs (requirements) отвечать требованиям

default feature признак “по умолчанию”

valid interpretation обоснования интерпретация

3. Read and translate the text:

A high level language is a language in which each instruction or statement correspond to several machine code instructions. It is contrasted with a low level language in which each instruction has a single corresponding machine code equivalent. High level languages allow users to write in a notation with which they are familiar, e.g., FORTRAN in mathematical notation, COBOL in English. So, high level languages are oriented to the problem, while low level languages are oriented to the machine code of a computer.

FORTRAN. FORTRAN is an acronym for FORmula TRANslation. It is a problem oriented high level programming language for scientific and mathematical use, in which the source program is written using a combination of algebraic formulae and English statements of a standard but readable form. FORTRAN was the first high level programming language. It was developed in 1954, and was designed to easily express mathematical formulas for computer processing. It is still the most widely used programming language. There were several versions of FORTRAN. The most popular and used was FORTRAN-4.

A FORTRAN program consists of data items, executable statements and non-executable statements. The program is structured in segments which consist of a master segment and optional function segments and subroutines.

Data items in FORTRAN are either variables or constants, and are assigned alphanumeric names by the programmer. Group of similar items of data can be processed as arrays, or tables of data, in which case the individual items are defined by one or more subscripts.

Data items in FORTRAN may take the following forms:

Integer is a whole number value falling within a range determined by the capacity of the computer being used.

Real is a number expressed in floating-point representation accurate to a number of significant digits, the range again depends on the capabilities of the particular machine being used.

Complex is a number in which two real numbers are used to express the real and imaginary parts.

Logical is a quantity which can only take two values, true or false. Text is character information, which is not used for mathematical operations.

The actual operations of the program are expressed by means of ‘executable statements’. These can take two forms: ‘assignment statement’ and ‘control statements’. An assigned statement takes the form Variable = Expression. The expression may be either arithmetic or logical. An arithmetic expression can include variables, elements, form arrays, constants and a variety of standard functions which are combined by arithmetic operations, e.g., +, -, * (multiplication), / (division), ** (exponentiation). A logical expression is similar but include the operations AND, NOT, OR, etc, and the logical operators.

An example of an arithmetic assignment statement would be:

ROOT = (-B +SQRT (B**2 - 4*A*C0))/(2*A),

where the word ROOT and the letters A, B, C represent variables and SQRT – the function provided for calculating square roots. The compiler recognizes these symbols and translates them into appropriate machine code. An example of a logical assignment statement would be: BOOL-A.OR.B. In this expression the variable BOOL would be given the value true or false according to the truth values of variables A and B, and the truth table defined by the Boolean operator OR.

Each statement can be preceded by a numerical label, permitting reference to the statement by means of control statements. Control statements enable the program to branch to other statements. Branches themselves may also be constructed which are conditional on results of arithmetic or logical operations.

As was said above, a FORTRAN program consists of one or more segments, of which there is one and only one master segment, and optionally function and subroutine segments. A function segment is used where the same form of function is required several times in a program. The statements describing the operation required to calculate the result of using the function are named and written once, and whenever the function is required in the program it is only necessary to give the function name and a list of parameters to replace the ’dummy’ variables used in the function segment.

4. Answer the following questions:

1. What is FORTRAN?

2. What are low lever languages oriented to?

3. What are high level languages oriented to?

4. When was FORTRAN developed?

5. What does a FORTRAN program consist of?

6. Who assigns alphanumeric names to data items?

7. Which forms may data items in FORTRAN take?

8. By means of what are the actual operations expressed in FORTRAN?

9. How is a program in FORTRAN structured?

10. What do segments in a FORTRAN program consist of?




Поделиться с друзьями:


Дата добавления: 2014-12-27; Просмотров: 1090; Нарушение авторских прав?; Мы поможем в написании вашей работы!


Нам важно ваше мнение! Был ли полезен опубликованный материал? Да | Нет



studopedia.su - Студопедия (2013 - 2024) год. Все материалы представленные на сайте исключительно с целью ознакомления читателями и не преследуют коммерческих целей или нарушение авторских прав! Последнее добавление




Генерация страницы за: 0.009 сек.