ФЕДЕРАЛЬНОЕ АГЕНСТВО ПО ОБРАЗОВАНИЮ РФ Благовещенский государственный педагогический университет
Е.Л. Еремин, В.В. Еремина, М.С. Капитонова
МАТЕМАТИЧЕСКОЕ И КОМПЬЮТЕРНОЕ МОДЕЛИРОВАНИЕ Учебное пособие
Благовещенск 2005
УДК 658.5.011.56 ББК 22.181 В 641 Е70
Печатается по решению редакционно-издательского совета Благовещенского государственного педагогического университета
Еремин Е.Л., Еремина В.В., Капитонова М.С. Математическое и компьютерное моделирование. Благовещенск: Изд-во Благовещенского гос. пед. ун-та, 2005. Основу учебного пособия составляют теоретические, прикладные и методические разделы по математическому и имитационному моделированию динамических систем, ориентированные на выполнение лабораторных и курсовой работ в среде MATLAB – международном стандарте автоматизации математических расчетов. Для студентов, специализирующихся в области информатики и интересующихся вопросами моделирования динамических процессов и систем.
Рецензенты: Е.Ф. Алутина, канд. физ.-мат. наук, доцент, зав. кафедрой информатики БГПУ А.В. Бушманов, канд. техн. наук, доцент, зав. кафедрой информационных и управляющих систем АмГУ
© Благовещенский государственный педагогический университет, 2005 2
ОГЛАВЛЕНИЕ 1. Математические модели 1.1. Модели непрерывных систем 1.1.1. Линеаризация дифференциальных уравнений 1.1.2. Первая форма записи линеаризованных уравнений 1.1.3. Операционное исчисление и преобразование Лапласа 1.1.4. Вторая форма записи уравнений на основе W(s) 1.2. Характеристики непрерывных систем 1.2.1. Временные характеристики 1.2.2. Частотные характеристики
5 5 6 9 11 15 17 17 19
2. Модели в пространстве состояний 2.1. Состояние динамической системы 2.1.1. Вход, состояние выход 2.1.2. Пространство состояний 2.2. Описание систем в нормальной форме 2.2.1. Уравнение линейных систем в пространстве состояний 2.2.2. Способы пронраммирования в переменных состояния 2.2.3. Примеры уравнений состояния систем 2.2.4. Передаточные функции нормальных систем 2.2.5. Уравнения состояний при типовом соединении систем 2.3. Дискретизация непрерывных моделей 2.3.1. Решение уравнений состояния 2.3.2. Дискретные модели непрерывных систем 2.3.3. Вычисление матричной экспоненты 2.3.4. Вычисление матрицы Q 2.3.5. Вычисление передаточной функции дискретной модели 2.3.6. Устойчивость дискретных моделей
22 22 23 24 25 25 27 36 39 40 42 42 44 46 50 51 52
3. Модели и характеристики элементарных динамических звеньев 3.1. Группа позиционных звеньев 3.1.1. Безынерционное звено 3.1.2. Инерционное звено 1-го порядка 3.1.3. Инерционное звено 2-го порядка 3.1.4. Колебательное звено 3.2. Группа интегрирующих звеньев 3.2.1. Интегрирующее звено 3.2.2. Интегрирующее звено с замедлением 3.3. Группа дифференцирующих звеньев 3.3.1. Идеальное дифференцирующее звено 3.3.2. Реальное дифференцирующее звено
56 56 56 58 61 65 68 68 70 72 72 74
4. Пакет MATLAB 4.1. Рабочее место MATLAB® for Windows (версия 4.0) 4.2. Основные команды и параметры диалога MatLab 4.2.1. Раздел меню File 4.2.2. Раздел меню Edit 3
77 78 79 79 83
4.2.3. Раздел меню Options 4.2.4. Раздел меню Windows 4.2.5. Раздел меню Help 4.3. Тулбокс MatLab 4.4. Тулбокс Signal 4.5. Тулбокс KMM
83 85 85 86 87 89
5. Курсовая работа 5.1. Краткие методические указания 5.2. Задание 5.3. Примеры
90 90 90 99
6. Лабораторные работы 6.1. ЛБ №1. Знакомство с рабочим местом лабораторного комплекса 6.2. ЛБ №2. Имитационное моделирование позиционных звеньев 6.3. ЛБ №3. Имитационное моделирование интегрирующих звеньев 6.4. ЛБ №4. Имитационное моделирование реального дифзвена
101 101 103 108 109
7. Математическое и компьютерное моделирование процессов поляризации 7.1. Процесс упругой электронной поляризации диэлектриков 7.2. Длинноволновый спектр оптического показателя преломления воды 7.3. Оптический спектр воды в области упругих ионных поляризаций
111 111 118 127
Библиографический список
135
4
1. МАТЕМАТИЧЕСКИЕ МОДЕЛИ
Динамические системы разнообразны по своему назначению, принципу действия и конструктивному исполнению. Поведение систем может описываться обыкновенными дифференциальными уравнениями, дифференциальными уравнениями в частных производных, уравнениями в прямых или обратных разностях и т.д. Рассмотрим методику составления уравнений непрерывных динамических систем с сосредоточенными параметрами, динамика которых описывается обыкновенными дифференциальными уравнениями. 1.1. Модели непрерывных систем Большинство динамических систем – это совокупность взаимодействующих между собой подсистем (фрагментов) и отдельных элементов, определенным образом соединенных друг с другом. Начальным этапом при составлении дифференциальных уравнений является разделение (декомпозиция) системы на отдельные элементы и составление их дифференциальных уравнений. Математические модели элементов системы в виде дифференциальных уравнений и уравнений связей между ними описывают процессы в динамической системе, т.е. изменение во времени всех ее физических координат. Зная уравнения элементов и уравнения связей динамической системы, можно построить ее структурную схему. Структурная схема динамической системы отражает геометрию системы и характеризует как состав ее элементов, так и связи между ними. На структурной схеме системы указывают пути и направления передачи информации (сигналов). Состояние системы, а также входящих в нее элементов описывается определенным числом независимых координат, часть которых доступна измерению: например, для электрических систем – это ток, напряжение, мощность; для механических систем – угол поворота, перемещение, скорость и т.д. Для описания взаимодействия системы с внешней средой, а также подсистемы с другими подсистемами на входе и выходе выбирают соответствующие векторные координаты (входные и выходные). Будем пока полагать, что координаты, или переменные динамической системы – скалярные функции времени, пусть 5
входная величина g(t), а выходная z(t). 1.1.1. Линеаризация дифференциальных уравнений При составлении математического описания динамической системы основной задачей является получение дифференциальных уравнений ее отдельных элементов. На рис. 1 показан общий вид произвольного элемента динамической системы, на входе которого выделено два типа внешних воздействий, один из которых будем называть задающим воздействием g(t), а другой – возмущающим ϕ(t). Составление уравнений отдельных элементов системы опирается на те физические законы, которые характеризуют их природу и поведение. Рис. 1.1. Элемент Для технических систем – это законы динамической системы. механики, электротехники, гидравлики, теплотехники и т.п. Уравнения динамики каждого элемента и всей системы в целом являются дифференциальными, при составлении которых стремятся, с одной стороны, наиболее точно, полно и подробно описать поведение, а с другой, учитывая сложность таких уравнений, – найти компромисс между усложнением дифференциальных уравнений и упрощением исследования свойств системы при решении этих уравнений. Если в динамической системе возникает установившийся режим (стабилизация), то это ее состояние характеризуется зависимостью значений выходной величины от входной в виде так называемой статической характеристики. Эти характеристики могут быть получены из дифференциальных уравнений при t → ∞. Для примера рассмотрим дифференциальное уравнение элемента системы (см. рис. 1.1), динамику которого опишем выражением d 2 z (t ) dz (t ) dϕ (t ) , , ( ), ( ) φ , ϕ ( ) (1.1) F z t g t = t , 2 dt dt dt где F(.), φ(.) – некоторые функции переменных g(t), z(t) и ϕ(t), а также производных от z(t) и ϕ(t). В этом случае статическая характеристика (здесь в неявном виде) будет описываться уравнением
F (0, 0, z0 , g 0 ) = φ (0, ϕ 0 ),
(1.2) 6
где z0, g0, ϕ0 = const. Если функции F(.), φ(.) нелинейные, в частном случае – линейные, то и элемент (1.1) соответственно – нелинейный или линейный. Из-за нелинейности большинства статических характеристик уравнения динамических систем являются нелинейными. Упрощение анализа динамической системы чаще всего состоит в приближенной замене нелинейных дифференциальных уравнений на линейные уравнения, решения которых с достаточной степенью точности совпадают с решениями нелинейных уравнений. Такая линеаризация нелинейного уравнения производится относительного некоторого установившегося состояния. Если нелинейность элемента системы вызвана его статической характеристикой, пусть для примера z = ψ(g), то линеаризация характеристики сводится к ее замене на линейную функцию z = ag + b. Аналитически такая замена осуществляется за счет разложения в ряд Тейлора функции z = ψ(g) в окрестности стационарной точки, соответствующей установившемуся состоянию при отбрасывании всех членов ряда, содержащих отклонения входной величины ∆g в степени выше первой. Геометрически это означает замену кривой z = ψ(g) касательной, проведенной к кривой в стационарной точке (z0 , g0), как это показано на рис. 1.2, т.е. в точке установившегося режима. В других случаях линеаризацию можно осуществить путем проведения секущей, мало отличающейся от функции z = ψ(g) в заданном диапазоне изменения входной величины. Такие нелинейные характеристики, т.е. линеаризуемые в любой стационарной точке с требуемым диапазоном изменения входной величины в ее окрестности, называют несущественными нелинейноРис. 1.2. Пример линеаризации z = ψ(g). стями; наряду с ними имеются нелинейные статические характеристики, которые такой линеаризации не поддаются – существенные нелинейности. На рис. 1.3 изображены примеры некоторых существенных нелинейностей: а) – элемент с зоной нечувствительности; b) – релейный элемент с гистерезисом; с) – элемент с люфтом.
7
Рис. 1.3. Существенно нелинейные статические характеристики.
С помощью разложения в ряд Тейлора выполним линеаризацию для уравнений (1.1) и (1.2). Введем в рассмотрение отклонения входной и выходной переменных от установившегося состояния: ∆g (t ) = g (t ) − g 0 , ∆z (t ) = z (t ) − z0 , d∆z (t ) dz (t ) d 2 ∆z (t ) d 2 z (t ) = = z ' (t ), = = z ' ' (t ). 2 2 dt dt dt dt
(1.3)
Разложим левую часть выражения (1.1) в ряд Тейлора относительно состояния (0, 0, z0, g0): d 2 z (t ) dz (t ) ∂F F = + z t g t F z g , , ( ), ( ) ( 0 , 0 , , ) ∆g (t ) + 0 0 2 dt ∂ g 0 dt (1.4) ∂F ∂F ∂F + ∆z (t ) + ∆z ' (t ) + ∆z ' ' (t ) + ВЧР, ∂z 0 ∂z ' 0 ∂z ' ' 0 где аббревиатура ВЧР (высшие члены разложения) обозначает слагаемые, содержащие отклонения ∆z(t), ∆g(t) и производные от ∆z(t) в степени выше первой. Частные производные в правой части уравнения (1.4) являются постоянными величинами, значения которых зависят от вида функций F(z''(t), z'(t), z(t), g(t)) и координат стационарной точки (z0, g0). Вычитая из уравнения (1.1) уравнение (1.2), с учетом равенства (1.4), можно записать следующее соотношение: ∂F ∂F ∂F ∂F ∆g (t ) + ∆z (t ) + ∆z ' (t ) + ∆z ' ' (t ) + g z z z ∂ ∂ ∂ ∂ ' ' ' 0 0 0 0 (1.5) dϕ (t ) + ВЧР = φ , ϕ (t ) − φ (0, ϕ 0 ). dt
Предполагая, что отклонения (1.3) малы по величине, а функция F(z''(t), z'(t), z(t), g(t)) в окрестности стационарной точки достаточно гладкая по всем аргументам, и отбрасывая в левой части уравнения (1.5) слагаемые ВЧР в силу их малости, получим уравнение вида 8
∂F ∂F ∂F ∂F ∆g (t ) + ∆z (t ) + ∆z ' (t ) + ∆z ' ' (t ) = g z z z ∂ ∂ ∂ ∂ ' ' ' 0 0 0 0 (1.6) dϕ (t ) = φ , ϕ (t ) − φ (0, ϕ 0 ). dt
Таким образом, уравнение (1.6) – это линейная модель нелинейного уравнения (1.1), записанная в малых отклонениях относительно заданного установившегося состояния динамической системы. Процедура линеаризации уравнения (1.1) может геометрически быть интерпретирована следующим образом. В пространстве переменных z''(t), z'(t), z(t), g(t) уравнение (1.1) задает некоторую поверхность. Переход от уравнения (1.1) к уравнению (1.6) означает приближенную замену поверхности на касательную плоскость, проведенную к поверхности в стационарной точке. 1.1.2. Первая форма записи линеаризованных уравнений В стандартной первой форме записи принято дифференциальное уравнение элемента системы представлять так, чтобы выходная координата и все ее производные находились в левой части уравнения (причем сама выходная переменная входила бы в уравнение с коэффициентом, равным единице), а все входные переменные располагались в правой части уравнения. В соответствии с этим правилом уравнение (1.6) перепишется следующим образом: ∂F ∂F 2 ∂z ' ' 0 d ∆z (t ) ∂z ' 0 d∆z (t ) + + ∆z (t ) = dt ∂F ∂F dt 2 z z ∂ ∂ 0 0 ∂F dϕ (t ) , ϕ (t ) − φ (0, ϕ 0 ) φ dt ∂g 0 =− ∆g (t ) + . F F ∂ ∂ ∂z 0 ∂z 0
(1.7)
Если для постоянных коэффициентов и отклонений координат уравнения (1.7) ввести обозначения
9
∂F ∂F ∂F g ∂ ∂z ' ' 0 ∂z ' 0 0 T1 = , T2 = , K =− , x(t ) = ∆z (t ), ∂F ∂F ∂F ∂z 0 ∂z 0 ∂z 0 (1.8) dϕ (t ) , ϕ (t ) − φ (0, ϕ 0 ) φ dt u (t ) = ∆g (t ), f (t ) = , ∂F ∂z 0 где f(t) – переобозначение внешнего возмущения ϕ(t), которое математически описано, как правило, недостаточно полно, то уравнение (1.7) приобретает компактный вид: dx(t ) d 2 x(t ) T T1 + + x(t ) = Ku (t ) + f (t ). 2 dt dt 2
(1.9)
Достоинством первой формы записи является удобная размерность коэффициентов в уравнении (1.9). Так, положительные коэффициенты при производных Т1 и Т2, с учетом явного вида соотношений (1.8), имеют соответственно размерность (сек)2 и (сек) и называются постоянными времени. В свою очередь K – это коэффициент передачи, который является безразмерным только тогда, когда размерности входа u(t) и выхода x(t) совпадают. Если K > 0, то это означает, что при увеличении величины u(t) происходит рост значений x(t), если же K < 0, то с ростом u(t) происходит уменьшение x(t).Для линейных динамических систем, описываемых уравнениями типа (1.9), справедлив принцип суперпозиции, согласно которому реакция системы на линейную комбинацию воздействий совпадает с той же линейной комбинацией реакций на каждое воздействие в отдельности. Например, для системы (1.9) это означает, что ее реакция x(t) является суперпозицией решений xu(t) и xf(t) в виде алгебраической суммы откликов на входные воздействия u(t) и f(t). В задачах анализа линейных систем, подверженных действию нескольких входных воздействий, благодаря принципу суперпозиции решений всегда существует возможность исследовать сложную многосвязную задачу как суммы независимых и более простых задач. Поэтому в дальнейшем, как правило, будем рассматривать линейные динамические системы с одним входом, в частности уравнение (1.9) в следующем виде: dx(t ) d 2 x(t ) T T1 + + x(t ) = Ku (t ). 2 2 dt dt 10
(1.10)
1.1.3. Операционное исчисление и преобразование Лапласа Под операционным исчислением понимается один из методов математического анализа, позволяющий в ряде случаев сводить исследование и решение некоторых типов интегродифференциальных уравнений к рассмотрению более простых алгебраических задач. Операционное исчисление нашло широкое применение при исследовании динамических систем, т.к. его помощью осуществляется анализ переходных и установившихся процессов. Рассмотрим основной способ применения операционного метода. Пусть имеется некоторая функция f(t) действительной переменной t, причем такая, что для нее существует прямое преобразование Лапласа (Lпреобразование) ∞
F ( s ) = L{ f (t )} = ∫ f (t )e − st dt ,
(1.11)
0
где интеграл в правой части равенства сходится. Используя L-преобразование, можно каждой функции-оригиналу f(t) поставить в соответствие функцию-изображение F(s), т.е. изображение по Лапласу относительно комплексной переменной s = c + jω. Преобразование Лапласа имеет неоспоримые преимущества, например, – дифференцированию оригинала f(t) по переменной t соответствует операция умножения изображения F(s) на переменную s, а интегрированию оригинала f(t) соответствует операция деления F(s) на s. Принципиально важным является то, что относительно сложные операции дифференцирования и интегрирования оригинала заменяются в пространстве изображений на более простые алгебраические – соответственно операции умножения и деления изображения F(s) на s. Это позволяет дифференциальное уравнение относительно функции f(t) заменить в пространстве изображений на алгебраическое уравнение, записанное относительно изображения F(s), решив которое можно найти F(s). L-преобразованию (1.11) присущ ряд свойств. Линейность: n n L ∑ ak f k (t ) = ∑ ak Fk ( s ). k =1 k =1 11
Смещение в комплексной области:
{
}
L f (t )e ±α t = F ( s m α ). Изображение производных: df (t ) L = sF ( s ) − f (0), ..., dt d n f (t ) n n −1 n−2 ( n −1) L = s F ( s ) − s f ( 0 ) − s f ' ( 0 ) − ... − f (0). n dt
(1.12)
(1.13)
Изображение интеграла: t 1 L ∫ f (τ )dτ = F ( s ). 0 s
(1.14)
Смещение∗ в действительной области: L{ f (t − τ )} = e − sτ F ( s ).
(1.15)
Свертка функций в действительной области: t L ∫ f1 (τ ) f 2 (t − τ )dτ = F1 ( s ) F2 ( s ). 0
(1.16)
Свертка функций в комплексной области: 1 c + j∞ L{ f1 (t ) f 2 (t )} = ∫ F1 (q) F2 ( s − q)dq. 2πj c − j∞
(1.17)
Начальное и предельное значение оригинала: lim sF ( s ) = lim f (t ),
s →∞
t → +0
lim sF ( s ) = lim f (t ).
s →0
(1.18)
t →∞
Результаты прямого интегрального преобразования Лапласа наиболее распространенных временных функций в силу их прикладной значимости сведены в таблицы в виде набора стандартных соответствий типа оригинал-изображение, часть из которых дана в табл. 1.1.
∗
Если смещение τ рассматривается относительно переменной времени t, то его называют запаздыванием. 12
Таблица 1.1 №
Оригинал
Изображение
1.
1(t)
2.
e-α t
3. 4.
e −α t − e − β t β −α sin ω t
1 s 1 s +α 1 ( s + α )( s + β )
5.
cos ω t
6.
tn
7.
1
ω
ω s2 + ω 2 s s2 + ω 2 n! s n +1 1 (s + α )2 + ω 2 s +α (s + α )2 + ω 2 1 s 2 (s + α ) s + a0 (s + α )2 1 s(s + α ) 2 s + a0 s(s + α ) 2 s (s 2 + ω 2 )2
e −α t sin ω t
8.
e −α t cos ω t
9.
e −α t + α t − 1
10.
α2 [(a0 − α )t + 1]e −α t
11.
1 − (1 + α t )e −α t
α2
12. 13.
a0 −α t α − a0 + − t e α 2 α α 2 1 t sin ω t 2ω a0
Определение искомого решения f(t) осуществляется с помощью обратного преобразования Лапласа (L-1-преобразованием), устанавливающего связь между изображением F(s) и соответствующим ему оригиналом f(t): 13
1 c + jω st f (t ) = L {F ( s )} = ∫ F ( s )e ds, t > 0, c = Re s. 2πj c − jω −1
(1.19)
Формула обращения (1.19) устанавливает однозначное соответствие между изображением и оригиналом в точках непрерывности оригинала. Вычисление оригинала f(t) по формуле (1.19) удобно производить с помощью вычетов, хотя можно и избежать непосредственного интегрирования – например, воспользовавшись набором стандартных соответствий типа изображение-оригинал, некоторые из которых представлены в табл. 1.2. Таблица 1.2 № 1. 2. 3. 4. 5.
F(s)
f(t) (t > 0)
1 1 1 A= , B=− Ae a t + B s( s − a) a a s+d d d Ae a t + B A = 1 + , B = − s( s − a) a a 1 1 1 , B= A= Ae a t + Beb t ( s − a )( s − b) a−b b−a s+d a+d b+d , B= A= Ae a t + Beb t ( s − a )( s − b) a−b b−a 1 1 1 1 A= ,B = ,C = at bt s ( s − a )( s − b) Ae + Be + C a ( a − b) b(b − a ) ab
6.
s+d at bt s ( s − a )( s − b) Ae + Be + C
7.
s 2 + qs + d at bt s ( s − a )( s − b) Ae + Be + C
A=
a+d b+d d ,B = ,C = a ( a − b) b(b − a ) ab
a 2 + qa + d b 2 + qb + d A= ,B = , a ( a − b) b(b − a ) d C= ab
Метод решения обыкновенных дифференциальных уравнений с помощью операционного исчисления, представленный графически в виде последовательности основных этапов, показан на рис. 1.4. 14
Рис. 1.4. Алгоритм решения обыкновенных дифференциальных уравнений.
1.1.4. Вторая форма записи уравнений на основе W(s) Передаточной функций W(s) называется отношение изображения выхода x(s) к изображению входа u(s): W ( s) =
x( s ) u(s)
(1.20)
при нулевых начальных условиях. Применение L-преобразования, в частности к уравнению (1.10), позволяет записать соотношение T1s 2 x( s ) + T2 sx ( s ) + x( s ) = Ku ( s ),
преобразование которого согласно определению W(s) дает следующий результат: K . (1.21) 2 T1s + T2 s + 1 Если динамическая система подвержена действию нескольких входных сигналов – см. например, (1.9), то вторую форму записи такого уравнения можно представить в виде x( s ) = W ( s )u ( s ), W ( s ) =
x( s) =
K 1 u ( s ) + f ( s ). T1s 2 + T2 s + 1 T1s 2 + T2 s + 1 15
(1.22)
Понятие передаточной функции динамической системы весьма удобно при анализе так называемых структурных схем – например, уравнению (1.22) соответствует схема, показанная на рис. 1.5. В тех случаях, когда существует возможность вычисления значений Рис. 1.5. Структурная схема полюсов W(s) или кор-ней знаменадинамической системы (1.22). теля передаточной функции, называемого характеристическим уравнением, можно с помощью данных табл. 1.2 найти явный вид искомой функции. Действительно, пусть в динамической системе, описываемой уравнением (1.21), входной сигнал – единичная функция, т.е. u(t) = 1(t) (изображение которой имеет вид u(s) = 1/s: см. данные табл. 1.1 в первой строке). Поскольку для передаточной функции (1.21) из равенства T1s2 + T2s + 1 = 0 следует, что s1, 2
− T2 ± T22 − 4T1 = , 2T1
(1.23)
то, переписав сомножительW(s)u(s) эквивалентным образом, находим явный вид изображения выходного сигнала x( s ) = W ( s )u ( s ) =
K / T1 . s ( s − s1 )( s − s2 )
Тогда искомый оригинал, согласно данным табл. 1.2 (пятая строка), соответствующий изображению x(s), будет описываться равенством 1 1 1 K , (1.24) e s1t + e s2t + T1 s1 ( s1 − s2 ) s2 ( s2 − s1 ) s1s2 где вещественные или комплексные числа s1 и s2, вычисляются по формулам (1.23). Кроме того, учитывая значения x(t ) =
s1 − s2 = −
T2 1 , s1s2 = , T1 T1
равенство (1.24) можно представить и следующим образом: 1 s1t 1 s2t x(t ) = K − e + e + 1. T s T s 21 2 2 16
(1.25)
1.2. Временные и частотные характеристики непрерывных систем Как уже отмечалось, для анализа динамических систем их разбивают на отдельные элементы. Классификация динамических элементов обычно осуществляется по виду дифференциального уравнения. Статическая характеристика любого элемента может быть изображена прямой линией (рис. 1.6), поскольку по-прежнему рассматриваются линейные, а точнее, – линеаризованные системы.
Рис. 1.6. Статические характеристики линейных элементов.
В элементах позиционного (статического) типа линейной зависимостью x(t) = Ku(t) связаны выходная и входная координаты в установившемся режиме. В элементах интегрирующего типа, при t → ∞ выходная и входная переменные связаны линейным уравнением t dx(t ) = Ku (t ) , или x(t ) = K ∫ u (q)dq . dt 0 В элементах дифференцирующего типа аналогичная линейная связь имеет вид
x(t ) = K
du (t ) . dt
1.2.1. Временные характеристики Динамические свойства элемента могут быть определены по его переходной функции и функции веса. Переходная функция h(t) (переходная характеристика) представляет собой временной отклик или реакцию выхода элемента, при подаче на его вход единичного сигнала 17
1, ∀t ≥ 0, u (t ) = 1(t ) = 0, t < 0,
(1.26)
который часто называют единичной ступенью, или единичным скачком. Предполагается, что единица имеет размерность физической величины на входе элемента. Графические образы временных сигналов 1(t) и h(t) показаны на рис. 1.7.
Рис. 1.7. Единичная ступень 1(t) и переходной процесс h(t).
Функция 1(t) – весьма распространенный вид входного воздействия в динамических системах. К такому виду сводятся мгновенное изменение нагрузки электрического генератора, мгновенное возрастание момента нагрузки на валу двигателя, мгновенный поворот руля управления движущегося автомобиля и т.д. Функция веса ω(t) (импульсная переходная характеристика) является временной реакцией выхода элемента при подаче на его вход единичного импульсного сигнала ∞, t = 0, u (t ) = δ (t ) = (1.27) 0 , t ≠ 0 . Основное свойство дельта-функции δ (t) заключается в том, что она имеет единичную площадь: ∞
∫ δ (t )dt = 1,
−∞
Характеристика ω (t) в динамических системах является распространенным видом входного воздействия. К такому виду можно отнести, например, кратковременный удар нагрузки на валу двигателя, кратковременный ток короткого замыкания генератора (отключаемый плавкими предохранителями) и т.п. Один из вариантов представления функций δ (t) и ω (t) показан рис. 1.8, где рассматривается динамический элемент при нулевых начальных условиях 18
ω(0) = 0.
Рис. 1.8. Функция δ (t) и импульсная переходная функция ω (t).
Можно показать, что между функциями h(t) и ω(t) существует связь вида
ω (t ) =
dh(t ) . dt
Кроме того, передаточная функция связана с переходным процессом и импульсной переходной функцией элемента – прямым интегральным преобразованием Лапласа ∞
W ( s ) = ∫ ω (t )e 0
− st
∞
dt =s ∫ h(t )e − st dt .
(1.28)
0
1.2.2. Частотные характеристики Динамические свойства элемента в частотной области определяются его частотной передаточной функцией W(jω), получаемой из функции W(s) путем замены s на jω, где j2 = -1, ω ∈ R, -∞ ≤ ω ≤ +∞. Часто W(jω) называют амплитудно-фазовой частотной характеристикой, или комплексным коэффициентом усиления. Поскольку в комплексной плоскости геометрический образ Рис. 1.9. Комплексная плоскость W(jω). функции W(jω) (рис. 1.9), может описываться как в прямоугольных, так и в полярных координатах, то частотную передаточную функцию будем рассматривать в виде 19
W ( jω ) = Re(W ( jω )) + j Im(W ( jω )) = = mod(W ( jω ))e j arg(W ( jω )) ,
(1.29)
где введены обозначения: Re(W(jω)) = U(ω) – вещественная частотная характеристика; Im(W(jω)) = V(ω) – мнимая частотная характеристика; mod(W(jω)) = A(ω) – амплитудная частотная характеристика; arg(W(jω)) = ϕ(ω) – фазовая частотная характеристика. В комплексной плоскости график векторной функции W(jω) – это годограф (геометрическое место конца вектора). Для пар характеристик (U(ω), V(ω)) и (A(ω), ϕ(ω)) в любой фиксированной точке ω = ω* (рис. 1.9) справедливы следующие формулы: V (ω * ) A(ω ) = U (ω ) + V (ω ) , ϕ (ω ) = arctg , U (ω * ) *
2
*
2
*
*
(1.30)
U (ω * ) = A(ω * ) cos ϕ (ω * ), V (ω * ) = A(ω * ) sin ϕ (ω * ). Поскольку передаточная функция W(s) любой системы является дробно-рациональной функцией вида R ( s ) r0 s m + r1s m −1 + ... + rm −1s + rm = W ( s) = , Q( s ) q0 s n + q1s n −1 + ... + qn −1s + qn
(1.31)
то в частотной области для нее справедливы, во-первых, соотношения (в прямоугольных координатах): W ( jω ) = U (ω ) = V (ω ) =
U R (ω ) + jVR (ω ) = U (ω ) + jV (ω ), U Q (ω ) + jVQ (ω )
U R (ω )U Q (ω ) + VR (ω )VQ (ω ) U Q2 (ω ) + VQ2 (ω ) U R (ω )VQ (ω ) − VR (ω )U Q (ω ) U Q2 (ω ) + VQ2 (ω )
, ,
U R (ω ) = Re( R ( jω )),
(1.32)
VR (ω ) = Im(R( jω )), U Q (ω ) = Re(Q( jω )), VQ (ω ) = Im(Q( jω ));
во-вторых, выражения (в полярных координатах): 20
W ( jω ) = A(ω ) =
AR (ω )e jϕ R (ω ) AQ (ω )e
jϕ Q (ω )
= A(ω )e jϕ (ω ) ,
AR (ω ) , AQ (ω )
ϕ (ω ) = ϕ R (ω ) − ϕ Q (ω ), AR (ω ) = mod( R ( jω )),
(1.33)
ϕ R (ω ) = arg( R( jω )), AQ (ω ) = mod(Q( jω )), ϕ Q (ω ) = arg(Q( jω )). Формулы (1.30) – (1.33) оказываются весьма полезными при решении как теоретических, так и прикладных задач.
21
2. МОДЕЛИ В ПРОСТРАНСТВЕ СОСТОЯНИЙ
В современной теории систем активно развиваются и используются методы пространства состояний. Начало систематического использования методов пространства состояний обычно связывают с работами Л.С. Понтрягина – по математической теории оптимальных процессов, Р. Беллмана – по динамическому программированию и Р. Калмана – по общей теории фильтрации и управления. 2.1. Состояние динамической системы К преимуществам методов пространства состояний общепринято относить: − одинаковую формулировку различных задач и простоту их решения при наличии большого числа переменных; − возможность обнаружения и исследования таких свойств систем, которые при использовании классических подходов в терминах "входвыход" остались бы недоступными; − возможность анализа и синтеза нестационарных и нелинейных динамических систем; − использование векторно-матричной формы представления для описа− сания исследовательских задач, имеющей неоспоримое преимущество при их численном решении на ПЭВМ. Основной недостаток методов пространства состояний заключается в том, что переменные состояния сохраняют ясный физический смысл только тогда, когда они наблюдаемы и могут быть измерены или когда переменные состояния совпадают с фазовыми x1(t)=x(t), x2(t)=dx1(t)/dt, …, xn(t)=dxn-1(t)/dt. В противном случае, если выбор переменных состояния определяется иным образом, связь математической модели с физической реальностью теряется и, как следствие, исчезает возможность корректного сопоставления расчетных и экспериментальных данных. 22
2.1.1. Вход, состояние и выход Динамика системы описывается ее математической моделью, аналитически отражающей зависимости между тремя множествами переменных: переменными входа u(t)∈Rm, выхода y(t)∈Rl и состояния x(t)∈Rn, где Ri – i-мерное линейное вещественное пространство. Вход системы, выраженный множеством временных функций, представляет описание внешних переменных, действующих на систему. Выход системы, выраженный аналогично, – это описание наблюдаемых выходных переменных, непосредственно отражающих поведение системы. Как уже отмечалось в главе 1, любая система состоит из набора подсистем или элементов (звеньев), которые по характеру реакции на входное воздействие делятся на статические и динамические. Отличительной особенностью статической системы является ее безынерционность, т.е. наличие мгновенной реакции на входное воздействие, никак не связанное с ее предыдущим положением. В любой момент времени t0 значение выхода статической системы y(t0) однозначно определяется по значению входа u(t0), а сама связь (стационарная или нестационарная) статическая характеристика – описывается одним из уравнений: y = F(u), y = F(u, t). Важнейшее свойство любой динамической системы – это зависимость ее реакции как от переменных, действующих на систему в данный момент, так и от переменных, действовавших на нее в прошлом. Отметим, что для определения в момент времени t1 значения выхода y(t1) информации только о значении входа u(t1) недостаточно, поскольку требуются еще сведения о предыстории изменения u(t) на некотором интервале t∈[t0, t1] и начальном состоянии x(t0). Такую зависимость будем описывать следующим образом: y(t1) = S(x(t0), u(t)),
t ∈ [t0, t1],
(2.1)
где S – оператор преобразования одной функции в другую. Таким образом, состояние динамической системы – это некий параметр, однозначно определяющий реакцию выхода системы относительно входа. Состояние системы должно удовлетворять так называемым аксиомам совместности. Укажем две наиболее важные. Первая аксиома совместности. Для определения будущего поведения системы не играет роли то, каким образом она пришла в данное со23
стояние, поскольку траектория движения системы определяется однозначно по начальному состоянию и динамике входа в рассматриваемом интервале времени. Выход y(t), ∀t ≥ t0 определяется однозначно при заданных x(t0) и u(t), t∈[t0, t1]. Вторая аксиома совместности. Если траекторию движения системы разбить на участки, то каждый из них можно рассматривать как новую траекторию с соответствующим начальным условием. При этом в зависимости от входного процесса и начального состояния динамика системы будет изменяться соответствующим образом. Пусть t0 < t1 < t2 , тогда при любом x(t0) и ∀t∈[t0, t1] выход y(t1) будет определяться уравнением (2.1). Если же вычислить значение x(t1), то выход y(t2) будет следующим: y(t2) = S(x(t1), u(t)),
t ∈ [t1, t2].
2.1.2. Пространство состояний Множество Х = {x} возможных значений состояния системы называется пространством состояний. В случае Х = Rn состояние х = x(t) есть n-мерный вещественный вектор – вектор состояния (в частном случае – это фазовый вектор), элементы которого будем обозначать через xi(t), i = 1, n . Вектор, составленный из указанных элементов, обычно записывают следующим образом: х = x(t) = [x1(t), x2(t), …, xn(t)]T, где Т – символ транспонирования. Если х – состояние системы, µ(⋅) – некоторое взаимно однозначное отображение пространства Х в себя (µ : Х → Х), Рис. 2.1. Переменные то x = µ(х) также можно считать состоядинамической системы. нием данной системы. Тогда состояние х можно определить различным, но взаимно однозначным образом. Например, если Х = Rn, а T – n-мерная невырожденная матрица (det T ≠ 0), то вектор x = Тх также можно применять для описания состояния системы, поскольку х = Т –1 x , где Т –1 – обратная матрица.
24
2.2. Описание динамической системы в нормальной форме Уравнения состояния так называемых конечномерных дифференциальных (непрерывных) систем можно представить в виде dx(t ) = f ( x(t ), u (t ), t ), x(t0 ) = x0 , t ≥ t0 , dt
(2.2)
y (t ) = g ( x(t ), u (t ), t ),
(2.3)
где f(⋅), g(⋅) – вектор-функции от векторных аргументов. Уравнение (2.2) называют уравнением состояния (эволюционным уравнением), описывающим изменение состояния системы во времени t∈R, в соответствии с начальным условием x(t0) и входным воздействием u(t), а уравнение (1.3) – уравнением выхода, устанавливающим статическую связь между значениями выхода и текущими значениями состояния и входа. 2.2.1. Уравнения линейных систем в пространстве состояний Метод пространства состояний в качестве базовой математической модели системы (2.2), (2.3), когда функции f(⋅), g(⋅) линейны по x, u, предполагает использование уравнений вида dx(t ) = A(t ) x(t ) + B (t )u (t ), x(t0 ) = x0 , t ≥ t0 , (2.4) dt y (t ) = C (t ) x(t ) + D(t )u (t ), (2.5) где x(t)∈Rn; u(t)∈Rm; y(t)∈Rk; матрицы-функции A(t), B(t), С(t), D(t) соответствующего размера1. Системы (2.4), (2.5) называются непрерывными линейными системами, в которых матрицы A(t), B(t) и С(t) имеют следующую структуру: a11 (t ) A(t ) = ... a (t ) n1 1
a12 (t )
...
...
...
an 2 (t )
...
a1n (t ) ... , ann (t )
(2.6)
В теории автоматического управления матрицы, входящие в уравнения (2.4), (2.5), обычно называют: A(t) – матрицей состояния системы, B(t) – матрицей управления, С(t) – матрицей выхода, D(t) – матрицей обхода системы. 25
b11 (t ) B(t ) = ... b (t ) n1
b12 (t )
...
...
...
bn 2 (t )
...
b1m (t ) ... , m ≤ n, bnm (t )
(2.7)
c12 (t ) c1n (t ) ... c11 (t ) C (t ) = ... ... ... ... , l ≤ n. (2.8) c (t ) cl 2 (t ) cln (t ) ... l1 В случае, когда матрица D(t) ≡ 0, систему (2.4), (2.5) называют собственной2 (строго реализуемой), а при D(t) ≠ 0 – несобственной. Систему (2.4), (2.5) с матрицами A(t), B(t), С(t), D(t) называют нестационарной, если же элементы этих матриц от времени не зависят, то система – стационарная. Структура стационарной линейной системы представлена на рис. 2.2, для которой (например, при n > m), математическое описание будет следующим: dx(t ) = Ax(t ) + Bu (t ), x(t0 ) = x0 , t ≥ t0 , (2.9) dt y (t ) = Cx (t ) + Du (t ), D = 0. (2.10)
Рис. 2.2. Структурная схема стационарной динамической системы.
Системы (2.4), (2.5) и (2.9), (2.10) часто называют нормальными системами, или системами в нормальной форме Коши. В тех случаях, когда в системе (2.9), (2.10) переменные состояний совпадают с фазовыми, оказывается, что матрица А имеет специфическую форму записи − форму Фробениуса, представляемую в виде 1 0 0 0 1 0 A= ... ... ... − an − an−1 − an−2 2
... ... ... ...
0 0 , ... − a1
(2.11)
Такой тип систем в прикладных задачах является наиболее распространенным. 26
где ai = const > 0. Для матрицы Фробениуса характерно следующее: элементы над главной диагональю равны единице, а элементы нижней строки являются коэффициентами однородного дифференциального уравнения n-го порядка dx(t ) d n x(t ) d n −1 x(t ) + + ... + a + an x(t ) = 0. a n − 1 1 n n −1 dt dt dt
(2.12)
Иногда матрицу Фробениуса называют матрицей сопровождения. 2.2.2. Способы программирования в переменных состояния Наиболее распространенными приемами построения моделей динамических систем в переменных состояния являются приемы, основанные на способах прямого, параллельного или последовательного программирования. Поскольку исходное математическое описание системы в этих способах программирования – передаточная функция, выберем описание динамической системы, например, в следующем виде: b0 s 2 + b1s + b2 x( s ) = W ( s )u ( s ) = u ( s ). a0 s 3 + a1s 2 + a2 s + a3
(2.13)
Прямое программирование относится к наиболее общим подходам, позволяющим осуществить переход в пространство состояний без какихлибо предварительных условий. Этапы прямого программирования предусматривают последовательное выполнение следующих типовых действий или процедур: во-первых, числитель и знаменатель функции W(s) вида (2.13) разделим на выражение a0s3, соответствующее слагаемому с максимальной степенью s в знаменателе, в результате получим уравнение b0 −1 b1 − 2 b2 − 3 s + s + s a0 a0 a0 u ( s ); x( s) = a1 −1 a2 − 2 a3 − 3 1+ s + s + s a0 a0 a0
(2.14)
во-вторых, введем обозначение E ( s) =
1 u ( s ); a1 −1 a2 − 2 a3 − 3 1+ s + s + s a0 a0 a0 27
(2.15)
в-третьих, перепишем уравнение (2.15) следующим образом: E ( s) = u ( s) −
a a a1 −1 s E ( s ) − 2 s − 2 E ( s ) − 3 s − 3 E ( s ); a0 a0 a0
(2.16)
в-четвертых, учитывая соотношение (2.15), а также вводя обозначение выхода y(s) = x(s), представим уравнение (2.14) в виде b0 −1 b b (2.17) s E ( s ) + 1 s − 2 E ( s ) + 2 s − 3 E ( s ); a0 a0 a0 в-пятых, введем в рассмотрение переменные состояния, которые в изображениях зададим следующим образом: y ( s ) = x( s) =
x1 ( s ) = s − 3 E ( s ),
(2.18)
x2 ( s ) = s − 2 E ( s ),
(2.19)
x3 ( s ) = s −1E ( s );
(2.20)
в-шестых, запишем совместно уравнения (2.15) – (2.18). Подстановка соотношений (2.19) в (2.18) и соответственно (2.20) в (2.19) позволяет записать уравнения x1 ( s ) = s −1 x2 ( s ), x2 ( s ) = s −1 x3 ( s ).
(2.21)
Кроме того, подстановка E(s) вида (2.16) в соотношение (2.17), с учетом обозначений (2.18) – (2.20), позволяет записать равенство y(s) =
b0 b b x1 ( s ) + 1 x2 + 2 x3 ( s ). a0 a0 a0
(2.22)
Аналогичные действия, выполненные для выражения (2.20), приводят к следующему уравнению a a a x3 ( s ) = s −1 u ( s ) − 1 x3 ( s ) − 2 x2 ( s ) − 3 x1 ( s ) . a0 a0 a0
(2.23)
Объединяя уравнения (2.20) – (2.23), окончательно получаем
28
sx1 ( s ) = x2 ( s ), sx2 ( s ) = x3 ( s ), sx3 ( s ) = − y(s) =
a3 a a x1 ( s ) − 2 x2 ( s ) − 1 x3 ( s ) + u ( s ), a0 a0 a0
(2.24)
b0 b b x1 ( s ) + 1 x2 ( s ) + 2 x3 ( s ), a0 a0 a0
где первые три уравнения – уравнения состояний системы, а последнее – уравнение ее выхода. Уравнения (2.24), записанные в изображениях, можно переписать относительно оригиналов следующим образом: dx1 (t ) = x2 (t ), dt dx2 (t ) = x3 (t ), dt dx3 (t ) a a a = − 3 x1 (t ) − 2 x2 (t ) − 1 x3 (t ) + u (t ), a0 a0 dt a0 y (t ) =
(2.25)
b0 b b x1 (t ) + 1 x2 (t ) + 2 x3 (t ), a0 a0 a0
т.е. в виде, который полностью идентичен уравнениям нормальной системы (2.9), (2.10), полагая, что имеют место соотношения xT (t ) = ( x1 (t ) x2 (t ) x3 (t ) ), 0 A= 0 − a3 a 0 b C = 0 a0
1 0 a − 2 a0 b1 a0
0 0 1 , B = 0 , a 1 − 1 a0
(2.26)
b2 , D = 0. a0
Для наглядности приведем числовой пример. Пусть в исходной передаточной функции W(s) вида (2.13) коэффициенты имеют значения: b0 = 1, b1 = 7, b2 = 12, a0 = 1; a1 = 3, a2 = 2, a3 = 0,
(2.27)
тогда в системе (2.9), (2.10) матрицы и векторы будут следующими: 29
0 0 0 1 A = 0 0 1 , B = 0 , C = (12 7 1), D = 0. 1 0 − 2 − 3
(2.28)
Для динамической системы (2.25) – (2.27) или в нормальной форме системы (2.9), (2.10), (2.28) можно построить структурную схему в пространстве состояний, показанную на рис. 2.3.
Рис. 2.3. Структурная схема динамической системы (2.25) – (2.27).
Параллельное программирование. Для применения этого способа требуется, чтобы полюса передаточной функции W(s) – корни знаменателя – были бы вещественными и рациональными, т.е. допускалось представление W(s) в виде суммы дробно-рациональных функций. Данный способ программирования рассмотрим на числовом примере. Пусть аналогично системе (2.13), (2.27) исследуемая система описывается уравнением s 2 + 7 s + 12 x( s) = 3 u ( s ). s + 3s 2 + 2 s
(2.29)
Параллельное программирование предусматривает выполнение определенной последовательности действий: во-первых, учитывая явный вид W(s), выражение (2.29) перепишем следующим образом: s 2 + 7 s + 12 s 2 + 7 s + 12 u ( s) = u(s) = x( s) = 3 s(s + 1)(s + 2 ) s + 3s 2 + 2 s α1
α2
α3
= + + u ( s ), s s +1 s + 2
где α1, α2, α3 – неопределенные множители; 30
(2.30)
во-вторых, используя тождество
α1 (s + 1)(s + 2) + α 2 s(s + 2 ) + α 3 s(s + 1) = s 2 + 7 s + 12 , запишем систему линейных уравнений относительно его коэффициентов
α1 + α 2 + α 3 = 1, 3α1 + 2α 2 + α 3 = 7, 2α1 = 12, решение которой будет иметь вид
α1 = 6, α 2 = −6, α 3 = 1;
(2.31)
в-третьих, учитывая (2.31), а также переобозначение y(s) = x(s), перепишем уравнение (2.30) следующим образом: 1 1 1 ⋅ (−6) + ⋅ 1u ( s ); y(s) = ⋅ 6 + s +1 s+2 s
(2.32)
в-четвертых, в соответствии с выражением (2.32) введем в рассмотрение переменные состояния 1 1 1 x1 ( s ) = u ( s ), x2 = u ( s ), x3 ( s ) = u ( s ), s s +1 s+2 уравнения которых в эквивалентном виде будут иметь вид
(2.33)
sx1 ( s ) = u ( s ), sx2 ( s ) = − x2 ( s ) + u ( s ),
(2.34)
sx3 ( s ) = −2 x3 ( s ) + u ( s ),
а также, учитывая явный вид переменных состояния (2.33), перепишем уравнение (2.32) следующим образом: y ( s ) = 6 x1 ( s ) − 6 x2 ( s ) + x3 ( s ).
(2.35)
Уравнения состояния (2.34) и уравнение выхода (2.35) можно записать и в оригиналах, т.е. в виде системы уравнений dx2 (t ) dx1 (t ) = u (t ), = − x2 (t ) + u (t ), dt dt (2.36) dx3 (t ) = −2 x3 (t ) + u (t ), y (t ) = 6 x1 (t ) − 6 x2 (t ) + x3 (t ), dt которой в векторно-матричной форме (2.9), (2.10) соответствуют следующие матрицы и векторы: 31
0 0 0 1 A = 0 − 1 0 , B = 1, C = (6 − 6 1), D = 0. 0 0 − 2 1
(2.37)
Структурная схема динамической системы (2.36) или (2.9), (2.10), (2.37) показана на рис. 2.4. Последовательное программирование. Для применения этого способа должно быть выполнено условие – W(s) исследуемой системы должна быть представлена в виде произведения дробно-рациональных функций, иначе говоря, как полюса, так и нули W(s) должны быть вещественны и рациональны. Применение способа параллельного программирования, как и в предыдущем случае параллельного программирования, Рис. 2.4. Структурная схема рассмотрим на примере выражения (2.29). системы (2.36). Этапы осуществления последовательного программирования следующие: во-первых, уравнение (2.29) перепишем в виде s 2 + 7 s + 12 1 ( s + 3) ( s + 4 ) x( s) = 3 = ⋅ ⋅ u ( s ) u ( s ); s (s + 1) (s + 2) s + 3s 2 + 2 s
(2.38)
во-вторых, введем в рассмотрение дополнительные переменные u1(s), Е1(s) и переменную состояния х1(s), задавая уравнения u1 ( s ) =
1 ( s + 3) 1 −1 u ( s ), E1 ( s ) = u ( s ), x ( s ) = s E1 ( s ), (2.39) 1 1 −1 s (s + 1) 1 + 2s
что позволяет первую переменную состояния х1(s) описать в виде 1 s −1 ( ) u s u1 ( s ) x1 ( s ) = = 1 s+2 1 + 2 s −1 или следующим образом: sx1 ( s ) = −2 x1 ( s ) + u1 ( s );
(2.40)
в-третьих, подобно предыдущему этапу, введем в рассмотрение переменные вида 1 1 u2 ( s ) = u ( s ), E2 ( s ) = u ( s ), x2 ( s ) = s −1E2 ( s ), (2.41) −1 2 s 1+ s 32
что позволяет преобразовать выражение u1(s) из (2.39) и получить соотношение u1 ( s ) =
(
)
s+3 u 2 ( s ) = 1 + 3s −1 E2 ( s ) = u 2 ( s ) + 2 x2 ( s ), s +1
(2.42)
а также записать следующее уравнение для второй переменной состояния: sx2 ( s ) = − x2 ( s ) + u2 ( s );
(2.43)
в-четвертых, аналогично двум предыдущим этапам введем в рассмотрение переменные вида E3 ( s ) = u ( s ), x3 ( s ) = s −1E3 ( s ),
(2.44)
тогда выражение для u2(s) из (2.41) получит вид 1 u2 ( s ) = E3 ( s ) = x3 ( s ), s
(2.45)
а третье уравнение состояния будет следующим: sx3 ( s ) = u ( s );
(2.46)
в-пятых, в результате подстановки уравнений (2.45) в (2.43) и (2.45) в (2.42), а затем (2.42) в (2.40) получаем систему уравнений состояния в виде: sx1 ( s ) = −2 x1 ( s ) + 2 x2 ( s ) + x3 ( s ), sx2 ( s ) = − x2 ( s ) + x3 ( s ),
(2.47)
sx3 ( s ) = u ( s );
в-шестых, обозначая выход y(s) = x(s) и выполняя подстановку выражения (2.39) в (2.38), получаем
(
)
y ( s ) = 1 + 4 s −1 E1 ( s ) = E1 ( s ) + 4 x1 ( s ) = u1 ( s ) + 2 x1 ( s ),
а также учитывая явный вид функций u1(s) и u2(s) согласно равенствами (2.42) и (2.45), окончательно уравнение выхода у(s) запишем в виде y ( s ) = 2 x1 ( s ) + 2 x2 ( s ) + x3 ( s ).
(2.48)
В оригиналах система уравнений (2.47), (2.48) имеет вид
33
dx1 (t ) = −2 x1 (t ) + 2 x2 (t ) + x3 (t ), dt dx2 (t ) = − x2 (t ) + x3 (t ), dt dx3 (t ) = u (t ), dt y (t ) = 2 x1 (t ) + 2 x2 (t ) + x3 (t ),
(2.49)
которому в векторно-матричной форме записи (2.9), (2.10) соответствуют следующие матрица и векторы: − 2 2 1 0 A = 0 − 1 1 , B = 0 , C = (2 2 1), D = 0. 0 1 0 0
(2.50)
Структурная схема динамической системы (2.49) или (2.9), (2.10), (2.50) показана на рис. 2.5.
Рис. 2.5. Структурная схема динамической системы (2.49).
Кроме приведенных выше способов программирования, построеение модели систем в переменных состояния можно осуществлять и по другим методикам. В частности, структура исследуемой системы может задана. Например, хорошо известно, что при последовательном соединении элементов их передаточные функции перемножаются, а при параллельном – Рис. 2.6. Структурная схема суммируются. Поэтому для системы, динамической системы (2.51). описываемой уравнением 1 1 ( s + 3) ( s + 4 ) x( s) = ⋅ ⋅ + u ( s ), ( ) ( ) s s 1 s 2 s 3 + + + 34
(2.51)
которой соответствует структурная схема, изображенная на рис. 2.6, можно вначале любым из способов выполнить построение моделей в пространстве состояний для каждого из четырех элементов, а затем, исключая промежуточные переменные, записать уравнение модели в переменных состояния для всей системы. Программирование по структурной схеме. Выделим в уравнении (2.51) элементы, описываемые следующим образом: s+4 y2 ( s ), s+2 s+3 (2.52) y2 ( s ) = W2 ( s ) y3 ( s ) = y3 ( s ), s +1 1 1 y3 ( s ) = W3 ( s )u ( s ) = u ( s ), y4 ( s ) = W4 ( s )u ( s ) = u ( s ). s s+3 Для каждой W(s) из (2.52), – например, с помощью прямого программирования – построим модели в пространстве состояний, структурные схемы которых показаны на рис. 2.7. y1 ( s ) = W1 ( s ) y2 ( s ) =
Рис. 2.7. Модели элементов системы (2.52) в пространстве состояний.
Модели элементов динамической системы (2.51) в пространстве состояний, в соответствии с выражениями (2.52), имеют вид dx1 (t ) = −2 x1 (t ) + y2 (t ), y1 (t ) = 2 x1 (t ) + y2 (t ), dt dx2 (t ) = − x2 (t ) + y3 (t ), y2 (t ) = 2 x2 (t ) + y3 (t ), dt dx3 (t ) = u (t ), y3 (t ) = x3 (t ), dt dx4 (t ) = −3 x4 (t ) + u (t ), y4 (t ) = x4 (t ). dt
(2.53)
Структурная схема динамической системы (2.53), в соответствии с моделями вида (2.52) и структурами на рис. 2.6 и рис. 2.7, изображена на рис. 2.8. 35
Рис. 2.8. Модель системы (2.53), (2.54).
Исключая в уравнениях (2.53) промежуточные переменные у1, у2, у3, у4, а также учитывая равенство у = у1 + у4, модель системы (2.51) в пространстве состояний можно записать в виде: dx1 (t ) = −2 x1 (t ) + 2 x2 (t ) + x3 (t ), dt dx2 (t ) = − x2 (t ) + x3 (t ), dt dx3 (t ) (2.54) = u (t ), dt dx4 (t ) = −3 x4 (t ) + u (t ), dt y (t ) = 2 x1 (t ) + 2 x2 (t ) + x3 (t ) + x4 (t ). Векторно-матричная форма представления уравнений (2.54) в виде (2.9), (2.10) имеет место при следующих матрице и векторах: − 2 2 0 −1 A= 0 0 0 0
0 0 1 0 0 = B , 1 , C = (2 2 1 1), D = 0. (2.55) 0 0 0 − 3 1 1
2.2.3. Примеры уравнений состояния систем Манипулятор. С помощью способа прямого программирования уравнение манипулятора можно описать в пространстве состояний уравнениями dx1 (t ) dx2 (t ) = x2 (t ), = −k1 x1 (t ) − k 2 x2 (t ) + u (t ), dt dt (2.56) T2 K K T3 1 y (t ) = k3 x1 (t ) + k 4 x2 (t ), k1 = , k 2 = , k3 = , k 4 = , T1 T1 T1 T1 36
а также представить в виде структурной схемы (см. рис. 2.9). В форме (2.9), (2.10) этим уравнениям соответствуют 1 0 0 , B = , A = 1 (2.57) − k1 − k 2 C = (k3 k 4 ), D = 0 .
Рис. 2.9. Модель манипулятора (2.56) в пространстве состояний.
Ресивер. С помощью способа программирования по структурной схеме, учитывая, что уравнению ресивера соответствует параллельное соединение двух звеньев с выходом y ( s ) = y1 ( s ) + y2 ( s ),
запишем уравнения переменных у1(s) и y2(s) следующим образом: y1 ( s ) = W1 ( s )u ( s ) =
k4 u1 ( s ), s + k3
k K K 1 y2 ( s ) = W2 ( s )u ( s ) = 5 u2 ( s ), k3 = , k 4 = 1 , k5 = 2 . s + k3 T0 T0 T0
(2.58)
Уравнения (2.58) в переменных состояния можно переписать в виде dx1 (t ) = −k3 x1 (t ) + u1 (t ), dt dx2 (t ) (2.59) = −k3 x2 (t ) + u2 (t ), dt y (t ) = k 4 x1 (t ) + k5 x2 (t ) . Структурную модель системы (2.59) в Рис. 2.10. Модель ресивера пространстве состояний можно изобразить в виде схемы, показанной на рис. 2.10. Если же (2.59) в пространстве систему уравнений (2.59) представить в вексостояний. торно-матричном виде (2.9), (2.10), то соответствующие векторы и матрицы будут иметь вид xT = ( x1 − k A = 3 0
x2 ), u T = (u1 u2 ), 0 1 0 , B = , C = (k 4 − k3 0 1
k5 ), D = 0 .
(2.60)
Гидравлический сервомотор. Используя способ прямого програм37
мирования, уравнение гидромотора в переменных состояния можно описать следующим образом: dx1 (t ) dx2 (t ) = x2 (t ), = x3 (t ), dt dt dx3 (t ) = −k 2 x2 (t ) − k3 x3 (t ) + u (t ), y (t ) = k1 x1 (t ), dt K 1 2ζ k1 = 2 , k 2 = 2 , k3 = , T T T
(2.61)
Структурная схема динамической системы (2.61) показана на рис. 2.11.
Рис. 2.11. Модель гидромотора (2.61) в пространстве состояний.
Векторно-матричная форма записи системы (2.61) в виде уравнений (2.9), (2.10) имеет следующие матрицу и векторы: 1 0 A = 0 0 0 − k 2
0 0 1 , B = 0 , C = (k1 0 0 ), D = 0. 1 − k3
(2.62)
Длинный бьеф. С помощью способа прямого программирования уравнение длинного бьефа можно описать в пространстве состояний уравнениями dx1 (t ) = −k 2 x2 (t ) + u (t − τ ), dt y (t ) = k3 x1 (t ) + k 4u (t − τ ), k2 =
(2.63)
K L L 1 , k3 = 1 − 12 , k 4 = 1 . T1 T1 T1 T1
Поскольку дифференциальное уравнение (2.63) – первого порядка, то ее векторно-матричная форма записи вида (2.9), (2.10) также будет скалярной, т.е. матрицы и векторы – скалярные величины, принимающие следующие значения: 38
A = −k 2 , B = 1, C = k3 , D = k 4 .
(2.64)
В выражении (2.64) в отличие, например, от соотношений (2.57), (2.60) или (2.62), матрица обхода системы D ≠ 0, что объясняется равенством порядка числителя и знаменателя передаточной функции из (1.98). Структурную модель системы (2.63) или (2.9), (2.10), (2.64) в пространстве состояний можно представить в виде схемы, приведенной на рис. 2.12.
Рис. 2.12. Модель длинного бьефа (2.63) в пространстве состояний.
2.2.4. Передаточные функции нормальных систем Рассмотрим модель нормальной системы, записанную в пространстве состояний dx(t ) = Ax(t ) + Bu (t ), dt y (t ) = Cx (t ) + Du (t ),
(2.65) (2.66)
где x(t)∈Rn; u(t)∈Rm; y(t)∈Rl. Перепишем уравнения системы (2.65), (2.66) в изображениях с помощью векторно-матричной передаточной функции системы. С этой целью выполним преобразование Лапласа над уравнениями (2.65) и определим изображение вектора состояний x(s) в виде sE − A)+ ( −1 x( s ) = (sE − A) Bu ( s ) = Bu ( s ), (2.67) det (sE − A) где (sE – A)-1 – обратная матрица; det(sE – A) – детерминант матрицы; (sE – A)+ – присоединенная1 матрица к матрице (sE – A); E – единичная матрица соответствующего размера, в данном случае (n x n). Если соотношение (2.66) записать в изображениях, куда затем подставить x(s) из (2.67), то получим равенство
(
)
y ( s ) = C (sE − A)−1 B + D u ( s ) = W ( s )u ( s ), 1
(2.68)
По определению это транспонированная матрица алгебраических дополнений. 39
где W(s) – передаточная функция в виде матричного2 множителя, связывающего изображения по Лапласу выхода у(s) и входа и(s) при нулевом начальном состоянии x(0). В строго реализуемых системах функция W(s) имеет более простой вид W ( s ) = C (sE − A)−1 B . (2.69) Размер матрицы W(s) определяется размерностями выхода у(s) и входа и(s), в рассматриваемом случае (l x m). При l = m = 1 функция W(s) будет скалярной, но в общем случае W(s) – это матричная функция с элементами Wij(s), т.к. выражение (2.68) можно представить соотношением y1 ( s ) W11 ( s ) ... W1m ( s ) u1 ( s ) ... ... ... ... = ... . y ( s ) W ( s ) ... W ( s ) u ( s ) lm m l l1
2.2.5. Уравнения состояний при типовом соединении систем В ряде прикладных задач возникает необходимость в получении математического описания системы в пространстве состояний, состоящей из элементов (подсистем), соединенных между собой типовым образом – параллельно, последовательно или с помощью обратной связи. Иногда требуется иметь единое уравнение в качестве математической модели некоторой объединенной системы, т.е. описание нескольких независимых систем. Объединение независимых систем. Рассмотрим простой случай, когда некоторая объединенная система S состоит из независимых систем Si, i=1, 2, описываемых уравнениями dxi (t ) = Ai xi (t ) + Bi ui (t ), (2.70) dt yi (t ) = Ci xi (t ), где матрицы Ai, Bi, Ci имеют соответственно размеры (ni x ni), (ni x ni), (li x mi). Введем в рассмотрение составные (обобщенные) векторы: для переменных состояния системы x(t) = col{x1(t), x2(t)}∈ R n1 + n2 , для переменных входа и(t) = col{и1(t), и2(t)}∈ R m1 + m2 , переменных выхода у(t) = col{у1(t), 2
В теории матриц комплексный аргумент передаточной функции принято обозначать через λ, для удобства будем его обозначать, как и в скалярном случае, через s. 40
у2(t)}∈ R l1 + l 2 . Графический образ объединения систем Si в одну показан на рис. 2.13, математическое описание которого представляет собой систему уравнений Рис. 2.13. Модель объединения независимых систем (2.70).
dx(t ) = Ax(t ) + Bu (t ), dt y (t ) = Cx(t ),
(2.71)
где блочные матрицы А, B, С имеют следующую структуру: A A = 1 0
0 B , B = 1 A2 0
0 0 C , C = 1 . B2 C 0 2
Параллельное соединение систем (подсистем). Принципиальное отличие параллельного соединения двух подсистем от объединения двух независимых систем состоит в том, что при параллельном соединении вход и(t) = и1(t) = и2(t) поступает на обе подсистемы одновременно, а выход этого соединения образуется как сумма у(t) = у1(t) + у2(t) (рис. 2.14). Вектор состояния x(t) остается по-прежнему составным и имеет вид x(t) = col{x1(t), x2(t)}∈ R n1 + n2 . Математическое описание сисРис. 2.14. Модель параллельного темы S, образованной параллельным сосоединения двух систем. единением нескольких систем Si, имеет попрежнему вид (2.71), где матрицы А, B, С также блочные, вида A A = 1 0
0 B , B = 1 , C = (C1 C2 ). A2 B2 Последовательное соединение подсистем, (рис. 2.15), где входом системы S является вход подсистемы S1, и(t) = и1(t), а выход системы S формиРис. 2.15. Последовательное руется выходом второй подсистемы S2, соединение двух подсистем. у(t) = у2(t). При этом выход первой подсистемы является входом второй, и2(t) = у1(t), поскольку их размерности совпадают. Описывая систему, представленную на рис. 2.15 уравнениями (2.71), получаем следующие блочные матрицы: 41
A A = 1 B2C1
0 B , B = 1 , C = (0 C2 ). A2 0
Соединение подсистем с обратной связью, (рис. 2.16), где выход подсистемы S2 вычитается (при положительной обратной связи прибавляется) из входа всей системы S и поступает на вход подсистемы S1. Другими словами, и1(t) = и(t) – у2(t), и2(t) = у1(t), что позволяет в математическом опиРис. 2.16. Соединение подсистем сании (2.71) для системы, показанной на c обратной связью. рис. 2.16, получить блочные матрицы вида − B1C2 A B , B = 1 , C = (C1 0). A = 1 A2 0 B2C1
2.3. Дискретизация непрерывных моделей 2.3.1. Решение уравнений состояния Пусть исследуемая система линейна и не содержит нестационарных элементов, т.е. уравнения динамики имеют вид dx(t ) = Ax(t ) + Bu (t ), dt y (t ) = Cx (t ) + Du (t ),
(2.72) (2.73)
где x(t)∈Rn; u(t)∈Rm; y(t)∈Rl. Очевидно, что если функция x(t) определена, то выход y(t) вычисляется непосредственно из (2.73). Рассмотрим решение задачи Коши, т.е. определим вектор состояния x(t) при известном начальном значении х(0) и заданном входном процессе и(t). Решение однородного уравнения dx(t ) = Ax(t ) dt
(2.74)
для всех действительных t0, при выполнении равенства dФ(t , t0 ) = AФ(t , t0 ), Ф(t0 , t0 ) = E , dt 42
(2.75)
где x(t)∈Rn; Ф(t, t0) = X(t)Х-1(t0) – переходная матрица состояния; X(t) – фундаментальная матрица-функция, можно представить в виде x(t ) = Ф(t , t0 ) x(t0 ). (2.76) Для того, чтобы воспользоваться выражением (2.76), необходимо уметь вычислять матрицу Ф(t, t0). Известно, что поскольку уравнение (2.74) стационарное, то матрица Ф(t, t0) зависит от одного аргумента θ и совпадает с матричной экспонентой Ф(t, t0) = еАθ, θ = t – t0, которую можно определить в виде ряда e
Aθ
∞ ( Aθ ) k ( Aθ ) 2 ( Aθ ) k = E + Aθ + + ... + + ...+ = E + ∑ . 2 k! k =1 k!
(2.77)
Таким образом, решение уравнения (2.74) определяется формулой (2.78) x(t ) = e At x0 , где х0 = х(t0=0). Выражение (2.78) имеет наиболее простой вид тогда, когда матрица А = diag{s1, s2, …, sn}, поскольку матрица eAt также будет диагональной
{
e At = diag e s1t
e s2t
}
... e s n t .
Решение неоднородного уравнения (2.72) можно представить в виде x(t ) = xобщ (t ) + xчаст (t ), где xобщ(t) – переходная составляющая или общее решение однородного уравнения (2.74) при заданных начальных условиях; xчаст(t) – вынужденная составляющая или частное решение уравнения (2.72) при нулевых начальных условиях. Как известно, xобщ(t) имеет вид t
xобщ (t ) = ∫ Ф(t , ϑ ) Bu (ϑ )dϑ , t0
а xчаст(t) представляет собой выражение (2.76); следовательно, для x(t) можно записать следующую формулу Коши t
x (t ) = Ф(t , t0 ) x0 + ∫ Ф(t , ϑ ) Bu (ϑ )dϑ ,
(2.79)
t0
а для стационарных систем в силу Ф(t, t0) = еАθ, θ = t – t0 выражение (2.79) представить в виде
43
x(t ) = e
A(t − t 0 )
t
x0 + ∫ e A(t −ϑ ) Bu (ϑ )dϑ ,
(2.80)
t0
часто называемом переходным уравнением состояния. Свойства переходной матрицы. Перечислим основные свойства матрицы Ф(t, t0). 1. ∀t0 имеет место Ф(t0, t0) = E. 2. ∀t0, t1, t выполнено правило композиции Ф(t, t0) = Ф(t, t1)Ф(t1, t0). 3. 4. 5. 6.
det Ф(t, t0) ≠ 0 ∀t0, t. Ф(t, t0) = X(t)Х-1(t0) , где X(t) – любая фундаментальная матрица. (Ф(t, t0))-1 = Ф(t0, t) ∀t0, t. Справедливо уравнение dФ(t , t0 ) = A(t )Ф(t , t0 ), Ф(t0 , t0 ) = E. dt
7. Матрица ФT(t, t0) удовлетворяет сопряженному уравнению dФT (t0 , t ) = − AT (t )ФT (t , t0 ), Ф(t0 , t0 ) = E. dt
ет
8. Если det T ≠ 0, ФT(t, t0) = Т-1 Ф T(t, t0)Т, где Ф (t, t0) удовлетворя-
(2.75), в котором вместо матрицы А подставлена подобная ей матрица A (t) = ТA(t)Т-1. 2.3.2. Дискретные модели непрерывных систем Постановка задачи дискретизации. Для динамической системы, непрерывная модель которой имеет вид dx(t ) = Ax(t ) + Bu (t ), y (t ) = Cx(t ) + Du (t ), t ∈ R, dt
(2.81)
требуется получить эквивалентную систему разностных уравнений или ее дискретную модель вида x[k + 1] = Px[k ] + Qu[k ], y[k ] = C x[k ] + Du[k ], k = 0,1,... . (2.82)
Здесь под эквивалентностью систем понимается совпадение их ре44
акций на одно и то же входное воздействие при соответствующих начальных условиях. Более того, при u[k] = u(tk), где tk = kT0, T0 = const – шаг дискретизации (период квантования), выполнено у[k] = у(tk) – решения уравнений (2.81) и (2.82) совпадают при tk = kT0. Формулы перехода к разностным уравнениям. Рассмотрим задачу определения матриц P, Q, C , D в (2.82) по известным матрицам А, B, C, D в (2.81), исходя из сформулированного выше требования эквивалентности систем по отношению к входному воздействию u(t). Для простоты изложения ограничимся рассмотрением кусочно-постоянного процесса вида u (t ) = u (t k ) при t k ≤ t < t k +1 , t k = kT0 , k = 0,1,2,... ,
достаточно распространенного на практике, который формируется так называемым фиксаторам или экстраполяторам нулевого порядка. Известно, что решение этой задачи с использованием аппарата передаточных функций и z-преобразования (дискретного преобразования Лапласа) позволяет передаточную функцию дискретной модели WD(z) записать следующим образом:
(
)
W ( s ) W ( z ) = 1 − z −1 Z , s
(2.83)
где Z означает операцию z-преобразования переходной функции исходной непрерывной системы. Для решения аналогичной задачи в рамках метода пространства состояний воспользуемся формулой Коши (2.80) и проинтегрируем первое уравнение из (2.81) на интервале [tk, tk+1], полагая на нем u(t)= u(tk). При х0 = х(tk) получим x(t k +1 ) = e
A(tk +1 − tk )
tk +1
x(t k ) + ∫ e A(tk +1 −υ ) Bu (υ )dυ = tk
tk +1 A(t −υ ) AT0 = e x(t k ) + ∫ e k +1 dυ Bu (t k ). t k
(2.84)
Если ввести новую переменную θ = tk+1 – υ, то, вычисляя интеграл в круглых скобках из соотношения (2.84), при tk+1 – tk = Т0 получим tk +1
∫e
tk
A(tk +1 −υ )
T0
dυ = ∫ e Aθ dθ = A −1 (e AT0 − E ) , 0
45
предполагая, что матрица А невырожденная. Следовательно, выражение (2.84) можно переписать в виде x(t k +1 ) = e AT0 x(t k ) + A−1 (e AT0 − E ) Bu (t k ), det A ≠ 0,
(2.85)
а уравнение выхода, согласно второму уравнению из (2.81), представить в виде y (t k ) = Cx(t k ) + Du (t k ).
(2.86)
Сопоставляя первое уравнение из (2.82) с уравнением (2.85) и второе уравнение из (2.82) с уравнением (2.86), получим очевидные соотношения P = e AT0 , Q = A−1 ( P − E ) B, C = C , D = D.
(2.87)
Когда выполнен переход от (2.81) к (2.82), то с учетом соотношений (2.87) можно записать уравнения x[k + 1] = e AT0 x[k ] + A−1 (e AT0 − E ) Bu[k ], det A ≠ 0, y[k ] = Cx[k ] + Du[k ], k = 0,1, ... ,
(2.88)
которые с помощью z-преобразования и преобразований, аналогичных соотношениям (2.67), (2.68), могут быть представлены следующим образом: y( z) = W ( z) u( z) =
(
= C zE − e AT0
(
= C ( zE − P )−1
)
( ) Q + D )u ( z ), det A ≠ 0. −1
A −1 e AT0 − E B + D u ( z ) =
(2.89)
Заметим, что передаточные функции в выражениях (2.83) и (2.89) идентичны, но получены различными способами. 2.3.3. Вычисление матричной экспоненты Методы вычисления матричной экспоненты eAt обычно подразделяют на точные и приближенные. Точные позволяют получить выражение для матричной экспоненты через скалярные аналитические функции, а приближенные – аппроксимировать ее с некоторой алгоритмической ошибкой, зависящей от способа аппроксимации и параметров алгоритма. Точные методы. Рассмотрим аналитические выражения для матричной функции eAt в следующих частных случаях: 46
1. Матрица А диагональная с вещественными собственными значениями. Пусть А = diag{s1, s2, …, sn}, Im si = 0, i = 1, …, n. Непосредственным вычислением суммы ряда (2.77) получаем
{
e At = diag e s1t
e s2t
}
... e s n t ,
где e sit – скалярные экспоненты. 2. Матрица А блочно-диагональная с мнимыми собственными значениями. Пусть А имеет собственные числа: s1,2 = α ± jβ, j2 = –1, тогда ее можно представить в виде α A= − β
β 0 α E = + α − β
β 0
,
а матричную экспоненту описать выражением e
At
=
0 αEt − β e e
β 0
t
.
Применяя формулу (2.77), можно показать, что это соотношение имеет вид cos βt sin βt e At = eαt . − sin β t cos β t 3. Матрица А имеет кратные вещественные собственные значения. Пусть si = 0, i = 1,2,3, т.е. матрица А нильпотентная 0 1 0 A = 0 0 1 , 0 0 0
вычисляя степени которой получаем, что 0 0 1 A2 = 0 0 0 , A3 = A4 = ... = 0. 0 0 0 Следовательно, ряд (2.77) точно выражается первыми тремя слагаемыми в виде
47
1 t 0.5t 2 e At = 0 1 t . 0 0 1 В случае отличных от нуля кратных вещественных собственных значений si = α, i = 1,2,3 аналогично предыдущему получаем e At
1 t 0.5t 2 = eαt 0 1 t . 0 0 1
Если матрица А имеет произвольный вид, то всегда существует невырожденное преобразование с матрицей Т такое, что подобная ей матрица A = ТАТ -1 – жорданова. Тогда по свойству 8 переходной матрицы (см. 2.3.1) получаем e At = T −1e At T .
Аналитические формулы для матричной экспоненты могут быть получены также на основе преобразования Лапласа. Этот способ основан на том, что резольвента R(s) постоянной матрицы А является изображением по Лапласу ее матричной экспоненты, т.е.
( )
L e At = (sE − A)−1 ,
причем элементы переходной матрицы можно найти с помощью таблиц обратного преобразования Лапласа. Приближенные методы. Эти методы основаны на различных аппроксимациях ряда (2.77) выражениями, содержащими конечное число слагаемых. Достаточно очевидной является аппроксимация Тейлора порядка k, согласно которой ряд (2.77) приближенно заменяется следующей конечной суммой: k ( Aθ ) i ( Aθ ) k ( Aθ ) 2 + ... + ≡E+∑ . (2.90) e ≈ E + Aθ + i ! k! 2 i =1 В частности, при k = 1 получаем линейное приближение вида Aθ
e Aθ ≈ E + Aθ , (2.91) которое будем называть аппроксимацией Эйлера. Аппроксимация (2.90) не является лучшей и во многих отношениях 48
уступает более общей аппроксимации Паде. При такой аппроксимации экспонента ех представляется рациональной функцией ex ≈
Fµν ( x) Gµν ( x)
(2.92)
,
µ µ (µ − 1) x+ x 2 + ... (µ + ν )1! (µ + ν )(µ + ν − 1) 2! µ (µ − 1) ⋅ ⋅ ⋅ 2 ⋅1 + xµ , (µ + ν )(µ + ν − 1) ⋅ ⋅ ⋅ (ν + 1)µ!
(2.93)
ν ν (ν − 1) x+ x 2 + ... (µ + ν )1! (µ + ν )(µ + ν − 1) 2! ν (ν − 1) ⋅ ⋅ ⋅ 2 ⋅1 xν . + (−1)ν (µ + ν )(µ + ν − 1) ⋅ ⋅ ⋅ (ν + 1)ν !
(2.94)
Fµν ( x) = 1 +
Gµν ( x) = 1 −
Соответственно, для матричного аргумента x = Aθ запишем −1 e Aθ ≈ Fµν ( Aθ )Gµν ( Aθ ),
(2.95)
где Fµν(Aθ), Gµν(Aθ) – матричные многочлены вида (2.93), (2.94). В дальнейшем (2.95) будем называть аппроксимацией Паде (µ,ν). Приведем некоторые частные случаи (2.95). Во-первых, аппроксимация Тейлора (2.90) – это частный случай (2.95) при ν = 0. Следовательно, выражение (2.91) совпадает с аппроксимацией Паде (1, 0). Аппроксимация Паде (0, 1) имеет вид e Aθ ≈ (E − Aθ )−1
(2.96)
и далее будет называться неявным методом Эйлера. Аппроксимация Паде (1, 1) соответствует методу Тастина и определяется формулой e Aθ ≈ (E + 0.5 Aθ )(E − 0.5 Aθ )−1.
(2.97)
Формула Паде (2, 2) приводит к выражению
(
)(
e Aθ ≈ 12 E + 6 Aθ + ( Aθ ) 2 12 E − 6 Aθ + ( Aθ ) 2
)
−1
.
(2.98)
Основным преимуществом аппроксимаций Паде является их более высокая точность, а недостатком – необходимость обращения матрицы 49
Gµν(Aθ) и связанная с этим проблема ее вырожденности. 2.3.4. Вычисление матрицы Q Как уже отмечалось, формула (2.87) для вычисления матрицы Q применима, если det A ≠ 0. Трудностей, связанных с вычислением Q при вырожденной матрице А, можно избежать, если при формальной подстановке выражения P = e AT0 , полученного из аппроксимаций Тейлора (2.90) или Паде (2.95), в соотношении (2.87) выполнить "сокращение" матрицы А. Тогда в выражение для Q матрица А-1 входить не будет. В частности, аппроксимация по методу Эйлера (2.87), (2.91) Р = Е + АТ0 приводит к формуле Q = ВТ0, а аппроксимация Паде (1, 1) (2.87), (2.97) – к формуле Q = (Е – 0.5АТ0)-1ВТ0. Иной способ заключается в расширении пространства состояний исходной системы (2.81). Входной процесс и(t) при tk ≤ t < tk+1 рассматривается как решение некоторого однородного дифференциального уравнения. Тогда расширенная система тоже однородная и в вычислении по (2.87) нет необходимости. Искомые матрицы Р и Q получаются как подматрицы расширенной "матричной" экспоненты. Покажем это на примере ступенчатого входного процесса и(t) = и(tk) при tk ≤ t < tk+1. Для указанного промежутка времени уравнение состояния (2.81) запишем в виде dx(t ) = Ax(t ) + Bu (t ), x(t k ) = x[k ], t k ≤ t < t k +1 , dt du (t ) = 0, u (t k ) = u[k ]. dt
(2.99)
Введем в рассмотрение расширенный (n + m)-мерный вектор состояния x(t ) = col{x(t ), u (t )} и (n + m)х(n + m) матрицу A A= 0 nxm
B . 0 mxm
Уравнение (2.99) запишем в виде d x(t ) = A x(t ), x(t k ) = col{x[k ], u[k ]}, t k ≤ t < t k +1. dt
(2.100)
Соответствующая дискретная модель, аналог (2.82), принимает вид x[k + 1] = P x[k ], P = e AT0 .
(2.101) 50
Учитывая структуру матрицы A и формулу (2.77), для матрицы P непосредственно находим P ' Q' P= . E 0 С учетом этого из (2.101) получаем: x[k + 1] = P ' x[k ] + Q' u[k ].
(2.102)
Сравнивая (2.102) с (2.82), имеем очевидный факт – матрицы Р и Q в (2.82) совпадают с матрицами Р' и Q'. Другими словами, они могут быть получены как соответствующие подматрицы матрицы P вида (2.101). 2.3.5. Вычисление передаточной функции дискретной модели Уже отмечалось, что уравнение (2.89) описывает дискретную систему с помощью передаточной функции, вычисленной по разностному уравнению (2.82), исходя из преобразования уравнений состояния непрерывной системы (2.81). Однако можно получить и приближенное решение задачи, при котором искомая функция W(z) определяется непосредственной заменой аргумента s в W(s). Эти формулы основаны на "линейных" аппроксимациях Паде (µ, ν), в которых значения µ и ν не превышают единицы. Для формулы аппроксимации Эйлера (2.91) в (2.89) следует подставить Р = Е + АТ0 и, как показано в п. 2.3.4, учесть Q = ВТ0. Таким образом, получаем W ( z ) = C ( zE − P )−1 Q = C (( z − 1) E − AT0 )−1 BT0 = −1
(2.103)
z −1 = C − A B. T0
Теперь при сравнении выражения (2.103) с формулой W(s) = C(sE – A) B становится вполне очевидным, что W(z) можно получить приближенно из W(s) с помощью следующей замены аргумента: -1
W ( z ) = W ( s)
s=
z −1 . T0
(2.104)
Для формулы неявного метода Эйлера (2.96), аналогичным образом получаем 51
1 W ( z ) = W ( s ) z −1 . s= z zT
(2.105)
0
Для формулы с аппроксимацией Паде (1, 1) после некоторых преобразований получаем подстановку метода Тастина W ( z) =
2 W (s) 2 s= z +1 T
0
z −1 . z +1
(2.106)
Точность приведенных методов зависит от соотношения между интервалом Т0 и наименьшей постоянной времени непрерывной системы W(s). 2.3.6. Устойчивость дискретных моделей Процедура построения дискретных моделей непрерывных систем всегда сопровождается требованием о сохранении свойства устойчивости: устойчивая непрерывная система должна приводить к устойчивой дискретной модели, а в случае неустойчивой исходной системы ее дискретная модель тоже должна получиться неустойчивой. Для точных методов перехода это требование выполнено, а для приближенных не всегда. Точный подход. Как известно, асимптотическая устойчивость линейных непрерывных систем имеет место, если корни характеристического многочлена (собственные числа) матрицы А в (2.81) имеют отрицательные вещественные части, т.е. Re si < 0 при det(siE – A) = 0, i =1,…, n. При этом дискретная система (2.82) будет асимптотически устойчивой, если корни ее характеристического многочлена удовлетворяют условию zi < 1 при det(ziE – P) = 0, i =1,…, n. Известно следующее утверждение: согласно точной формуле (2.87) P = e AT0 , следовательно, во-первых, собственные числа zi матрицы Р определяются соотношением zi = e siT0 , i =1,…, n, во-вторых, при всех Т0 > 0 выполнено {Re si < 0 ⇔ zi < 1}, в-третьих, свойства устойчивости систем (2.81) и (2.82) эквивалентны. Метод Эйлера. Согласно этому методу по (2.91) получаем равенство 52
Р = Е + АТ0. Следовательно, zi = 1+ siТ0, i =1,…, n. Проверка условия устойчивости zi < 1 приводит к следующим неравенствам:
(α i + 1)2 + β i2 < 1, α i = T0 Re si , β i = T0 Im si ,
i = 1,..., n.
(2.107)
Условие (2.107) означает, что значения корней характеристического многочлена системы, умноженные на интервал квантования, должны находиться на комплексной плоскости внутри круга единичного радиуса с центром в точке (–1, j0). Это эквивалентно неравенству T0 = 2 min i
Re si si2
(2.108)
.
Область применения явного метода Эйлера существенно ограничивается малыми (относительно модулей собственных чисел системы) значениями Т0. Неявный метод Эйлера. Согласно формуле (2.96) Р = (Е – Аθ)-1 имеем 1 zi = , i = 1,..., n, 1 − siT0 следовательно, условие zi < 1 приводит к неравенствам
(α i − 1)2 + β i2 > 1, α i = T0 Re si , β i = T0 Im si ,
i = 1,..., n.
(2.109)
Условие (2.109) означает, что корни характеристического многочлена системы, умноженные на интервал квантования, должны находиться на комплексной плоскости вне окружности единичного радиуса с центром в точке (1, j0). Из этого следует, что при такой аппроксимации для любой устойчивой непрерывной системы будет получена устойчивая дискретная модель при всех (а не только малых) Т0 > 0. Следует отметить, что свойства устойчивости непрерывных и дискретных моделей не будут эквивалентными: устойчивые дискретные модели могут получиться и для неустойчивых исходных непрерывных систем. Точность аппроксимации по этому методу невелика. Аппроксимация Паде при ν = µ. Можно показать, что для аппроксимаций Паде (ν , µ) при ν = µ, Т0 > 0 справедливо {Re si < 0 ⇔ zi < 1}. Таким образом, при их использовании устойчивость системы (2.81) эквивалентна устойчивости системы (2.82). В частности, это свойство выпол53
нено для рассмотренных выше аппроксимаций (2.97) и (2.98). Устойчивость методов численного интегрирования. Можно установить тесную связь между рассмотренными методами построения дискретных моделей непрерывных систем и методами численного решения задач Коши. Пусть требуется проинтегрировать уравнение dx(t ) = f ( x, t ), x(0) = x0 , t ≥ 0. (2.110) dt Известно, что его решение может быть получено в виде некоторого рекуррентного соотношения xk+1 = ϕ(xk, k), где k = 0, 1, 2, … – номер шага (итерации), а значения xk соответствуют значениям искомой функции x(t) в дискретные моменты времени tk = kh, где h > 0 – шаг интегрирования. Вид функции ϕ(xk, k) определяется по искомой функции f(x, t) согласно выбранному методу численного интегрирования. Например, используя метод Эйлера, получаем хорошо известную формулу xk +1 = xk + f ( xk , t k )h, tk = k ⋅ h, k = 0,1,2,... .
(2.111)
Более подробно рассмотрим случай, когда функция f(x, t) линейна по x и уравнение (2.110) может быть представлено в виде dx(t ) = Ax + φ (t ), (2.112) dt где А – nxn-матрица. Формула метода Эйлера (2.111) приводит к разностному уравнению xk +1 = (E + Ah )xk + φ (t k )h .
(2.113)
Обратим внимание на то, что уравнение (2.113) с точностью до обозначений совпадает с уравнением (2.82), в котором матрицы P, Q получены на основе приближенной формулы (2.91) для матричной экспоненты. Устойчивость полученной численной процедуры определяется приведенными в п. 2.3.1 свойствами данной аппроксимации: так, для А и Т0 = h должно выполняться неравенство (2.107). Следовательно, если собственные числа системы велики по модулю (что соответствует малым по величине постоянным времени), то для получения устойчивого решения необходимо выбирать шаг интегрирования h достаточно малым. Это приводит к значительным затратам машинного времени, а также надо иметь в виду, что уменьшение величины h вызывает увеличение инструментальных ошибок, связанных с конечностью разрядной сетки ЦВМ. 54
Подобным свойством обладают все так называемые явные методы численного интегрирования, которые для линейных стационарных систем сводятся к аппроксимации Тейлора (2.90). Отметим, что недостатки явных методов заметно проявляют себя при решении жестких систем, у которых собственные значения отличаются друг от друга по модулю на несколько порядков.
55
3. МОДЕЛИ И ХАРАКТЕРИСТИКИ ЭЛЕМЕНТАРНЫХ ДИНАМИЧЕСКИХ ЗВЕНЬЕВ
Структурную схему любой линейной системы, как правило, можно представить в виде соединения элементарных динамических звеньев, порядок дифференциальных уравнений которых будет не выше второго порядка. Общепринято каждое из таких звеньев включать в состав одной из трех групп – позиционных, интегрирующих или дифференцирующих звеньев. Классификационным признаком, позволяющим отнести звено к соответствующей группе является его уравнение, описывающее поведение звена в статике, т.е. в установившемся режиме. 3.1. Группа позиционных звеньев В группу позиционных звеньев обычно включаются безынерционное, инерционные 1-го и 2-го порядков, колебательное. Все эти звенья в установившемся режиме описываются одинаковым уравнением вида (3.1) x(t ) = ku (t ), k = const . 3.1.1. Безынерционное звено Это звено часто называют статическим, усилительным, масштабным, пропорциональным и описывают уравнением вида (3.1). Примеры безынерционного звена даны на рис. 3.1, где изображены: а) редуктор; b) делитель напряжения; c) электронный усилитель. Согласно уравнению (3.1) передаточная функция имеет вид (3.2) W (s) = k. Переходной процесс описывается уравнением (3.3) h(t ) = k1(t ) , а импульсная переходная характеристика уравнением вида (3.4) ω (t ) = kδ (t ) . 56
Рис. 3.1.
График функции h(t), построенный при значении коэффициента передачи k = 3 и согласно выражению (3.3), показан на рис. 3.2. График же функции ω(t) вида (3.4) не имеет строгой физической интерпретации и его реализация может быть лишь приближенной, в частности – в виде прямоугольного сигнала с большой амплитудой и малым интервалом времени, причем площадь такого сигнала, согласно Рис. 3.2. уравнению (3.4), должна быть равной k. Частотная передаточная функция описывается уравнением (3.5) W ( jω ) = k , годограф которой (точка на плоскости) изображен на рис. 3.3.
Рис. 3.3.
Представив частотную передаточную функцию вида (3.5) как комплексное выражение, представленное соответственно в полярных и прямоугольных координатах, получим частотные характеристики: амплитудную (3.6) mod(W ( jω )) = A(ω ) = k ; фазовую (3.7) arg(W ( jω )) = ϕ (ω ) = 0 ; вещественную (3.8) Re(W ( jω )) = U (ω ) = k ; мнимую (3.9) Im(W ( jω )) = V (ω ) = 0 . 57
Графики частотных характеристик (3.6) – (3.9) безынерционного звена со значением коэффициента k = 3 показаны на рис. 3.4.
Рис. 3.4.
1.1.2. Инерционное звено 1-го порядка Звено также называют апериодическим 1-го порядка и описывают уравнением вида dx T + x = ku , T [c], k = const > 0. (3.10) dt В частности, известно, что дифференциальное уравнение движения электродвигателя, при отсутствии момента нагрузки на валу, можно описать уравнением M dυ (3.11) J = KмE − 0 υ , υ0 dt где υ – скорость вращения; M0 – пусковой момент; J – суммарный момент инерции, приведенный к валу двигателя; υ0 – скорость вращения холостого хода; E – управляющее воздействие; KM – коэффициент пропорциональности между вращающим моментом и управляющим воздействием; dυ J – вращающий момент. dt Если уравнение (3.11) представить в первой форме записи Kυ υ dυ J 0 +ν = м 0 E , M 0 dt M0 то используя новые обозначения: 58
∆ Jυ 0 K υ , k= M 0, M0 M0 получим уравнение, вид которого будет в точности совпадать с уравнением (3.10). Примеры инерционного звена 1-го приведены на рис. 3.5, где изображены: a) резервуар с газом (ресивер); b) электрический двигатель; c) RC – цепочка; d) тепловой объект; e) резервуар с жидкостью. ∆
∆
∆
x =υ , u = E , T =
Рис. 3.5.
Передаточная функция звена имеет вид x( s) k W (s) = = . u ( s) Ts + 1
(3.12)
Поскольку для характеристического уравнения Ts + 1 = 0 , корень определяется соотношением 1 s1 = − , T то уравнение связи вход-выход, согласно (3.12), будет следующим: x( s ) =
k /T u ( s) , s − s1
которое, для входного сигнала u(t) = 1(t) и его изображения ∞ 1 u ( s ) = ∫ 1(t )e −st dt = , 0 s перепишется в виде
59
k /T . (3.13) s ( s − s1 ) Теперь, используя таблицу обратных преобразований Лапласа, легко найти решение уравнения (3.10), в частности – переходной процесс определится соотношением t − k /T −1 T (3.14) h(t ) = L = k (1 − e ) , − s ( s s ) 1 из которого, в результате дифференцирования функции h(t) получается уравнение импульсной переходной характеристики dh(t ) k −Tt (3.15) ω (t ) = = e . T dt Графики временных характеристик инерционного звена 1-го порядка, построенные для значений коэффициента передачи k = 5 и постоянной времени Т = 2 (с), представлены на рис. 3.6. x( s ) =
Рис. 3.6.
Из уравнения (3.12) следует, что частотная передаточная функция инерционного звена 1-го порядка имеет вид k W ( jω ) = , (3.16) 1 + jωT годограф которой со значениями k = 5 и Т = 2 изображен на рис. 3.7. Частотную передаточную функцию (3.16) можно описать как в полярных координат с помощью выражений k A(ω ) = , ϕ (ω ) = − arctgωT , (3.17) 1 + ω 2T 2 так и в прямоугольных координатах, используя соотношения k − ωkT , ( ) U (ω ) = V ω = . (3.18) 1 + ω 2T 2 1 + ω 2T 2 Графики частотных характеристик (3.17), (3.18), построенные при значениях k = 5 и Т = 2, представлены на рис. 3.8. 60
Рис. 3.7.
Рис. 3.8. 3.1.3. Инерционное звено 2-го порядка Инерционное или апериодическое звено 2-го порядка описывают уравнением 2 dx 2 d x 2 2 T1 T + + x = ku , T > 4T , (3.19) 2 2 1 dt 2 dt где положительные числа k – коэффициент передачи; T12, T2 – постоянные времени. Часто вместо T12 пишут просто T1, что означает лишь изменение обозначения, но сохранение размерности, т.е. здесь T1 в [сек]2. Уравнению (3.19) соответствует передаточная функция k . (3.20) W ( s) = 2 2 T1 s + T2 s + 1 Поскольку при T22 >4T12 корни характеристического уравнения 2 T1 s 2 + T2 s + 1 = 0 61
всегда будут вещественными, то передаточную функцию (3.20) удобно записывать следующим образом: k , (3.21) W (s) = (T3 s + 1)(T4 s + 1) т.е. рассматривая новые постоянные времени ∆ T T = T 2 , 3 4 1 ∆ T3 + T4 = T2 . В качестве примера математического описания инерционного звена 2-го порядка рассмотрим уравнения электродвигателя постоянного тока с независимым возбуждением, схема которого изображена на рис. 3.5b. Известно, что с учетом электромагнитной реакции цепи якоря, но при отсутствии момента нагрузки на валу двигателя, динамику последнего описывают двумя уравнениями: во-первых – уравнением равновесия ЭДС в якорной цепи di L + Ri = uвх − K Eυ , (3.22) dt где L, R – соответственно индуктивность и активное сопротивление якорной цепи, а KE – коэффициент пропорциональности между обратной ЭДС и скоростью вращения двигателя υ; во-вторых – уравнением равновесия моментов на валу двигателя dν J = K мi , (3.23) dt где KМ – коэффициент пропорциональности между вращающим моментом и током якоря i. Исключив в уравнениях (3.22), (3.23) промежуточную переменную i, можно записать следующее уравнение движения электродвигателя LJ d 2υ RJ dυ + + K Eυ = uвх , K м dt 2 K м dt которому в первой форме записи будет соответствовать выражение L RJ d 2υ RJ dυ 1 (3.24) + + υ = uвх . R K м K E dt 2 K м K E dt KE Если ввести обозначения ∆ ∆ ∆ L RJ 1 k= , TM = , TЯ = , x = υ, u = uвх, R KE KмKE где ТМ – электромеханическая постоянная времени двигателя, а ТЯ – ее электромагнитная постоянная, то уравнение (3.24) получит вид 62
d 2x dx TM TЯ 2 + TM + x = ku . (3.25) dt dt Уравнение (4.24) будет полностью эквивалентно уравнению (3.12) только при выполнении дополнительного коэффициентного соотношения
Tм − 4TмTя > 0 или Tм > 4Tя > 0 . (3.26) Другие примеры инерционного 2-го звена показаны на рис. 3.9, где каждое представляет собой последовательное соединение двух инерционных звеньев 1-го порядка (см. рис. 3.5). 2
Рис. 3.9.
Поскольку у передаточной функции вида (3.21) корни характеристического уравнения имеют вещественные значения 1 1 s1 = − , s2 = − , T4 T3 то переходной процесс будет описываться следующим образом: k / T3T4 h(t ) = L−1 = s ( s − s1 )( s − s2 ) (3.27) t t − − T4 T3 e T , = k 1 − eT + T3 − T4 T3 − T4 а импульсной переходной характеристике будет соответствовать уравнение t − k −Tt T ω (t ) = (3.28) e − e . T3 − T4 Графики временных характеристик инерционного звена 2-порядка со значениями коэффициентов 3
3
4
4
63
k = 5, T3 = 1, T4= 3, представлены на рис. 3.10.
(3.29)
Рис. 3.10.
Частотная передаточная функция, получаемая из (3.21), имеет вид k . (3.30) W ( jω ) = (1 + jωT3 )(1 + jωT4 ) Годограф функции (3.30) со значениями (3.29) показан на рис. 3.11.
Рис. 3.11.
Амплитудная и фазовая частотные характеристики, как следует из соотношения (3.30), описываются соотношениями k , A(ω ) = 2 2 2 2 (1 + ω T3 )(1 + ω T4 ) (3.31)
ϕ (ω ) = −arctgωT3 − arctgωT4 , а вещественная и мнимая частотные характеристики, также получаемые из (3.30), имеют вид 1 − ω 2T3T4 U (ω ) = 2 , 2 (1 + ω 2T3 )(1 + ω 2T4 ) (3.32) − ω (T3 + T4 ) V (ω ) = 2 . 2 (1 + ω 2T3 )(1 + ω 2T4 ) 4
Графики частотных характеристик (3.31), (3.32) со значениями коэффициентов (3.29), приведены на рис. 3.12. 64
Рис. 4.12.
3.1.4. Колебательное звено Как и апериодическое звено 2-го порядка, колебательное также описывается дифференциальным уравнением вида (3.19), но при этом указанное в (3.19) неравенство заменяется на противоположное, т.е. получает вид 2 2 T2 < 4T1 . (3.33) Очевидно, что при этом оба корни характеристического уравнения передаточной функции (3.20) оказываются комплексно-сопряженными. В этом случае передаточную функцию (3.20) удобно записывать следующим образом: k , (3.34) W (s) = 2 2 T s + 2ξTs + 1 т.е. рассматривая новые коэффициенты, определяемые из соотношений ∆ T 2 = T 2 , 1 ∆ 2ξT = T2 , где ξ – коэффициент затухания 0 ≤ ξ < 1; T – постоянная времени, удовлетворяющая соотношению q = T-1, здесь q – угловая частота свободных колебаний при отсутствии затухания, т.е. при ξ = 0. Примером конкретного математического описания колебательного звена может служить уравнение двигателя постоянного тока с независимым возбуждением вида (3.25), но только в том случае, когда его пара65
метры удовлетворяют неравенству Tм − 4TмTя < 0 . Примеры колебательного звена представлены на рис. 3.13: а) центробежный маятник; b) механическая система; с) RLC-цепочка. 2
Рис. 3.13.
Если определить корни характеристического уравнения T 2 s 2 + 2ξTs + 1 = 0 и записать их в виде − 2ξT ± 4ξ 2T 2 − 4T 2 ξ 1 2 ξ − 1 ξ <1 = = − ± s1, 2 = 2T 2 T T ξ 1 (3.35) =− ± j 1 − ξ 2 = −γ ± jλ , T T ∆ ∆ ξ 1 γ = = ξq, λ = 1 − ξ 2 = q 1 − ξ 2 , T T то из двух последних уравнений можно установить зависимость коэффициентов T, ξ (или q, ξ) от параметров γ и λ, в виде следующих функций: 1 1 γ γ , ξ= = 2 , T= = 2 2 q q λ +γ λ +γ 2 Переходной процесс и импульсная переходная характеристика колебательного звена описываются соотношениями k /T 2 γ −1 h(t ) = L = k 1 − e −γt sin(λt + ϕ ) = ξλ s ( s − s1 )( s − s2 ) (3.36) ∆ γ λ = k 1 − e −γt (cos λt + sin λt ), ϕ = arctg , λ γ 2
66
ω (t ) =
k (γ 2 + λ2 )
λ
e sin λt = −γt
kq 2
λ
e sin λt = −γt
kγ 2
λξ
2
e −γt sin λt , (3.37)
а их графики, построенные при значении коэффициентов k = 10, T = 1.5, ξ = 0.3, показаны на рис. 3.14.
Рис. 3.14.
Частотная передаточная функция, согласно уравнению (3.34), описывается выражением вида k W ( jω ) = (3.38) 2 2 (1 − T ω ) + j 2ξωT а частотные характеристики следующим образом: k , (3.39) A(ω ) = 2 2 2 2 2 2 (1 − T ω ) + 4ξ ω T 2ξωT 1 − T 2ω 2 k (1 − T 2ω 2 ) U (ω ) = , (1 − T 2ω 2 )2 + 4ξ 2ω 2T 2
ϕ (ω ) = −arctg
V (ω ) =
(3.40) (3.41)
− 2kξωT . (1 − T 2ω 2 )2 + 4ξ 2ω 2T 2
(3.42)
Известно, что в колебательном звене может появиться резонанс, когда в некотором частотном диапазоне текущее значение амплитуды превышает величину А(0), а при резонансной частоте ωрез достигает своего максимума, т.е. А(ωрез) = max А(ω). Определить величину ωрез можно, например, используя необходимое условие экстремума функции ∂A(ω ) − 2kT 2ω (− 1 + T 2ω + 2ξ 2 ) == = 0. 2 2 2 2 2 2 3 ∂ω ((1 − T ω ) + 4ξ T ω ) Поскольку при ω = 0 резонанса быть не может, то величину ωрез находят 1 1 − 2ξ 2 = q 1 − 2ξ 2 , где из условия − 1 + T 2ω 2 + 2ξ 2 = 0 , в виде ω рез = T 67
рассматриваются лишь вещественные значения ωрез, удовлетворяющие неравенству 1 − 2ξ 2 > 0 , при этом коэффициентное соотношение ξ < 0.707 – это условие наличия резонанса. Годографы частотной передаточной функции, построенные со значениями коэффициентов k = 10, T = 1.5, при ξ = 0.3 и ξ = 0.5, показаны на рис. 3.15, а графики частотных характеристик – на рис. 3.16.
Рис. 3.15.
Рис. 3.16.
3.2. Группа интегрирующих звеньев К этой группе звеньев обычно относят интегрирующее звено и интегрирующее звено с замедлением. Эти звенья в установившемся режиме описываются одним и тем же уравнением t
x(t ) = k ∫ u (t ) dt , k = const .
(3.43)
0
3.2.1. Интегрирующее звено Звено иногда называют идеально интегрирующим, тем самым подчеркивая, что для любого момента времени его математической моделью 68
является уравнение (3.43), которое можно переписать и в дифференциальной форме 1 dx dx (3.44) = ku или T = u , где T = (с) . dt dt k Примеры физической реализации интегрирующего звена показаны на рис. 3.17: а) интегратор на операционном усилителе; b) гидравлический демпфер, динамика которого (без учета инерции) описывается соотdx p ношением ν = , где Ks – коэффициент скоростного сопротивле= dt K s ния.
Рис. 3.17.
В соответствии с уравнениями (3.44), передаточная функция интегрирующего звена имеет вид 1 k (3.45) W (s) = = , Ts s следовательно, переходной процесс и импульсная переходная характеристики описываются соотношениями k h(t ) = L−1 2 = kt , (3.46) s dh(t ) ω (t ) = (3.47) = k. dt Графики временные характеристик интегрирующего звена, построенные при значении параметра k = 6, изображены на рис. 3.18.
Рис. 3.18.
Частотная передаточная функция и частотные характеристики име69
ют вид W ( jω ) = A(ω ) =
1 , j ωT
(3.48)
1 , ωT
(3.49)
π ϕ (ω ) = − ,
(3.50) 2 U (ω ) = 0, (3.51) 1 V (ω ) = − , (3.52) ωT графики которых, построенные при значении параметра Т = 1/6, показаны на рис. 3.19
Рис. 3.19
3.2.2. Интегрирующее звено с замедлением Звено описывается уравнением 70
d 2 x dx (3.53) T 2 + = ku , dt dt где k (с-1) – коэффициент передачи; T (с) – постоянная времени. Примером интегрирующего звена с замедлением может служить двигатель постоянного тока (см. рис. 3.5) с математическим описанием (4.11), (4.12), т.е. без учета электромагнитной реакции якорной цепи, но в случае когда выходной величиной является не скорость, а угол поворота вала электродвигателя. Передаточная функция и корни характеристического уравнения определяются соотношениями 1 k , s1 = 0 , s2 = − , (3.54) W ( s) = s (Ts + 1) T что позволяет переходной процесс и импульсную переходную характеристику описать следующими уравнениями: t − k −1 T h(t ) = L 2 (3.55) = k t − T (1 − e ) , s ( Ts 1 ) + −
t
ω (t ) = k (1 − e T ) .
(3.56) Временные характеристики интегрирующего звена с замедлением, построенные при значении коэффициентов k = 5, T = 2 (с), приведены на рис. 3.20.
Рис. 3.20.
Частотная передаточная функция и частотные характеристики описываются уравнениями k W ( jω ) = , (3.57) jω (1 + jωT ) k A(ω ) = , (3.58) ω (1 + ω 2T 2 )
ϕ (ω ) = −
π
2
− arctgωT ,
(3.59) 71
U (ω ) =
− kT , 1 + ω 2T 2
(3.60)
−k , (3.61) ω (1 + ω 2T 2 ) графики этих функций, построенные при значении коэффициентов k = 5, T = 2 (с), изображены на рис. 3.21. V (ω ) =
Рис. 3.21.
3.3. Группа дифференцирующих звеньев В состав этой группы звеньев обычно входят идеальное дифференцирующее и реально дифференцирующее звенья, описываемые в установившемся режиме уравнением du (t ) (3.62) , k = const , k (c). x (t ) = k dt 72
3.3.1. Идеальное дифференцирующее звено Идеальное дифференцирующее звено, в любой момент времени должно описываться уравнением вида (3.62), но в природе отсутствуют примеры данного звена, которые могли физически реализовать такую динамику. Действительно, если бы такое звено существовало, то оно должно было бы мгновенно вычислять значение производной (скорость изменения) входного сигнала, но именно это и невозможно, т.к. выполнить какую-либо работу за нулевой интервал времени – практически не реализуемая задача. Однако, если рассмотреть работу тахогенератора, то в установившемся режиме его функционирования оказывается, что выходное напряжение, индуцируемое в якорной цепи тахогенератора, строго пропорционально входной скорости вращения его вала u я (t ) = kωв (t ) = const . (3.63) Но входной сигнал можно представить как dα ωв (t ) = п , dt где αП – угол поворота, т.е. при этом получается уравнение dα (t ) u я (t ) = k п , dt которое с точностью до обозначения совпадает с выражением (3.62). Указанное совпадение имеет место только благодаря выполнению строго равенства (3.63), т.е. постоянной величине генерируемого напряжения тахогенератора при постоянной скорости его вращения, которое будет сразу потеряно, как только произойдет любое изменение величины скорости вращения. Уравнению (3.62) соответствует передаточная функция W ( s ) = ks . (3.64) Переходной процесс в идеальном дифференцирующем звене описывается уравнением h(t ) = kδ (t ) , (3.65) которое, также как и уравнение(3.4) не имеет строгой физической реализации. При этом теряет смысл Частотная передаточная функция и частотные характеристики описываются выражениями W ( jω ) = jωk , (3.66) A(ω ) = ωk , (3.67)
73
ϕ (ω ) =
π
, 2 U (ω ) = 0 , V (ω ) = ωk .
(3.68) (3.69) (3.70)
Изображения функций (3.66) – (3.70), простроенные при значении коэффициента k =1, представлены на рис. 3.22.
Рис. 3.22.
3.3.2. Реальное дифференцирующее звено Это звено описывается уравнением dx du T +x=k , (3.71) dt dt где постоянная времени Т и коэффициент передачи k имеют размерность в секундах. Примерами реального дифференцирующего звена, как это показано на рис. 3.23, могут служить, например: a) RC-цепочка; b) гидравлический демпфер с пружиной. 74
Передаточная функция этого звена имеет вид ks W ( s) = , (3.72) Ts + 1 согласно которому определив корень характеристического можно записать уравнения переходного процесса и импульсной переходной характеристики следующим образом: sk / T k −Tt −1 k / T = = L h(t ) = L−1 s − s T e , − s s s ( ) 1 1
(3.73)
k −Tt ω (t ) = − 2 e . T
(3.74)
Рис. 3.23.
Временные характеристики реального дифзвена, построенные при значении коэффициентов k = 4, T = 2, приведены на рис. 3.24.
Рис. 3.24.
Частотная передаточная функция и частотные характеристики реального дифференцирующего звена, имеют следующее математическое описание: jωk W ( jω ) = , (3.75) 1 + jωT ωk A(ω ) = , (3.76) 1 + ω 2T 2 75
ϕ (ω ) =
π 2
− arctgωT ,
(3.77)
ω 2 kT U (ω ) = , 1 + ω 2T 2 ωk V (ω ) = , 1 + ω 2T 2
(3.78) (3.75)
графики которых, построенные при значении коэффициентов k = 4, T = 2, изображены на рис. 3.25.
Рис. 3.25.
76
4. ПАКЕТ MATLAB
Выполнение всех заданий курсового практикума связано с использованием MatLab – высокоэффективного программного обеспечения для научных и инженерных расчетов. Выполняя математические расчеты в программной среде MatLab, пользователь имеет весьма комфортные возможности для решения различных вычислительных задач в областях линейной алгебры, общей теории систем, теории информации и обработки сигналов, теорий автоматического и автоматизированного управления и ряда иных дисциплин. Возможности среды MatLab достаточно гибкие и могут быть значительно расширены за счет использования дополнительного инструментария, так для MATLAB(r) for Windows (версия 4.0), кроме базового тулбокса Matlab, предусматривается возможность применения и следующих специализированных тулбоксов: − Signal Processing Toolbox "обработка сигналов"; − Optimization Toolbox "оптимизация"; − Neural Network Toolbox "нейронные сети"; − Control System Toolbox"системы управления" ; − SplineToolbox "сплайны"; − SIMULINK (Dynamic System Simulation Software) "программное обеспечение моделирования динамических систем". Привлекательной чертой среды MatLab является простота и легкость ее адаптации к прикладным задачам конкретного пользователя, который всегда может ввести в программную среду любую свою команду, оператор, функцию или создать собственный toolbox (ящик инструментов). В частности, для выполнения курсовой работы используются как типовые m-файлы, так и оригинальные, например КММ. Основная цель введения – характеристика программной среды MatLab и ознакомление пользователя с возможностями стандартного интерфейса MATLAB(r) for Windows (версии 4.0), поскольку выполнение курсовой работы осуществляется с использованием возможностей типовых тулбоксов – Matlab, Signal. 77
4.1. Рабочее место MATLAB(r) for Windows (версия 4.0) Непосредственная работа с программной средой Matlab начинается с момента появления на экране ее рабочего места. Для этого, как и обычно при взаимодействии с рабочим столом в режиме быстрого запуска приложений Windows95, Вам необходимо на столе или найти ярлык программной среды Matlab или выбрать кнопку Matlab панели Office (см. рис. 4.1).
Рис. 4.1.
Для вызова среды Matlab Вы перемещаете указатель мыши на кнопку Matlab панели Office и один раз нажимаете левую клавишу мыши. Если же для активизации рабочего места Matlab Вами используется ярлык, то перемещая указатель мыши в положение ярлыка Matlab, Вы должны дважды быстро нажать левую клавишу мыши. Если же на Вашем рабочем столе Windows для Matlab отсутствуют как ярлык, так и кнопка на офисной панели, то необходимо воспользоваться кнопкой Пуск, после нажатия которой Вам требуется последовательно переместить указатель мыши в следующие положения: Программы, Matlab for Windows, Matlab (рис. 4.2) и нажать один раз левую клавишу мыши.
Рис. 4.2. 78
При любом варианте вызова программной среды MatLab на экране появится изображение, показанное на рис. 4.3.
Рис. 4.3
Из рис. 4.3 следует, что Рабочее место MatLab представляет собой командное окно (MatLab Command Window), состоящее из: главного меню, с разделами – File, Edit, Options, Windows, Help; рабочей области, с информационным текстом и специальным знаком приглашения к работе ">>", после которого вводится, например, та или иная команда: demo, toau и т.п. Помимо указанного, рабочее место MatLab объединяет в своем составе команды главного и дополнительных меню, диалоговые окна. 4.2. Основные команды и параметры диалога MatLab 4.2.1. Раздел меню File
Рис. 4.4.
Если в строке главного меню рабочего места программной среды MatLab (командного окна), выбрать Имя "File", то переместившись в указанное положение и щелкнув один раз левой клавишей мыши, Вы распахнете Окно команд раздела меню, представленное на рис. 4.4. При этом становится доступным большинство команд меню File, а именно: New; Open M-file...; Save Workspace As...; Run M-file...; Print...; Print Setup...; Exit
MATLAB. Команда New. Ввод команды "New", этот случай как раз и отражен на рис. 4.4 (имеется ввиду расположение указателя мыши), позволяет 79
пользователю создавать новые m-файлы (M-file) или новые графические окна (Figure). Для создания нового m-файла необходимо выбрать и ввести команду – m-file. Результат действия этой команды представлен на рис. 4.5. При формировании нового графического окна необходимо воспользоваться командой – Figure, выполнение которой вызывает на экран окна с первым или очередным номером, один из вариантов показан на рис. 4.6.
Рис. 4.5.
Рис. 4.6.
Если Вам требуется написать некоторый новый текст и оформить его в виде m-файла, то для этого MatLab предоставляет пользователю стандартные возможности Windows. Действительно, изображение показанное на рис. 4.5, соответствует стандартному виду рабочего окна типовой программы "Блокнот". Поскольку меню программы "Блокнот" имеет собственный справочный раздел – "?", содержащий подробную русифицированную подсказку, то команды и параметры диалога программы "Блокнот" здесь не приведены, т.к. не требуют какой-либо дополнительной характеристики. Для работы с рисунками пользователь может сформировать графическое окно (см. рис. 4.6), которое имеет собственное меню команд, выполнение которых позволяет преобразовывать получаемые изображения, а также проводить ряд дополнительных преобразований и действий. В частности, можно получить графические копии в формате *.bmp (команда – Copy to Bitmap) или с расширением .met (команда – Copy to Metafile).Уместно заметить, что если тип расширения (*.bmp) является стандартным и широко применяемым в Windows, то расширение (*.met) таковым не является. Расширение (*.met) позволяет создавать специальные или метафайлы, которые используются так называемым графическим постпроцессором GPP – самостоятельной программой, расположенной вне оболочки среды MatLab. Для удобства визуального обзора всего перечня команд, входящих в состав меню графического окна, на рис. 4.7 изображен вариант "одновременно раскрытых" всех разделов меню окна Figure. Содержание любой команды графического окна Figure (см. рис. 4.7) 80
и цель ее выполнения, на наш взгляд, достаточно очевидны и непосредственно следуют из названия той или иной команды.
Рис. 4.7.
Команда Open M-file ... Если в меню раздела File (см. рис. 4.4) выбрать и ввести команду "Open M-file", то на экране появится диалоговое окно, показанное на рис. 4.8.
Рис. 4.8.
Рассматриваемый случай, как следует из анализа содержимого полей "Имя файла" и "Папки", дает представление только о составе mфайлов и папок, входящих в папку matlab – основную директорию MatLab. При этом для открытия и просмотра, а также внесения изменений и корректировок пользователю доступен любой m-файл из включённых в список поля "Имя файла". Для его открытия необходимо переместить указатель мыши на выбранный m-файл и дважды щелкнуть в этом положении левой клавишей мыши. Аналогично открывается и любой иной m-файл, но предварительно его необходимо выбрать в списке mфайлов, входящих в другие папки, характеристика состава которых будет приведена далее. Команда Save Workspace As... При выборе и вводе команды "Save Workspace As..." раздела File главного меню MatLab Command Window, 81
на экране появится окно для диалога, показанное на рис. 4.9, с помощью которого можно сохранить текущее состояние системы.
Рис. 4.9.
Альтернатива сохранения состояния текущих переменных в некотором файле заключается не столько в присвоении ему соответствующего имени, сколько в назначении файлу типа его расширения: .m или .mat. В последнем случае появляется возможность в каждом новом сеансе работы с MatLab загружать из Имя_файла.mat прежнее состояние системы, что достигается за счет применения оператора Load2. Команда Run M-file. Если в меню раздела File будет выбрана и введена команда "Run M-file", то на экране появится диалоговое окно, показанное на рис. 4.10.
Рис. 1.10.
Диалоговое окно позволяет пользователю с помощью кнопки Browse осуществить просмотр и выбор m-файла с последующим запуском выбранного файла в работу. Действительно, если нажать кнопку Browse, то для просмотра списков m-файлов на экран будет вызвано дополнительное диалоговое окно (см. рис. 4.11), используя которое пользователь (с помощью мыши) может выбрать нужную папку и требуемый m-файл. Например, если для просмотра Вы выбрали (см. рис. 4.11): в по82
ле "Папки" – папку Demos; в поле "Имя файла" – файл demo.m и нажали кнопку ОК, то в результате закроется окно Browse и откроется окно Run M-file (рис. 4.12), а при нажатии кнопки ОК выбранный файл запустится в работу.
Рис. 4.11.
Рис. 4.12.
Пожалуй, уместно обратить внимание на то, что для запуска в работу m-файла, в том числе и файла demo.m, можно было выбрать и более простой путь, т.е. в командном окне (см. рис. 4.3) после знака приглашения достаточно было ввести команду demo и нажать клавишу Enter, но этот путь хорош лишь тогда, когда Вы точно знаете имя интересующего Вас m-файла. Завершая обзор команд раздела File командного окна MatLab (см. рис. 4.4), отметим, что применение следующих команд этого раздела: Print...; Print Setup...; Exit MATLAB, по сравнению с общепринятым не имеет каких-либо принципиальных особенностей, поэтому здесь они и не рассматриваются. 4.2.2. Раздел меню Edit
Рис. 4.13.
Раскрывая в окне MatLab Command Window раздел Edit (рис. 4.13), пользователь получает доступ, во-первых, к трем обычным командам типового редактирования: Cut, Copy, Paste, которые не требуют дополнительных комментариев и, во-вторых, одной специальной команде – Clear Session, позволяющей выполнять очистку командного окна MatLab сеансе работы. 83
4.2.3. Раздел меню Options Если в строке главного меню командного окна среды MatLab (рис. 4.4), раскрыть раздел Options, то появится диалоговое окно, представленное на рис. 4.14. С помощью этого окна становятся доступными следующие команды: Numeric Format; Turn Echo on (Turn Echo off); Enable Background Process (Disable Background Process); Font...; Editor Preference. Команда Numeric Format. Рис. 4.14. Ввод команды "Numeric Format", этот случай приведен на рис. 1.14 (имеется ввиду активное положение указателя мыши), позволяет пользователю выбрать и задать выходной формат числовых данных, в частности: − Short (default) – формат с фиксированной точкой с 5 знаками, который установлен по умолчанию; − Long – формат с фиксированной точкой с 15 знаками; − Hex – шестнадцатеричный формат; − Bank – фиксированный формат для денежных единиц; − Plus – компактный формат для отображения положительных элементов, мнимая часть игнорируется; − Short e – формат с плавающей запятой с 5 знаками; − Long e – формат с плавающей запятой с 15 знаками; − Rational – формат целочисленной аппроксимации; − Loose (default) – формат без подавления перевода строки; − Compact – формат обратный предыдущему. Команда Turn Echo on (off). Команда "Turn Echo on" включает режим отображения листинга script-файла3, а команда "Turn Echo off" этот режим отключает. Команда (Disable ) Enable Background Process. Команда "Enable (Disable) Background Process" разрешает (блокирует) выполнение фоновых процессов. Команда Font... В результате ввода команды "Font..." появляется диалоговое окно, представленное на рис. 4.15, с помощью которого пользователь может как изменить тип используемого шрифта, так и задать 84
ему соответствующий цвет и размер.
Рис. 4.15.
Рис. 4.16.
4.2.4. Раздел меню Windows Если пользователь выбрал и раскрыл в командном окне MatLab раздел Windows, то ему становятся доступны команды, позволяющие вызвать любое из активных окон текущего сеанса работы с MatLab. В частности, на рис. 4.17 – это могут быть окна: Figure No.1; Figure No.2; Figure No.3; MatLab Command Window. 4.2.5. Раздел меню Help При выборе в MatLab Command Window раздела меню – Help, на экране появляется изображение, представленное на рис. 4.18. Данное окно позволяет пользователю работать с помощью, например, вводя команду Table of contents вызывается оглавление англоязычной справки по функциям тулбокса MatLab. Если же в разделе Help ввести команду index, то в окне помощи появится перечень обозначений всех функций тулбокса программной среды MatLab. 85
Рис. 4.17.
Рис. 4.18.
4.3. Тулбокс MatLab Обратимся рис. 4.19, где, во-первых, перечислен состав разделов справки MatLab (типовая версия 4.0) и, во-вторых, говорится о том, что предлагаемая помощь доступна для ознакомлением с функциями MatLab различных областей применения.
Рис. 4.19.
При этом для каждой из рассматриваемых областей выделены отдельные директории (папки), в каждую из которых загружены соответствующие рабочие файлы MatLab, как правило, это m-файлы. В частности, в состав тулбокса MatLab входят следующие папки: − COLOR Управление цветом и модели освещенности. − DATAFUN Анализ данных и Фурье-преобразование функций. − DEMOS Демонстрации и примеры. 86
− − − − − − − − − − − − − − − − −
ELFUN ELMAT FUNFUN GENERAL GRAPHICS IOFUN LANG MATFUN OPS PLOTXY PLOTXYZ POLYFUN SOUNDS SPARFUN SPECFUN SPECMAT STRFUN
Элементарные математические функции. Элементарные матрицы и действия над ними. Функционалы и нелинейные численные методы. Универсальные команды. Универсальные графические функции. Нижний уровень файловых I/O-функций. Язык создания и отладки. Матричные функции и линейная алгебра. Операторы и специальные символы. Двухмерная графика. Трехмерная графика. Полиномиальные и интерполяционные функции. Обработка звуковых функции. Разреженные матричные функции. Специальные математические функции. Специальные матрицы. Функции обработки строк и текста. 4.4. Тулбокс Signal
В отличие от тулбокса MatLab, тулбокс "Signal" состоит из более чем 100 m-файлов, предназначенных для исследования систем управления. Далее перечислены имена конкретных m-файлов, разбитых на три блока, внутри которых выделены соответствующие группы. Блок «Характеристики систем управления».
impulse step lsim dimpulse dstep dlsim bode nyquist dbode
Группа - временные характеристики импульсная характеристика переходной процесс отклик системы на произвольное задающее воздействие дискретная импульсная характеристика дискретный переходной процесс отклик дискретной системы на задающее воздействие Группа - частотные характеристики амплитудно-фазовые частотные характеристики (АФЧХ) годограф Найквиста дискретные АФЧХ 87
Блок «Модели систем управления». append connect parallel series ord2 ss2tf ss2zp tf2ss tf2zp zp2tf zp2ss c2d d2c balreal damp gram ctrb obsv tzero
Группа - построение моделей добавление уравнений динамики системы моделирование блок-схем параллельное соединение систем последовательное соединение систем формирование матриц A, В, C и D для системы 2го порядка Группа - преобразование моделей пространство состояний → передаточная функция пространство состояний → нули и полюса передаточная функция → пространство состояний передаточная функция → нули и полюса нули и полюса → передаточная функция нули и полюса → пространство состояний непрерывная модель → дискретная модель дискретная модель → непрерывная модель Группа - реализация моделей сбалансированная реализация Группа - свойства моделей собственные частоты и коэффициенты демпфирования грамианы управляемости и наблюдаемости матрица управляемости матрица наблюдаемости передаточные нули
Блок «Расчет регуляторов систем управления». Группа - расчеты lqr расчет линейно-квадратичного оптимального регулятора lqe расчет линейно-квадратичного оптимального наблюдателя dlqr расчет линейно-квадратичного дискретного регулятора dlqe расчет линейно-квадратичного дискретного наблюдателя margin расчет запаса по амплитуде и фазе Группа - полюсы place размещение полюсов rlocus годограф полюсов замкнутой системы Группа - решения lyap решение уравнения Ляпунова dlyap решение дискретного уравнения Ляпунова 88
4.5. Тулбокс KMM На рис. 4.20 представлен перечень m-файлов, составляющих директорию KMM, с помощью которых осуществляется подготовка и выполнение заданий всех лабораторных работ. В данном тулбоксе большинство m-файлов могут быть распределены по отдельным группам. В частности, такие файлы как LB1, LB2, LB3, LB4, LB5, LB6, LB7 относятся к группе основных или рабочих файлов. Вторая группа m-файлов объединяет в своём составе те файлы, которые применяются для организации интерактивного Рис. 4.20. режима работы с разделами меню “Лабораторные работы по KMM”. К этой группе относятся файлы: Choices, Opisanie, KMM. В свою очередь, следующие файлы: Pos01, Pos02, Pos03, Pos04, Pos05, Pos06, Pos07 и Pos08, также образуют группу m-файлов оперативной помощи, поскольку указанные файлы являются соответствующими подразделами русифицированной подсказки, оформленной в виде дополнительного диалогового окна - “Краткое описание
”.
89
5. КУРСОВАЯ РАБОТА
5.1. Краткие методические указания Тема курсовой работы – "Использование встроенных функций и операторов ППП MatLab for Windows". Работа включает в себя изучение основных приемов работы в среде MatLab, в частности изучение встроенных функций и операторов для решения математических задач, описываемых в матричной форме. Необходимо в соответствии с номером варианта решить с помощью MatLab ряд задач (см. п. 5.2.), включающих построение графика функции, различные действия над матрицами и решение системы нелинейных алгебраических уравнений. При оформлении курсовой работы необходимо подготовить: Титульный лист. Оглавление. Содержание работы (в тексте пояснить смысл используемых функций; привести результаты расчетов в среде MatLab). Заключение. Список литературы. Обратить внимание на применение основных символов и знаков при вводе данных, правил записи выражений, возможности встроенных функций. Подробнее можно прочитать в справочнике языка MatLab1. 5.2. Задание2 5.2.1. Построить график функции F(x) при изменении аргумента x (согласно номеру варианта). 1. F ( x) = ( x − 2) 2 2 x + x 2 − 20 sin x . 2. F ( x) = arcctgx + 2( x − 2) 2 − 4 x − 3 .
3. F ( x) = ( x − 3) cos x − 3 x + x 2 . 1
Еремин Е.Л. Компьютерное моделирование процессов и систем. Благовещенск: Изд-во БГПУ, 2003. 2 Пункты задания подготовлены Самохваловой С.Г.
90
4. F ( x) = ( x − 2) 2 lg( x + 11) − 20 sin x . 5. F ( x) = e x + ( x + 2) 2 + x 2 cos 2 x . 6. F ( x) = ( x − 3) 2 log 0,5 ( x − 2) − 5 arcsin x . 7. F ( x) = ( x − 2) 2 lg( x + 11) + 2arctgx . 8. F ( x) = sin( x − 0,5) + 2e x − ( x − 2) 2 2 x . 9. F ( x) = x log 3 ( x + 1) + cos( x + 0,3) .
10. F ( x) = tg 3 x + x lg( x + 1) . 11. F ( x) = 2e x − ( x − 2) 2 2 x + x log 3 ( x + 1) . 12. F ( x) = ( x − 3) cos x + 0,5 x + 1 . 13. F ( x) = arctg ( x − 1) + 2 x + e − 2 x + x 2 . 14. F ( x) = arctg ( x − 1) + 2 x + x 2 cos 2 x . 15. F ( x) = x lg( x + 1) + x 2 2 x − 20 sin 5 x . 16. F ( x) = x log 3 ( x + 1) 2 + 2e x + arcctgx . 17. F ( x) = sin( x + 1) + ( x + 2) log 2 ( x − 3) + 5 x − 6 . 18. F ( x) = 3 x + 5 x − ( x − 3) cos( x − 2) . 19. F ( x) = ( x − 2) 2 lg( x + 11) + 2 x x 2 − sin x .
5.2.2. Найти собственные числа и собственные векторы матриц. 5.2.3. Округлить элементы матрицы к ближайшему целому числу. 5.2.4. Преобразовать элементы матрицы А из вещественной формы записи в форму записи вида рациональной дроби. Номер варианта 1
2
3 Номер
Матрица
Номер варианта
1 1,5 2,5 A = 1,5 1,3 2,1 2,5 2 1,7 1 1,2 2 A = 1,2 1 0,4 2 0,4 2 1 1,2 2 A = 1,2 1 0,5 2 0,5 2 Матрица
11
12
13 Номер 91
Матрица 1,5 2,5 2,5 A = 1,3 2 1,2 2 1,9 1,7 1 2,5 3,5 A = 1,5 2 1,6 2,5 1 1,7 1,5 1,6 3,5 A = 1,6 2,5 1,2 1,7 1,2 1,4 Матрица
варианта 4
5
6
7
варианта 2,5 1 2 A = 1 2 1, 2 2 0,4 1,5 2 1 1,4 A = 1 1 0,5 1,4 0,5 2
14
15
2 1,5 3,5 A = 1,5 2 2 3,5 2 2 1,2 0,5 1 A = 0,5 1 2 2 0,8 1
16
17
8
0,5 1,2 1 A = 1,2 2 0,5 0,5 0,5 1
18
9
1,2 0,5 A = 0,5 1,4 2 0,6
1 2 1
19
10
1 1,5 1,2 A = 1,5 2 0,4 2,5 2 1
1 2,5 3,5 A = 1,5 2 1,6 2,5 1 1,7 2 1,7 1,6 A = 1,7 2 3,5 1,6 2 1 3 1,7 1,6 A = 1,7 1 2 1,6 2 3 1 1,5 1,2 A = 1,5 2 0,4 1,2 2 1,5 1 2,5 3,5 A = 1,5 2 1,6 2,5 1 1,7 1 1,5 0,4 A = 1,5 1 1,6 0,4 1 2
5.2.5. Выполнить сложение, умножение и деление матриц. 5.2.6. Вычислить кумулятивные суммы для каждого столбца матрицы. Номер варианта 1
2 Номер
Матрица 1 − 1 2 A = 1 2 1 2 0 3 3 1 1 A= 1 2 3 − 2 5 −2 Матрица
Номер варианта 11
12 Номер 92
Матрица 1 2 5 A = 1 4 1 2 1 7 1 5 3 A = 1 2 6 2 1 7 Матрица
варианта 3
4
5
6
7
8
варианта −1 1 −1 A= 4 4 2 1 2 3 3 2 −1 A = 2 4 1 −1 0 − 2
13
14
2 1 1 A = 1 1 5 1 5 2 6 3 8 A = 3 2 3 −1 0 − 4
15
16
2 5 1 A = 5 1 2 2 8 1 5 2 1 A = 1 2 5 5 5 1
9
2 5 A = 7 1 2 6
10
1 5 2 A = 1 2 4 2 2 1
17
18
1 3 1
19
5 6 3 A = 1 2 2 7 1 4 1 2 3 A = 5 2 6 2 1 7 2 7 6 A = 1 2 3 6 2 1 3 7 1 A=1 2 4 6 2 3 1 5 2 A = 5 2 4 1 2 5 1 5 3 A = 5 2 6 2 1 7 1 5 4 A = 5 1 6 4 1 2
5.2.7. Уравновесить строки и столбцы матриц таким образом, чтобы нормы строк и столбцов оказались примерно одинаковыми. 5.2.8. Найти максимальный и минимальный элемент матриц. 5.2.9. Отсортировать каждый столбец матрицы в возрастающем порядке элементов. 5.2.10. Вычислить вектор-строку с суммами элементов каждого столбца матрицы. 93
− 14 −1 1. A = − 14 − 15 − 29 − 12 1 3. A = − 12 − 11 − 23 − 10 3 5. A = − 10 −7 − 17 −8 5 7. A = − 8 −3 − 11 − 6 7 9. A = − 6 1 − 5 − 4 9 11. A = − 4 5 1 − 2 11 13. A = − 2 9 7
−9 −4 1 6 − 2 − 2 − 4 − 14 −9 −9 −2 3 − 11 − 11 − 3 − 8 − 20 − 20 0 − 10 −7 −2 3 8 0 8 − 2 − 12 −7 4 5 0 −7 −4 6 1 − 14 10 − 4 6 − 5 0 5 10 2 10 0 − 10 −5 6 7 2 − 3 10 5 0 − 8 16 12 2 − 3 2 7 12 4 12 2 − 8 −3 8 9 4 1 14 9 4 − 2 22 18 8 − 1 4 9 14 6 14 4 − 6 − 1 10 11 6 5 18 13 8 4 28 24 14 1 6 11 16 8 16 6 − 4 1 12 13 8 9 22 17 12 10 34 30 20 3 8 13 18 10 18 8 − 2 3 14 15 10 13 26 21 16 16 40 36 26 94
− 13 0 2. A = − 13 − 13 − 26 − 11 2 4. A = − 11 −9 − 20 −9 4 6. A = − 9 −5 − 14 − 7 6 8. A = − 7 −1 −8 − 5 8 10. A = − 5 3 − 2 − 3 10 12. A = − 3 7 4 −1 12 14. A = − 1 11 10
−8 −3 2 7 − 1 7 − 3 − 13 −8 −1 3 4 −9 4 −1 − 6 − 17 7 3 − 7 − 6 −1 4 9 1 9 − 1 − 11 −6 5 6 1 −5 8 3 2 − 11 13 9 − 1 − 4 1 6 11 3 11 1 − 9 −4 7 8 3 − 1 12 7 2 − 5 19 15 5 − 2 3 8 13 5 13 3 − 7 − 2 9 10 5 3 16 11 6 1 25 21 11 0 5 10 15 7 15 5 − 5 0 11 12 7 7 20 15 10 7 31 27 17 2 7 12 17 9 17 7 − 3 2 13 14 9 11 24 19 14 13 37 33 23 4 9 14 19 11 19 9 − 1 4 15 16 11 15 28 23 18 19 43 39 29
− 4 9 15. A = − 4 5 1 − 2 11 17. A = − 2 9 7 − 4 9 19. A = − 4 5 1
1 8 1 9 10 3 10 3 13 16 1 8 1 9 10
6 16 12 22 34 8 18 14 26 40 6 16 12 22 34
11 6 13 17 30 13 8 15 21 36 11 6 13 17 30
− 3 10 16. A = − 3 7 4 −1 12 18. A = − 1 11 10
16 − 4 8 12 20 18 − 2 10 16 26 16 − 4 8 12 20
2 9 2 11 13 4 11 4 15 19
7 17 13 24 37 9 19 15 28 43
12 7 14 19 33 14 9 16 23 39
17 − 3 9 14 23 19 − 1 11 18 29
5.2.11. Вектор b1 как строку к матрице А, а вектор b2 как столбец и вывести новую матрицу. − 14 − 9 −1 − 2 1. A = − 14 − 9 − 15 − 11 − 29 − 20 − 13 − 8 −1 0 2. A = − 13 − 8 − 13 − 9 − 26 − 17 − 12 − 7 0 1 3. A = − 12 − 7 − 11 − 7 − 23 − 14
−4 6 2 2 4 −3 7 3 4 7 −2 8 4 6 10
1 −4 3 −3 0 2 −3 4 −1 3 3 −2 5 1 6
6 − 14 −2 −8 − 10 7 − 13 −1 −6 − 7 8 − 12 0 −4 − 4
95
− 3.45 − 15 . 2 b1 = − 10.45 − 18.65 − 29.1 − 2.8 − 26.3 b1 = − 16.8 − 29.1 − 45.9 1.95 − 33.3 b1 = − 19.05 − 31.35 − 50.4
− 2.45 − 15 . 1 b2 = − 9.45 − 18.98 − 29.6 − 1.8 − 26.1 b2 = − 15.8 − 29.77 − 46.9 2.95 − 33 b2 = − 18.05 − 32.35 − 51.9
9 − 11 − 6 − 1 4 − − 2 1 9 1 11 4. A = − 11 − 6 5 6 1 − − 9 5 8 3 2 − 20 − 11 13 9 − 1 − 10 − 5 0 5 10 − 3 2 10 0 10 5. A = − 10 − 5 6 7 2 0 − 7 − 3 10 5 − 17 − 8 16 12 2 − 9 − 4 1 6 11 3 11 1 − 9 4 6. A = − 9 − 4 7 8 3 2 − 5 − 1 12 7 − 14 − 5 19 15 5 − 8 − 3 2 7 12 4 12 2 − 8 5 7. A = − 8 − 3 8 9 4 − 3 1 14 9 4 − 11 − 2 22 18 8 − 7 − 2 3 8 13 − 6 5 13 3 7 8. A = − 7 − 2 9 10 5 − 1 3 16 11 6 − 8 1 25 21 11 − 6 − 1 4 9 14 − 7 6 14 4 6 9. A = − 6 − 1 10 11 6 5 18 13 8 1 − 5 4 28 24 14 − 5 0 5 10 15 8 7 15 5 − 5 10. A = − 5 0 11 12 7 3 7 20 15 10 − 2 7 31 27 17 96
10.8 − 36 . 2 b1 = − 17.2 − 25 . 4 − 42.6 − 23.75 35 b1 = − 11.25 − 11.25 − 22.5 − 40.8 − 29.7 b1 = − 1.2 11.1 9.9 61.95 − 20.3 b1 = 12.95 41.65 54.6 87.2 − 6 . 8 b1 = 31.2 80 . 4 111.6 116.55 10 . 8 b1 = 53.55 127.35 180.9 150 32.5 b1 = 80 182.5 265.5
b2
b2
b2
b2
b2
b2
b2
− 11.8 − 35 . 8 = − 16.2 − 26 . 73 − 44.6 24.75 34 . 5 = − 10.25 − 12.92 − 25 − 41.8 − 29.1 = − 0.2 9.1 6.9 62.5 − 19.6 = 13.95 39.32 51.1 88.2 − 6 = 32.2 77 . 73 107.6 117.55 11 . 7 = 54.55 124.35 176.4 151 33.5 = 81 179.167 257.5
11.
12.
13.
14.
15.
16.
17.
− 4 1 6 11 16 − 9 8 16 6 4 A = − 4 1 12 13 8 5 9 22 17 12 1 10 34 30 20 − 3 2 7 12 17 − 10 9 17 7 3 A = − 3 2 13 14 9 7 11 24 19 14 4 13 37 33 23 − 2 3 8 13 18 11 10 18 8 − 2 A = − 2 3 14 15 10 9 13 26 21 16 7 16 40 36 26 − 1 4 9 14 19 12 11 19 9 − 1 A = − 1 4 15 16 11 11 15 28 23 18 10 19 43 39 29 8 − 12 − 7 − 2 3 − − 1 0 8 2 12 A = − 12 − 7 4 5 0 − − − 11 7 6 1 4 − 23 − 14 10 6 − 4 − 9 − 4 1 6 11 − 4 3 11 1 9 A= −9 −4 7 8 3 2 − 5 − 1 12 7 − 14 − 5 19 15 5 − 6 − 1 4 9 14 6 14 4 − 6 7 A = − 6 − 1 10 11 6 5 18 13 8 1 − 5 4 28 24 14 97
187.55 58 . 3 b1 = 110.55 245 . 85 356.4 229.2 88 . 2 b1 = 145.2 317.4 462.6 274.95 122.2 b1 = 183.95 397.15 581.1 324.8 160.3 b1 = 226.8 485.1 711.9 6 7 b1 = 1 − 2 4 5 2 b1 = 6 1 9 3 4 b1 = 5 1 2
188.55 59 . 4 b2 = 11.55 242 . 183 350.9 230.2 89 . 4 b2 = 146.2 313.4 456.6 275.95 123.5 b2 = 184.95 392.817 574.6 325.8 161.7 b2 = 227.8 480.433 704.9 1 3 b2 = 8 2 9 8 4 b2 = 1 7 5 8 2 b2 = 1 6 5
− 3 10 18. A = − 3 7 4 −8 5 19. A = − 8 −3 − 11
5 3 b1 = 6 1 7 5 3 b1 = 1 7 8
2 7 12 17 9 17 7 − 3 2 13 14 9 11 24 19 14 13 37 33 23 − 3 2 7 12 4 12 2 − 8 −3 8 9 4 1 14 9 4 − 2 22 18 8
7 2 b2 = 4 1 6 5 2 b2 = 1 3 7
5.2.12. Решить графически систему нелинейных алгебраически уравнений. Номер варианта 1 2 3 4 5 6 7 8 9
Система уравнений
Номер варианта
у + ( x − 2) 2 2 x = 2
11
x 2 − 20 sin y = 3
arcctgx + 2( y − 2) 2 = 5
12
y − 4x − 3 = 3 y + ( x − 3) cos x = 5
13
− 3x + y 2 = 2 y = ( x − 2) 2 lg( x + 11) = 7 − 20 sin x − 3
x −3
14
=3
ye x + ( x + 2) 2 = 3
15
x 2 cos 2 x − 5 y 3 = 2 y ( x − 3) 2 log 0,5 ( x − 2) = 6 − 5 arcsin x + 2
x +3
16
=2
y − ( x − 2) 2 + x = 6
17
lg( y + 11) + 2arctgx = 1 y + sin( x − 0,5) + 2e x = 4
18
( x − 2) 2 2 x − y 2 = 1 y − x log 3 ( x + 1) = 3
19
cos( x + 0,3) + 2 y = 1
98
Система уравнений y + 2e x − ( x − 2) 2 = 6 2 y + x log 3 ( x + 1) = 1 y 3 − ( x − 3) cos x = 4 2
0,5 x + 2 − y = 1 y 2 − arctg ( x − 1) = 2 2 x + e −2 y + x 2 = 4 y 5 + arctg ( x − 1) = 4 2 x + x 2 cos 2 y = 1 4 y − x lg( x + 1) = 3 x 2 2 x − 20 sin 5 y = 4 y 3 − x log 3 ( x + 1) 2 = 6 2e y + arcctgx = 2 6 y + sin( x + 1) + ( x + 2) = 5 log 2 ( y − 3) + 5 x − 6 = 1 3 y + 5 x − ln( x − 3) = 3 cos( x − 2) + e y = 2 y 3 − ( x − 2) 2 lg( x + 11) = 4 2 x x 2 − arcsin y = 2
Номер варианта 10
Система уравнений
Номер варианта
Система уравнений
–
–
y − tg 3 x = 2 x lg( x + 1) − cos y = 5
5.3. Примеры Пример 1. Выполнить действия с матрицами (сложение и умножение). Над матрицами можно выполнять простейшие арифметические действия, используя соответствующие операторы. >> A=[1 2 3; 4 5 6; 7 8 9]; B=[1 4 7; 2 5 8; 9 6 3] >> C=A+B C= 2 6 10 6 10 14 16 14 12 >> D=A*B D= 32 32 32 68 77 86 104 122 140 Пример 2. Вычислить кумулятивные суммы для каждого столбца матрицы. Используем функцию CUMSUM(X). >> x=[2 4 6; 1 3 2]; cumsum(x) ans = 2 4 6 3 7 8 >> Пример 3. Округлить элементы матрицы к ближайшему целому числу. Для этого используем функцию ROUND(A). >> x=[1.2 -3.2 3.3 4.8]; y=round(x) y= 1 -3 3 5 >> Пример 4. Решить графически систему нелинейных алгебраических равнений. 99
y + cos 2 x = 0, y − sin 3 x = 0. Выразим y из первого и второго уравнений в явном виде, получим: y = − cos 2 x, y = sin 3 x. Построим в одной системе координат графики функций 3 y ( x) = − cos 2 x и y(x) = sin x , координаты точек пересечения которых будут являться решением данной системы уравнений.
>> x=-6:0.01:6; >> y1=-(cos(x)).^2; >> y2=(sin(x)).^3; >> plot(x,y1,x,y2) >>
Рис. 5.1.
100
6. ЛАБОРАТОРНЫЕ РАБОТЫ Перечень предлагаемых лабораторных работ включает в себя: − Лабораторная работа №1 (4 ч.). Знакомство с рабочим местом лабораторного комплекса. − Лабораторная работа №2 (6 ч.). Имитационное моделирование позиционных звеньев. − Лабораторная работа №3 (4 ч.). Имитационное моделирование интегрирующих звеньев. − Лабораторная работа №4 (2 ч.). Имитационное моделирование реального дифференцирующего звена. Выполнение всех заданий лабораторно практикума связано с использованием MatLab – высокоэффективного программного обеспечения для научных и инженерных расчетов. 6.1. ЛБ №1. Знакомство с рабочим местом лабораторного комплекса Для вызова программной среды MatLab вам необходимо воспользоваться кнопкой Пуск и выбрать следующую последовательность: Программы → MatLab for Windows → MatLab. После вызова MatLab на экране появится окно, показанное на рис. 6.1.
Рис. 6.1.
Из рис. 6.1 следует, что Рабочее место MatLab представляет собой командное окно (MatLab Command Window), состоящее из: главного меню, с разделами – File, Edit, Options, Windows, Help; 101
− рабочей области, с информационным текстом и специальным знаком приглашения к работе “>>”, после которого вводится та или иная команда: demo, kmm и т.п. Непосредственно для начала работы вводится команда kmm, в результате чего в рабочей области MatLab Command Window появляется диалоговое окно “Лабораторные работы по КММ” (рис. 6.2).
Рис. 6.2.
Представленное меню предлагает пользователю осуществить любое из следующих действий: − запустить интерактивный режим выполнения нужной лабораторной работы; − просмотреть пример заполнения отчета по лабораторной работе №1; − просмотреть краткое описание программной среды MatLab; − закрыть диалоговое окно. Раздел меню “Краткое описание ” вызывает дополнительное диалоговое окно, внешний вид которого приведен на рис. 6.3. С помощью вызова этого дополнительного меню пользователь получает доступ к соответствующим разделам справочного материала, в котором кратко описаны наиболее характерные особенности применения и базовые возможности программной среды MatLab. Если в меню “Лабораторные работы по КММ” (см. рис. 6.2), выбрать и ввести раздел – Векторно-матричные преобразования пакета MatLab, то это приведет к появлению в рабочей области MatLab Command Window первоначального экранного фрагмента данной лабора102
торной работы (см. рис. 6.4), которую необходимо выполнить, внимательно прочитав все указания, появляющиеся на экране.
Рис. 6.3.
Рис. 6.4.
Текст данной программы содержит наряду с краткими комментариями и методическими указаниями, также и описание соответствующей последовательности. 6. 2. ЛБ №2. Имитационное моделирование позиционных звеньев Цель данной лабораторной работы – исследование динамических характеристик группы позиционных звеньев (см. п. 3.1), в частности апериодических 1-го и 2-го порядков и колебательного. Все эти звенья в 103
установившемся режиме описываются одинаковым уравнением вида (3.1) и передаточными функциями вида (3.12) и (3.20) для апериодических звеньев 1-го и 2-го порядка, соответственно, и (3.34) для колебательного звена. Требуется для динамических систем (3.12), (3.20) и (3.34) в соответствии с заданным вариантом (см. ниже) осуществить математическое и имитационное моделирование (с построением графиков) следующих временных и частотных характеристик: h(t), w(t), A(ω), ϕ(ω), U(ω), V(ω) и W(jω). В качестве образца ниже приведена распечатка программы1, которая будет отработана в диалоговом режиме после выбора пункта Характеристики апериодического звена 1-го порядка меню “Лабораторные работы по КММ” и отражающая последовательность необходимых действий, осуществляемых пакетом MatLab 4 для расчета и построения временных и частотных характеристик апериодического звена 1-го порядка. Ключевым моментом, от которого зависит правильность выполнения данной и последующих лабораторных работ, является введение коэффициентов числителя (num) и знаменателя (den) передаточной функции. % АПЕРИОДИЧЕСКОЕ ЗВЕНО 1-ОГО ПОРЯДКА % % Рассматривается передаточная функция вида % W (p) = x(p)/u(p) = K/(T*p + 1) (1) % где x(p) и u(p) - изображения входа и выхода; К, Т - положительные постоянные коэффициенты. % В А Р И А Н Т Ы: % ¦No¦К ¦Т¦ % ¦==¦==¦=¦ % ¦01¦10¦1¦ % ¦02¦12¦2¦ % ¦03¦13¦3¦ % ¦04¦15¦1¦ % ¦05¦14¦3¦ % ¦06¦16¦2¦ % ¦07¦17¦1¦ % ¦08¦16¦2¦ % ¦09¦15¦3¦ % ¦10¦14¦2¦ % ВАШ вариант определяется последней цифрой номера в журнале % (в соответствии со списком фамилий) pause % Для продолжения работы нажмите любую клавишу ... % % ЗАДАНИЕ % Требуется: 1
Это распечатка экранной формы окна управления MatLab 4, полученная при выполнении расчетов с конкретными данными.
104
% 1. Построить переходной процесс, весовую функцию. % 2. Построить АЧХ, ФЧХ, ВЧХ, МЧХ, АФЧХ. % % Введите числитель (num) передаточной функции (1). num = input('num=') num=[14] num = 14 pause % Для продолжения работы нажмите любую клавишу ... % Введите знаменатель (den) передаточной функции (1). den = input('den=') den=[3 1] den = 3
1
pause % Для продолжения работы нажмите любую клавишу ... % Переход в пространство состояний pause % Для продолжения работы нажмите любую клавишу ... [a,b,c,d] = tf2ss(num,den) a= -0.3333 b= 1 c= 4.6667 d= 0 pause % Для продолжения работы нажмите любую клавишу ... % Построение переходного процесса t=0:.005:15; step(a,b,c,d,1,t); pause % Для продолжения работы нажмите любую клавишу ... % Построение весовой функции impulse(a,b,c,d,1,t); pause % Для продолжения работы нажмите любую клавишу ... % Построение частотных характеристик
105
w=0:.005:30; [mag,phase] = bode(a,b,c,d,1,w); [re,im] = nyquist(a,b,c,d,1,w); pause % Для продолжения работы нажмите любую клавишу ... subplot(221), plot(w,mag), title('Magnitude response'), xlabel('Radians/s'), subplot(223), plot(w,phase), title('Phase response'), xlabel('Radians/s'), subplot(222), plot(w,re), title('Real response'), xlabel('Radians/s'), subplot(224), plot(w,im), title('Image response'), xlabel('Radians/s'), pause % Для продолжения работы нажмите любую клавишу ... plot(re,im), title('W(jw)'), xlabel('Re'), ylabel('Im'), pause % Для завершения работы нажмите любую клавишу ...
Реализации данной программы в графических образах показана на рис. 6.5 – 6.8: рис. 6.5 – переходный процесс; рис. 6.6 – весовая функция; рис. 6.7 – частотные характеристики A(ω), ϕ(ω), U(ω), V(ω); рис. 6.8 – годограф W(jω). Для того чтобы в процессе выполнения программы каждый рисунок появлялся в отдельном окне, необходимо в появившемся графическом окне выбрать меню File команду New Figure. Для сохранения графических образов можно использовать в меню Edit команду Copy to bitmap. Затем нужно открыть графический редактор Paint, создать в нем новый файл и вставить рисунок, выбрав команду главного меню Правка → Вставить. Теперь рисунок можно отредактировать (например, обратить цвета) и сохранить, выбрав команду Сохранить или Сохранить как… в меню Файл. Для исследования апериодического звена 2-го порядка и колебательного звена выбираются пункты, соответственно, Характеристики апериодического звена 2-го порядка и Характеристики колебательного звена, вследствие чего будет отработана аналогичная программа. АПЕРИОДИЧЕСКОЕ ЗВЕНО 2-ОГО ПОРЯДКА % % % % % % % % % % % %
В А Р И А Н Т Ы: ¦No¦К ¦Т1¦Т2¦ ¦01¦10¦ 1¦10¦ ¦02¦12¦ 2¦11¦ ¦03¦13¦ 3¦12¦ ¦04¦15¦ 1¦13¦ ¦05¦14¦ 3¦14¦ ¦06¦16¦ 2¦15¦ ¦07¦17¦ 1¦14¦ ¦08¦16¦ 2¦13¦ ¦09¦15¦ 3¦12¦ ¦10¦14¦ 2¦11¦
КОЛЕБАТЕЛЬНОЕ ЗВЕНО % % % % % % % % % % % %
В А Р И А Н Т Ы: ¦No¦К ¦Т1¦Т2¦ ¦01¦10¦11¦3¦ ¦02¦12¦12¦2¦ ¦03¦13¦13¦1¦ ¦04¦15¦11¦1¦ ¦05¦14¦13¦2¦ ¦06¦16¦12¦2¦ ¦07¦17¦11¦3¦ ¦08¦16¦12¦3¦ ¦09¦15¦13¦1¦ ¦10¦14¦12¦1¦
Результаты выполненной лабораторной работы предоставляются в виде отчета, в котором необходимо записать: дифференциальное уравне106
ние звена, вид передаточной функции, уравнения временных характеристик h(t) и w(t) с соответствующими графиками, уравнения частотных характеристик W(jω) и A(ω), ϕ(ω), U(ω), V(ω) с их графиками. Для подготовки отчета рекомендуется использовать текстовый редактор MS Word.
Рис. 6.5.
Рис. 6.6.
107
Рис. 6.7.
Рис. 6.8.
6. 3. ЛБ №3. Имитационное моделирование интегрирующих звеньев Цель работы – исследование динамических характеристик идеального интегрирующего звена и интегрирующего звена с замедлением (см. п. 3.2). Эти звенья в установившемся режиме описываются одинаковым 108
уравнением вида (3.43) и передаточными функциями вида (3.45) и (3.54), соответственно. Требуется для динамических систем (3.45) и (3.54) в соответствии с заданным вариантом осуществить математическое и имитационное моделирование (с построением графиков) следующих временных и частотных характеристик: h(t), w(t), A(ω), ϕ(ω), U(ω), V(ω) и W(jω). Для выполнения данной лабораторной работы выбираются в меню “Лабораторные работы по КММ” пункты Характеристики идеального интегрирующего звена и Характеристики интегрирующего звена с замедлением, вследствие чего будет отработана последовательность действий, осуществляемых пакетом MatLab 4 для расчета и построения временных и частотных характеристик (программа аналогична описанной в п. 6.2). ИДЕАЛЬНОЕ ИНТЕГРИРУЮЩЕЕ ЗВЕНО % % % % % % % % % % % % %
ИНТЕГРИРУЮЩЕЕ ЗВЕНО С ЗАМЕДЛЕНИЕМ
В А Р И А Н Т Ы: ¦No¦К ¦ ¦==¦==¦ ¦01¦10¦ ¦02¦22¦ ¦03¦13¦ ¦04¦25¦ ¦05¦14¦ ¦06¦26¦ ¦07¦17¦ ¦08¦26¦ ¦09¦15¦ ¦10¦24¦
% % % % % % % % % % % % %
В А Р И А Н Т Ы: ¦No¦К ¦Т¦ ¦==¦==¦=¦ ¦01¦10¦1¦ ¦02¦12¦2¦ ¦03¦13¦3¦ ¦04¦15¦1¦ ¦05¦14¦3¦ ¦06¦16¦2¦ ¦07¦17¦1¦ ¦08¦16¦2¦ ¦09¦15¦3¦ ¦10¦14¦2¦
Результаты выполненной лабораторной работы предоставляются в виде отчета, в котором необходимо записать: дифференциальное уравнение звена, вид передаточной функции, уравнения временных характеристик h(t) и w(t) с соответствующими графиками, уравнения частотных характеристик W(jω) и A(ω), ϕ(ω), U(ω), V(ω) с их графиками. Для подготовки отчета рекомендуется использовать текстовый редактор MS Word. 6. 4. ЛБ №4. Имитационное моделирование реального дифференцирующего звена Цель работы – исследование динамических характеристик реального дифференцирующего звена (см. п. 3.3). Это звено в установившемся 109
режиме описывается уравнением вида (3.71) и передаточной функцией (3.72). Требуется для процесса (3.71) в соответствии с заданным вариантом осуществить математическое и имитационное моделирование (с построением графиков) следующих временных и частотных характеристик: h(t), w(t), A(ω), ϕ(ω), U(ω), V(ω) и W(jω). Для выполнения данной лабораторной работы выбираются пункты, соответственно, Характеристики реального дифференцирующего звена, вследствие чего будет отработана последовательность действий, осуществляемых пакетом MatLab4 для расчета и построения временных и частотных характеристик. РЕАЛЬНОЕ ДИФФЕРЕНЦИРУЮЩЕЕ ЗВЕНО % % % % % % % % % % % % %
В А Р И А Н Т Ы: ¦No¦К ¦Т¦ ¦==¦==¦=¦ ¦01¦10¦1¦ ¦02¦12¦2¦ ¦03¦13¦3¦ ¦04¦15¦1¦ ¦05¦14¦3¦ ¦06¦16¦2¦ ¦07¦17¦1¦ ¦08¦16¦2¦ ¦09¦15¦3¦ ¦10¦14¦2¦
Результаты выполненной лабораторной работы предоставляются в виде отчета, в котором необходимо записать: дифференциальное уравнение звена, вид передаточной функции, уравнения временных характеристик h(t) и w(t) с соответствующими графиками, уравнения частотных характеристик W(jω) и A(ω), ϕ(ω), U(ω), V(ω) с их графиками. Для подготовки отчета рекомендуется использовать текстовый редактор MS Word.
110
7. МАТЕМАТИЧЕСКОЕ И КОМПЬЮТЕРНОЕ МОДЕЛИРОВАНИЕ ПРОЦЕССОВ ПОЛЯРИЗАЦИИ
В этой главе рассматривается кибернетическая модель процесса поляризации конденсированных материалов, дающая хорошее совпадение теоретических и экспериментальных характеристик комплексной диэлектрической проницаемости в области электронной упругой поляризации, а также, в рамках использования этой модели, предлагается методика определения параметров поляризационных процессов, эффективность которой оценивается в рамках моделирования длинноволнового спектра показателя преломления на примере воды. 7.1. Процесс упругой электронной поляризации диэлектриков Проблемы имитационного моделирования динамических систем, возникающие при решении ряда прикладных задач, в том числе характерных и для теоретической физики, по-прежнему остаются весьма актуальными. При этом качество результатов или эффективность вычислительных экспериментов существенно зависит от уровня адекватности теоретической модели реальному физическому процессу. Предлагается, следуя работу А.Л. Фрадкова1, для описания процесса поляризации воспользоваться, наряду с традиционными, кибернетической моделью, позволяющей описать свойства физической системы с помощью обратных связей. Модель Клаузиса-Мосотти-Лорентц-Лоренца Известно, что количественной мерой результата поляризации материала служит его поляризованность − P, которую можно описать выражением: K
P = E ∑ niα i ,
(7.1)
i =1
1
Фрадков А.Л. Исследование физических систем при помощи обратных связей // Автоматика и телемеханика. 1999. № 3. С. 213-229.
111
где Е − напряженность электрического поля внутри диэлектрика; K − число разновидностей индуцированных диполей; ni и αi − соответственно концентрации и поляризуемости частиц. Для вычисления диэлектрической проницаемости материала − ε, традиционно используются соотношения, связывающие ε с поляризуемостями частиц, составляющих диэлектрик. Следует отметить ради полноты изложения, что при вычислении диэлектрической проницаемости газов обычно используется формула Борна: 1 K (7.2) ε = 1 + ∑ niα i ,
ε0
i =1
где ε0 − электрическая постоянная (8,85418782⋅10−12 Ф/м), при выводе которой предполагается, что E определяется напряженностью среднего макроскопического поля Eср в материале: P (7.3) E = Ecp = E0 − E1 = E0 − ,
ε0
где E0 − напряженность внешнего поля; E1 − напряженность деполяризующего поля, обусловливаемого наведенными поверхностными зарядами. Действительно, если в выражении (3) осуществить замену E0=εE, то в результате преобразований получим соотношение: P , (7.4) Ecp = ε 0 (ε − 1) из которого, с учетом выражения (7.1), будет следовать соотношение (7.2). Итак, если формула (7.2) применяется для газов, то расчет диэлектрической проницаемости конденсированных материалов обычно осуществляется по формуле Клаузиуса-Мосотти: ε −1 1 K (7.5) = ∑ nα . ε + 2 3ε 0 i =1 i i Здесь, согласно модели Лорентца, величина E определяется, в отличие от выражения (3), не только напряженностью среднего макроскопического поля, но и напряженностями внутренних полей E = Ecp + E2 + E3 , (7.6) где E2 − напряженность поля, создаваемого поляризованными молекулами, окружающими сферу Лорентца, а E3 − напряженность поля, образованного молекулами, находящимися внутри сферы. Значения напряженностей E2 и E3 определяются следующим образом: 112
P (7.7) , E3 = 0 . 3ε 0 Из выражения (7.6), с учетом (7.1), (7.4), (7.7), можно записать соотношение P P E E K ∑ n α , E= (7.8) + = + ε 0 (ε − 1) 3ε 0 ε 0 (ε − 1) 3ε 0 i =1 i i из которого непосредственно вытекает формула Клаузиуса-Мосотти. При исследовании частотных характеристик материала, его диэлектрическую проницаемость принято рассматривать как комплексную функцию ε(jω), т.е. формулы (7.2) и (7.5) принимают вид, во-первых, модели Борна 1 K (7.9) ε ( jω ) = 1 + ∑ niα i ( jω ) , E2 =
ε0
i =1
и, во-вторых, модели Клаузиуса-Мосотти-Лорентц-Лоренца ε ( jω ) − 1 1 K (7.10) = ∑ n α ( jω ) , ε ( jω ) + 2 3ε 0 i =1 i i где αk(jω) − так называемые комплексные поляризуемости частиц вида: qk2 mk . (7.11) α k ( jω ) = 2 2 ω0 k − ω + j 2bk ω При получении явного вида функций αk(jω), используется математическое описание процесса поляризации, в котором участвует отдельно взятая заряженная частица. Если же ограничится рассмотрением только одного вида поляризации − упругой электронной, то этот процесс можно описать системой уравнений: d 2 µ k (t ) dµ k (t ) qk2 2 (7.12) + 2bk + ω0 k µ k (t ) = E0 (t ),k = 1, K , dt 2 dt mk где k − индекс разновидности иона; K − их число; µk(t) − индуцированный дипольный момент электронного облака отдельного иона; ω0k и bk − собственная частота и коэффициент затухания колебаний облака; qk и mk − его заряд и масса; E0(t) − напряженность внешнего переменного электрического поля с малой амплитудой. Кибернетическая модель Как уже отмечалось, напряженность поля в диэлектрике E определяется как напряженностями внешнего и деполяризующего полей (E0 и E1), так и напряженностями внутренних полей (E2 и E3). Однако в отличие от выражения (7.6), где использовалось описание поля с напряженностью 113
Еср, напряженность поля внутри диэлектрика E, подобно известным результатам (например, см. [7]), можно записать в виде: 2 K (7.13) E = E0 − E1 + E2 + E3 = E0 − ∑ ni µ i , 3ε 0 i =1 где µi=αiE − индуцированный дипольный момент частицы i-й разновидности. Кроме того, при составлении математической модели процесса поляризации диэлектрика, будем учитывать как напряженность внешнего поля E0(t), так и напряженности других действующих полей. Относительно уравнения (7.12) это означает, что для его правой части справедлива замена E0(t)→E(t), приводящая к математической модели вида: qk2 dµ k (t ) d 2 µ k (t ) 2 (7.14) + 2bk + ω0 k µ k (t ) = E (t ) , 2 mk dt dt где напряженность E(t) согласно соотношению (7.13) описывается выражением 2 E (t ) = E0 (t ) − 3ε 0
K
∑ ni µi (t ) .
(7.15)
i =1
Тогда с целью построения модели рассматриваемого процесса поляризации диэлектрика, в результате объединения набора соотношений типа (7.14), описывающих все виды поляризации и выражения (7.15), можно получить следующую систему уравнений: d 2 µ k (t ) dµ k (t ) + 2 b + ω02k µ k (t ) = k 2 dt dt (7.16) qk2 2 K E0 (t ) − = ni µ i (t ) , k = 1, K . ∑ i = 1 mk 3ε 0 С позиции технической кибернетики, уравнения (7.16) можно рассматривать как математическую модель некоторой замкнутой линейной системы управления с отрицательной обратной связью. При этом если уравнения (7.14), (7.15), записать в изображениях и преобразовать к виду 2 K E ( s ) = E0 ( s ) − ∑ ni µ i ( s ), 3ε 0 i =1
µ k ( s) = α k ( s ) E ( s), k = 1, K ,
(7.17)
qk2 mk , α k ( s) = 2 s + 2bk s + ω02k где s − комплексная переменная; µk(s), E(s) и E0(s) − изображения по Лапласу функций µk(t), E(t) и E0(t); αk(s) − передаточная функция, то струк114
турную схему процесса поляризации диэлектрика можно представить в виде, показанном на рис. 7.1.
Рис. 7.1. Структурная схема процесса упругой электронной поляризации диэлектрика.
Важно отметить, что как для системы (7.17), так и для структурной схемы (рис. 7.1), можно записать уравнение "кибернетической связи" типа выход-вход между напряженностями внутреннего и внешнего полей, а именно: 1 , (7.18) E ( s ) = W ( s ) E0 ( s ),W ( s ) = 2 K 1+ ∑ niα i ( s) 3ε 0 i =1 где W(s) − передаточная функция "связи". Значение передаточной функции W(s) состоит еще и в том, что с ее помощью, путем замены s→jω, можно получить выражение вида: 1 W ( jω ) = . (7.19) 2 K 1+ ∑ niα i ( jω ) 3ε 0 i =1 Однако при исследовании свойств диэлектриков данное частотное соотношение и ему подобные не применяются, поскольку в физике общепринято использовать функцию ε(jω) − комплексную диэлектрическую проницаемость материала, обратную функции W(jω), − например, функциональные зависимости (7.9), (7.10). Таким образом, на основании уравнения (7.19) будет иметь место новая функциональная зависимость 2 K (7.20) ε ( jω ) = 1 + ∑ niα i ( jω ) , 3ε 0 i =1 которую в дальнейшем будем называть кибернетической моделью процесса поляризации, а для расчета ε будем использовать формулу: 2 K (7.21) ε = 1+ ∑ niα i . 3ε 0 i =1 115
Вариативность параметрического синтеза Известно, что в диапазоне ближних инфракрасных, видимых и ультрафиолетовых частот внешнего поля диэлектрическая проницаемость материала определяется исключительно упругой электронной поляризацией ионов, поскольку на этих частотах другие ее виды не проявляются из-за своей инерционности. Кроме того, для расчета частотных характеристик ε(jω) с использованием моделей вида (7.10), (7.20) в указанном частотном диапазоне и в соответствии с уравнением типа (7.12) требуется предварительно определить числовые значения таких параметров как заряд, масса, коэффициент затухания и частота собственных колебаний электронного облака каждого вида ионов, составляющих диэлектрик. Первый вариант. С одной стороны, для системы уравнений (7.12), описывающей процесс упругой электронной поляризации, предлагается использовать следующие значения qk и mk: qk = e, mk = me , (7.22) где e и me − заряд (1,6021892⋅10−19 Кл) и масса (0,9109534⋅10−30 кг) электрона. При этом, значения частот собственных колебаний ω0k определяются через коэффициент квазиупругой связи, обусловленной силой кулоновского взаимодействия электрона с единично заряженным ядром, вида e2 2 , (7.23) ω0 k = 4πε 0 me rk3 где rk − ионные радиусы, а величины коэффициентов затухания bk рассчитываются по излучению элементарных электронных диполей следующим образом: µ 0 e 2ω02k , (7.24) 2bk = 6πme c где µ0 − магнитная постоянная (12,5663706144⋅10−7 Гн/м); c − скорость света в вакууме (2,99792458⋅108 м/с). Второй вариант. С другой стороны, поскольку электронные облака ионов обычно содержат более одного электрона, то это, видимо, необходимо учитывать в расчетах. Электронные поляризуемости ионов значительно возрастают с ростом их радиусов, поскольку наибольшее смещение под действием поля испытывают внешние (оптические) электроны вследствие уменьшения притяжения между ними и ядром. Внутренние электроны находятся гораздо ближе к ядру, и, кроме того, на них действует более высокий эффективный заряд, поэтому их поляризация весьма несущественна по сравнению с поляризацией внешних электронов. Поэтому для описания электронной поляризации иона k-й разновид116
ности можно воспользоваться уравнением колебаний его оптической оболочки относительно экранизированного атомного остатка с эффективным зарядом − Qke. При этом заряд и масса электронного облака обусловливаются числом электронов Zk, входящих в состав оптической оболочки: qk = Z k e, mk = Z k me . (7.25) В рамках такого подхода параметры ω0k и bk следует вычислять по формулам: Qk e 2 µ 0 Z k e 2ω02k 2 . (7.26) ω0 k = , 2bk = 4πε 0 me rk3 6πme c Вычислительный эксперимент С целью оценки эффективности каждой из рассматриваемых математических моделей, во-первых, был проведен вычислительный эксперимент, связанный с определением диэлектрической проницаемости конденсированных материалов, а именно − с расчетом вещественных частотных характеристик ε(jω) − ε′ по функциональным зависимостям (7.10), (7.20), преобразованных к виду: 2 K (ω02i − ω 2 )ni qi2 mi 1 K (ω02i − ω 2 )ni qi2 mi 1 − 1 + ∑ ∑ 2 2 2 2 2 2 2 2 2 2 i =1 (ω i =1 (ω 3 ε ω ) 4 ω 3 ε ω ) 4 ω b b − + − + − i i 0 0i 0 0i ε′ = 2 2 2biωni qi2 mi 1 K (ω02i − ω 2 )ni qi2 mi 1 K + 1 − ∑ ∑ 2 2 2 2 2 2 2 2 2 2 i =1 (ω i =1 (ω 3 ε ω ) 4 ω 3 ε ω ) 4 ω b b − + − + 0 i i 0i 0 0i (7.27) 2 2 K 1 2biωni qi mi 2 ∑ 2 2 2 2 2 i =1 (ω ε ω ω 3 ) 4 b − + 0 i 0i − 2 2 , 2 2 2 2 K K (ω0i − ω )ni qi mi + 1 2biωni qi mi 1 1 − ∑ ∑ 2 2 2 2 2 2 2 2 2 2 i = i = 1 1 3ε 0 (ω0 i − ω ) + 4bi ω 3ε 0 (ω0 i − ω ) + 4bi ω 2 K (ω02i − ω 2 )ni qi2 mi , (7.28) ε′ =1+ ∑ 3ε 0 i =1 (ω02i − ω 2 ) 2 + 4bi2ω 2 а во-вторых, было выполнено сравнение полученных кривых с данными физического эксперимента.Исходные данные для кристалла NaCl, необходимые для проведения вычислительного эксперимента, приведены в табл. 7.1. Таблица 7.1. Ион k Zk Qk nk rk (A) + 0,98 Na 1 8 9 2.2311⋅1028 2 8 7 1,81 Cl− 2.2311⋅1028 117
Результаты вычислительного эксперимента для различных вариантов параметрического синтеза коэффициентов ω0k и bk представлены: по уравнениям (7.11), (7.22), (7.23), (7.24) и (7.27) − на рис. 7.2a; по уравнениям (7.11), (7.22), (7.23), (7.24) и (7.28) − на рис. 7.2b; по уравнениям (7.11), (7.25), (7.26) и (7.27) − на рис. 7.2с; по уравнениям (7.11), (7.25), (7.26) и (7.28) − на рис. 7.2d, где эксперимент – сплошная линия.
Рис. 7.2. Моделирование ε′ для NaCl.
Представленные результаты показывают существенное преимущество кибернетической модели по сравнению с моделью КлаузиусаМосотти. Действительно, по крайней мере в области электронной упругой поляризации диэлектриков модель, построенная с использованием кибернетического принципа – обратных связей, дает практически минимальный уровень отклонений между результатами теоретических расчетов и экспериментальными данными. 7.2 Длинноволновый спектр оптического показателя преломления воды Вода является самым распространенным природным диэлектриком, вызывающим неослабевающий интерес к всесторонним исследованиям его свойств. Именно это обстоятельство обусловливает наличие достаточно полного набора данных физических экспериментов, позволяющего 118
достоверно оценить адекватность существующих и предлагаемых математических моделей, описывающих поляризационные процессы, происходящие в аналогичных материалах. Кибернетическая модель процесса поляризации диэлектрика В п. 7.1 рассмотрено построение математической модели процесса упругой электронной поляризации конденсированных диэлектриков, полученной с помощью выделения обратных связей. Проведенные вычислительные эксперименты, направленные на имитационное моделирование поляризационных характеристик ряда ионных кристаллов, показали наибольшую адекватность предложенной кибернетической модели диэлектрической проницаемости материалов реальным физическим свойствам по сравнению с другими подобными уравнениями. Однако использование традиционных подходов для расчета параметров процессов оказалось недостаточно эффективным с точки зрения величины отклонения моделируемых спектров от результатов их практических измерений. В диапазоне частот установления электронной поляризации ионов динамическая модель процесса поляризации воды, учитывая однотипность ионного состава H2O, может быть описана уравнением: d 2 µ e (t ) dµ e (t ) 8e 2 2 2 , (7.29) 2 β ω µ ( ) ( ) µ ( ) + + t = E t − t N e e e 0e 0 dt 2 dt me 3ε 0 где µе(t) − индуцированный электронный дипольный момент ионов О2-; βе и ω0е − соответственно коэффициент затухания и частота собственных колебаний оптической оболочки иона; e и те − заряд и масса электрона; Е0(t) − функция напряженности внешнего электрического поля; ε0 − электрическая постоянная; N − концентрация ионов кислорода. Значения параметров электронной поляризации ионов (βе и ω0е) могут быть определены аналитически с помощью следующих формул: Z эф e 2 µ 0 8e 2ω02e , (7.30) ω0 e = ; βe = 3 12πme c 4πε 0 me ri где Zэф − эффективный заряд ядра, действующий на электроны оптической оболочки ионов, определяемый по методике Слейтора; ri − радиус оптической оболочки; µ0 − магнитная постоянная; с − скорость света в вакууме. Непосредственно на основании выражения (7.29) комплексную диэлектрическую проницаемость воды − ε(jω) можно представить в виде: 119
2 (7.31) α e ( jω ) N , 3ε 0 а через вещественную и мнимую частотные характеристики ε(jω) соответственно ε′(ω) и ε″(ω):
ε ( jω ) = 1 +
ε ( jω ) = ε ′(ω ) + jε ′′(ω ), (7.32) 2 2 α e′ (ω ) N , ε ′′(ω ) = α e′′(ω ) N , 3ε 0 3ε 0 где α′е(ω) и α″е(ω) − вещественная и мнимая частотные характеристики комплексной электронной поляризуемости иона. В свою очередь зависимости α′е(ω) и α″е(ω) будут иметь вид ω02e − ω 2 2 , α e′ (ω ) = 8e me 2 (ω0 e − ω 2 )2 + (2β eω )2 (7.33) 2 β ω e α e′′(ω ) = 8e 2 me 2 . 2 2 (ω0 e − ω ) + (2β eω )2
ε ′(ω ) = 1 +
Уравнение оптического показателя преломления Изучение влияния структуры и химического состава вещества на поляризационные свойства можно проводить на основе анализа спектров его оптического показателя преломления − n, характеризующего, во сколько раз уменьшается скорость света в рассматриваемой среде по отношению к его скорости в вакууме. Известно, что электрическая составляющая светового потока гораздо существеннее магнитной, т.е. преломление света определяется преимущественно электрической поляризацией частиц, составляющих диэлектрик. Таким образом, для отображения зависимости n(ω) можно использовать уравнение вида: 2 2 ε ′(ω ) + (ε ′(ω ) ) + (ε ′′(ω ) ) n(ω ) = . (7.34) 2 Необходимо отметить, что при исследовании оптических свойств материалов традиционно более распространены не частотные характеристики, а аналогичные им длинноволновые спектры, переход к которым осуществляется с помощью пересчета значений рассматриваемого диапазона круговых частот в эквивалентные длины волн по формуле: λ=2πс/ω. Результаты моделирования длинноволнового спектра показателя преломления воды, полученного на основании уравнений (7.30), (7.32) – (7.34) в области установления процессов ее упругой электронной поляри120
зации, соответствующей длинам волн от 1 нм до 1 мкм, представлены на рис. 7.3, где точками отмечены данные физического эксперимента, отраженные в табл. 7.2. При этом, кроме физических констант, в расчетах были использованы следующие значения: Zэф=3,85; ri=1,32 Å; N=3,3331⋅1028 м-3.
Рис. 7.3. Длинноволновый спектр оптического показателя преломления воды, рассчитанный на основании модели (7.6).
Таблица 7.2.
λ (мкм) 0,200 0,300 0,400
n 1,396 1,349 1,339
λ (мкм)
n 1,335 1,332 1,331
0,500 0,600 0,700
λ (мкм) 0,800 0,900 1,000
n 1,329 1,328 1,327
Рассмотрение рассчитанного спектра показало, что в области фазового перехода, соответствующего явлению электронного резонанса оптической оболочки, его вид не адекватен реальным оптическим свойствам вещества. Устранение причины, вызывающей данное обстоятельство, требует использования первого слагаемого в уравнении (7.34), взятого по абсолютной величине: n(ω ) =
ε ′(ω ) +
(ε ′(ω ) )
2
+ (ε ′′(ω ) )
2
. (7.35) 2 Результаты моделирования спектра показателя преломления воды, полученного с учетом уравнения (7.35), приведены на рис. 7.4, на котором пунктирная линия соответствует расчетам n(ω) по модели (7.34). Оценка изменения вида моделируемой характеристики, достигнутого при введении модуля в уравнение оптического показателя преломления, показала, что внешний вид спектра становится качественно адекватным реальным свойствам вещества и соответствует физической картине взаимодействия заряженных частиц с электромагнитным полем света, но остает121
ся недостаточно эффективным с количественной точки зрения. Определение параметров βе и ω0е на базе ионных радиусов Поскольку вода, подобно подавляющему большинству конденсированных неорганических соединений, может рассматриваться как совокуп-
ность ионов, составляющих ее молекулу, то для определения значений ri обычно используются ионные радиусы. Рис. 7.4. Длинноволновый спектр оптического показателя преломления воды, рассчитанный на основании модели (7.35).
Необходимо отметить, что эти данные представляют собой условные величины, позволяющие при их суммировании получить достаточно точные межъядерные расстояния молекул различных химических соединений. Особенность такого подхода к определению параметров поляризационных процессов, см. уравнения (7.30), заключается в существовании целого ряда таблиц ионных радиусов, содержащих различные значения ri для иона кислорода, которые колеблются от 1,32 до 1,40 Å. Наиболее известны классические таблицы по Гольдшмидту и по Полингу, а также современные данные по Бокию и Белову, по Шеннону и Прюитту. Результаты моделирования длинноволновых характеристик показателя преломления воды, полученного для различных значений радиуса иона О2, приведены на рис. 7.5, где 1 − кривая спектра для радиуса иона кислорода по Гольдшмидту (1,32 Å); 2 − спектр по Бокию и Белову (1,36 Å); 3 − спектр по Полингу и по Шеннону и Прюитту (1,40 Å). Оценка полученных графиков продемонстрировала, что использование всего набора таблиц ионных радиусов принципиально не улучшает порядок величины отклонения моделируемых характеристик от их реальных аналогов. 122
Анализ рассчитанных кривых на фоне результатов экспериментальных измерений показателя преломления воды (рис. 7.6) позволил установить их следующее очевидное различие. Расчетный спектр включает только один резонанс, т.к. в случае использования величины ионного радиуса предполагается, что все электроны оптической оболочки движутся по одной орбите.
Рис. 7.5. Спектры оптического показателя преломления воды.
Рис. 7.6. Длинноволновая характеристика оптического показателя преломления воды в широкой области спектра.
Соответствующий же участок реального спектра (см. пунктир на рис. 7.6) содержит целый ряд всплесков, характерных для сложной конфигурации электронного облака. Таким образом, повышение эффективности моделирования может быть связано с учетом электронной конфигурации оптических оболочек ионов. Учет электронной конфигурации ионов на базе модели Бора Для определения радиусов электронных орбит, составляющих оптические оболочки ионов, можно взять модель строения атома по Бору. Согласно этой модели, используемой применительно к водородоподобным атомам, радиус орбиты электрона рассчитывается по формуле 123
k 2h 2 , (7.36) rk = me Ze 2 где k − главное квантовое число электронной оболочки; ћ − постоянная Планка; Z − порядковый номер атома, эквивалентный его заряду. В случае рассмотрения электронной конфигурации иона, с учетом эффекта экранизации его ядра внутренними электронными оболочками, для определения радиусов орбит предлагается использовать выражение: k 2h 2 rl = , l = 1, K , (7.37) me Z эф l e 2
где l − индекс электронной орбиты оптической оболочки иона; K − число орбит, эквивалентное количеству пар электронов, составляющих рассматриваемую оболочку. Величины Zэф l могут рассчитываться на основании методики, предложенной Слейтором, согласно которой: вклад электронов, внешних по отношению к группе X (предполагается, что орбиталь принадлежит некоторой группе X), равен 0; вклад электронов из группы X равен 0,30, если это s1-электроны, и 0,35 – в остальных случаях; если рассматриваемые электроны находятся на sk- или pk-орбиталях группы X, то вклад каждого из электронов, расположенных на внутренних орбиталях с главным квантовым числом k-1, равен 0,85, а вклады электронов, находящихся на орбиталях с главным квантовым числом k-2, k-3, … равны 1,00; если рассматриваются электроны, расположенные на dk- или fk-орбиталях группы X, то вклад каждого из электронов для групп, предшествующих рассматриваемой, равен 1,00. Схема электронной конфигурации молекулы H2O, построенная на базе модифицированной формулы Бора вида (9) и методики Слейтора для определения величины эффективного заряда, представлена на рис. 7.7. C учетом сложного строения оптической оболочки ионов кислорода, процесс упругой электронной поляризации воды можно описать уравнениями вида: 2e 2 2 4 d 2 µ l (t ) dµ l (t ) 2 , + + = E t − ( t ) N β ω µ µ 2 ( t ) ( ) ∑ 0l 0 l l i me 3ε 0 i =1 dt 2 dt (7.38) l = 1,4. На базе (7.38) частотные характеристики комплексных диэлектрической проницаемости и поляризуемостей электронных орбит будут вида:
124
ε ′(ω ) = 1 +
2 4 2 4 ′ ′ ′ N ( ) , ( ) α ω ε ω = ∑ i ∑ α i′′(ω )N , 3ε 0 i =1 3ε 0 i =1
ω02l − ω 2 , l = 1,4, α l′(ω ) = 2e me 2 (ω0l − ω 2 )2 + (2β lω )2 2β lω α l′′(ω ) = 2e 2 me 2 , l = 1,4. (ω0l − ω 2 )2 + (2β lω )2 2
(7.39)
Результаты моделирования спектра показателя преломления воды,
полученного на базе системы уравнений (7.38), приведены на рис. 7.8. Рис. 5. Расчетная модель электронной конфигурации молекулы воды, полученная на базе модели Бора.
Рис. 7.8. Результаты моделирования длинноволнового спектра показателя преломления воды по уравнениям (7.38). 125
Анализ полученной характеристики на фоне результатов экспериментальных измерений показателя преломления воды (рис. 7.6) свидетельствует о качественном улучшении адекватности расчетного спектра. При этом был получен образ резонанса s-орбитали (для λ=10 нм), полностью эквивалентный данным физического эксперимента. Однако образы резонансов остальных трех орбит p-орбитали оказались в области длин волн, расположенных несколько левее истинных. Кроме того, правая часть графика, соответствующая установившемуся режиму, показала, что значения показателя преломления воды, рассчитанные в соответствии с параметрами процессов электронной поляризации ионов, определяемых с помощью модели строения атома по Бору, ниже реальных. Модификация методики расчета поляризационных параметров Известно, что присоединение электронов к невозбужденному атому, происходящее при образовании иона, приводит к изменению электронной конфигурации его оптической оболочки, вызванному переходом электронов на более выгодные энергетические уровни. Поэтому для расчета радиусов орбит p-орбитали предлагается использовать формулу: (k + 1) 2 h 2 , l = 2,4 . (7.40) rl = me Z эф l e 2 Результаты моделирования спектра показателя преломления воды, полученные с учетом перехода электронов p-орбитали на орбиты следующей электронной оболочки, приведены на рис. 7.9.
Рис. 7.9. Результаты моделирования длинноволнового спектра показателя преломления воды, полученные с учетом перехода электронов.
Анализ полученных изменений показал, что моделируемый спектр стал более адекватен его истинному аналогу. Однако его правая часть превысила экспериментальные данные. Известно, что в разных химических соединениях один и тот же ион обладает различной величиной эффективного заряда, действующего на его молекулярных соседей. Учиты126
вая данное обстоятельство, для расчета Zэф, действующего на электронные орбиты иона, предлагается несколько модифицировать методику Слейтора, оставив ее без изменений применительно к электронам, эквивалентным невозбужденному состоянию атома. Нужно подобрать такие значения для экранирующих вкладов оптических электронов, которые позволят добиться наибольшей эффективности моделирования рассматриваемого спектра. Решение поставленной задачи параметрического синтеза, выполненное в рамках проведения вычислительного эксперимента, дало следующий результат: наибольшая адекватность моделируемого спектра данным практических измерений (рис. 7.10) достигается при значениях экранирующих вкладов 2s-электронов и 3p-электронов, равных соответственно 0,80 и 0,15.
Рис. 7.10. Результаты моделирования длинноволнового спектра показателя преломления воды, полученные на базе параметрического синтеза.
Оценка эффективности предлагаемой методики показала, что в ее рамках моделируемый спектр стал полностью адекватен его истинному аналогу. Использование уравнения зависимости n(ω) вида (7.35), модели процесса упругой электронной поляризации вещества, учитывающей электронную конфигурацию ионов (7.38), и модифицированной методики Слейтора для определения величины эффективного заряда ядра, действующего на оптические электроны, позволило аналитически получить длинноволновый спектр показателя преломления воды (рис. 7.10), практически эквивалентный экспериментальным данным (рис. 7.6). Рассмотренная возможность применения модифицированной формулы Борна для определения радиусов электронных орбит сделала подход к решению задачи моделирования поляризационных характеристик материалов более системным, поскольку отпала необходимость в использовании таблиц ионных радиусов.
127
7.3. Оптический спектр воды в области упругих ионных поляризаций Хорошо известно, что используемые математические модели, позволяющие описать поляризацию молекулярной воды, имеют вид следующей системы уравнений: d 2 µ v (t ) dµ v (t ) e2 2 dt 2 + 2bv dt + ω0 v µ v (t ) = M E (t ), OH 2 d µ d (t ) dµ d (t ) e2 2 + 2bd + ω0 d µ d (t ) = E (t ), v = 1, 2, d = 1,2, (7.41) 2 dt dt M OH 2 K ( ) ( ) E t = E t − N i µ i (t ), ∑ 0 i =1 3 ε 0 где µν (t ) и µ d (t ) – индуцированные дипольные моменты, обусловленные валентными и деформационными колебаниями связей OH; bν и bd – соответствующие коэффициенты затухания колебаний; ω0ν и ωd – собственные частоты колебаний; e – величина элементарного заряда; MOH – приведенная масса связи OH; E(t) – функция напряженности эффективного поля; К – число разновидностей поляризационных процессов; Ni – концентрация частиц. Эффективность применения модели (7.41) была оценена в рамках проведения вычислительного эксперимента, направленного на моделирование длинноволнового спектра оптического показателя преломления воды, соответствующих областей аргумента. Результаты моделирования отражены на рис. 7.11, на котором точечный массив соответствует данным физического эксперимента, а сплошная линия представляет собой моделируемую характеристику.
Рис. 7.11. Физический и моделируемый спектры показателя преломления воды. 128
Анализ графиков показал, что моделируемый спектр достаточно адекватен оптическим свойствам воды в области валентных колебаний молекулы H2O. Однако в диапазоне установления деформационных видов ее ионной поляризации наблюдаются существенные отклонения реальных и расчетных характеристик. Валентные колебания воды Известно, что упругая ионная поляризация молекулы воды обусловлена двумя видами колебаний, связанными с трансформацией внутренних координат соответствующих ее ионов. К ним относятся валентные колебания – смещения, отвечающие линейным изменениям связей OH; деформационные колебания – изменение валентных углов. Под действием внешнего электрического поля происходит линейное смещение ионов молекулы воды. При этом ионы водорода смещаются по направлению поля, иона кислорода – в противоположном направлении. Составим уравнение балансов сил относительно линий поля для линейного смещения связи OH: ma1 = Fэдс1 − Fсопр13 − Fупр13 , − Ma3 = − Fэдс 3 + Fсопр 31 + Fупр 31 , ma2 = Fэдс 2 − Fсопр 23 − Fупр 23 , − Ma = − F + F + Fупр 32 , эдс 3 сопр 32 3
(7.42)
где m и M – массы соответственно водорода и кислорода; Fэдс1, Fэдс2, Fэдс3 – электродвижущие силы; Fсопр13 = Fсопр 31 и Fсопр 23 = Fсопр 32 – силы сопротивления; F упр13= Fупр 31 и Fупр 23 = Fупр 32 – квазиупругие силы. Учитывая физические сущности каждой из сил, получаем уравнения вида:
129
2 d x1 m dx1 m dt 2 + τ dt + k упр1 ( x1 + x3 ) = eE (t ), 1 2 d x3 M dx3 M dt 2 + τ dt + k упр1 ( x1 + x3 ) = 2eE (t ), 1 (7.43) 2 m d x2 + m dx2 + k ( x + x ) = eE (t ), упр 2 2 3 dt 2 τ 2 dt 2 d M x3 + M dx3 + k ( x + x ) = 2eE (t ), упр 2 3 2 dt 2 τ 2 dt где x1 и x2 – смещение ионов водорода; x3 – смещение иона кислорода; m и M – массы соответственно иона водорода и иона кислорода; kупр1 и kупр2 – коэффициент упругости каждой из связей молекулы H2O; E (t ) – функция напряженности эффективного поля, действующая внутри поляризованного образца. Разделив каждый член системы (7.43) на m и M соответственно и объединив попарно уравнения колебания каждой из связей OH, получим:
1 d 2 ( x1 + x3 ) 1 d ( x1 + x3 ) 1 ( x1 + x3 ) = + + + k 1 упр 2 dt dt τ1 m M 1 2 = + m M eE , 2 d ( x 2 + x3 ) + 1 d ( x 2 + x3 ) + k 1 + 1 ( x + x ) = упр 2 2 3 dt 2 dt τ2 m M = 1 + 2 eE . m M
(7.44)
Введем в рассмотрение следующие обозначения: 1 1 1 M +m 1 + = , ( ) , µ x x e = + = = 2b1 , 1 3 1 m M τ1 mM M OH k упр 1 = ω 2 , ( x + x ) e = µ , 1 = 2b , k упр 2 = ω 2 , 01 2 3 2 2 02 M OH τ2 M OH
(7.45)
где µ1 , µ2 – индуцированные дипольные моменты каждой связи OH; b1, b2 – соответствующие коэффициенты затухания; ω01 , ω02 – соответствующие собственные частоты. 130
Подставив значения (7.45) в выражения (7.44), получим систему: 2m + M dµ1 d µ1 2 ω µ + 2 + = eE , b 1 01 1 dt 2 dt mM (7.46) 2 µ µ + 2 d m M d 2 2 2 dt 2 + 2b2 dt + ω 02 µ 2 = mM eE . Система дифференциальных уравнений (7.46) позволяет описывать валентные колебания молекулы воды. Так как было учтено, что ион кислорода имеет заряд, равный (-2e), то полученная модель отличается от ранее рассматриваемой модели (7.41) правой частью уравнений. 2
Деформационные колебания молекулы воды К упругим деформационным колебаниям молекулы воды относятся изменения валентных углов связи OH. Составим уравнение балансов сил относительно линий силового поля для радиально смещенных связей OH, получим систему уравнений: maτ 1 sin( β − θ1 ) = Fэдс1 − Fсопр1 sin( β − θ1 ) − Fупр1 sin( β − θ1 ), maτ 2 sin(α − β − θ 2 ) = Fэдс 2 − Fсопр 2 sin(α − β − θ 2 ) − − F sin(α − β − θ ), 2 упр 2
(7.47)
где Fэдс1, Fэдс2 – электродвижущая сила ионов водорода, в каждой из связей; Fсопр1 и Fсопр2 – силы сопротивления иона водорода в каждой из связей OH; Fупр1 и Fупр2 – сила упругости иона водорода; Fупр1 и Fупр2 – сила упругости иона кислорода; α – табличный угол между связями; β – исходный угол наклона одной из связей OH. Распишем каждую из сил, входящих в уравнение (7.47), для нашего случая с помощью перехода от линейной величины x к угловой θ следующим образом: x = иR . d 2θ1 m dx1 m Rdθ1 ε = = = = = , , , a R R F eE F эдс сопр τ 1 1 1 1 τ 1 dt τ 1 dt dt 2 d 2 x2 (7.48) Fупр1 = k упр1 x1 = k упр1 Rθ1 , aτ 2 = Rε 2 = R 2 , Fэдс 2 = eE , dt m dx2 m Rdθ 2 = F сопр 2 τ dt = τ dt , Fупр 2 = k упр 2 x2 = k упр 2 Rθ 2 , 2 2 131
где R – длина связи OH; ατ 1 и ατ 2 – тангенциальные составляющие угловых ускорений ионов водорода. Поскольку углы и1 и θ 2 очень малы, то sin( β − θ 1 ) ≅ sin β , sin(α − β − θ 2 ) ≅ sin(α − β ) и d 2θ1 mR dθ1 sin β = eE , mR + + k R θ упр 1 1 2 dt dt τ 1 2 mR d θ 2 + mR dθ1 + k Rθ sin(α − β ) = eE. упр 2 2 dt 2 τ 2 dt
(7.49)
Разделим каждый член уравнений системы (7.49) на величины mR, получим: d 2θ1 1 dθ1 k упр1 e + E, θ1 sin β = 2 + m mR τ 1 dt dt 2 d θ 2 + 1 dθ1 + k упр 2 θ sin(α − β ) = e E. 2 dt 2 τ dt m mR 2
(7.50)
Выполним переход к значениям коэффициентов их затухания и собственным частотам: d 2θ1 1 dθ1 k упр1 e + + sin = E, θ β 2 1 dt dt m mR τ 1 (7.51) 2 d θ 2 + 1 dθ1 + k упр 2 θ sin(α − β ) = e E. 2 dt 2 τ dt m mR 2 Представив индуцированные дипольные моменты связей OH как изменение проекции их собственных электрических моментов на силовые линии поля, получим систему уравнений: µ1 = µ 0 cos( β − θ 1 ) − µ 0 cos β , (7.52) cos( ) cos( ). µ µ α β θ α β = − − − − 2 0 2 Преобразуем (7.52) с помощью тригонометрических формул: µ1 = µ 0 [cos β cosθ 1 + sin β sin θ1 − cos β ], (7.53) [ ] cos( ) cos sin( ) sin cos( ) . µ µ α β θ α β θ α β = − + − − − 2 0 2 2 Учитывая, что углы θ малы, можно использовать приближения cosθ ≅ 1 , sin θ ≅ θ . Тогда: µ1 = θ µ 0 sin β , µ 2 = θ 2 µ 0 sin(α − β ). (7.54) 1
132
Выполним переход от θ к µ , для чего помножим каждый член системы (7.51) на величину собственного дипольного момента связи OH: 2 dµ1 еµ 0 d µ1 2 b 2 E, + + = ω µ 1 01 1 dt 2 dt mR (7.55) 2 d d e µ µ µ 2 2 0 2 dt 2 + 2 b2 dt + ω 02 µ 2 = mR E .
Учитывая, что mR 2 = J и µ 0 = eR получим: d 2 µ1 dµ1 µ0 2 b E, ω µ + 2 + = 1 01 1 dt 2 dt J (7.56) 2 2 d µ 2 + 2b d µ 2 + ω 2 µ = µ 0 E , 2 02 2 dt 2 dt J где J – момент инерции связи OH. Система уравнений (7.56) позволяет описать деформационные колебания молекулы H2O, где в качестве переменной рассматривается угловое смещение, а не традиционно – линейное. 2
Вычислительный эксперимент Для оценки эффективности полученных математических моделей был проведен вычислительный эксперимент, связанный с моделированием длинноволнового спектра оптического показателя преломления воды в области установления упругой ионной поляризации воды. Поскольку контрольные сведения о рассматриваемой характеристике обычно представляют собой табличные зависимости ее значений от длины волны прилагаемого электромагнитного излучения λ , то моделировался длинноволновый спектр n(λ ) . Методика проведения вычислительного эксперимента включала несколько этапов. Во-первых, на базе выражений (7.46) и (7.56), а также набора значений 13 b = 7,5346 ⋅ 10 рад / с, v1 0v1 14 13 = 6,4421 ⋅ 10 рад / с, b = 7,5346 ⋅ 10 рад / с, ω v2 0v 2 14 13 = 6,1219 ⋅ 10 рад / с, b = 7,5346 ⋅ 10 рад / с, ω d1 0d1 14 13 = 3,0892 ⋅ 10 рад / с, = 1,4127 ⋅ 10 рад / с b ω d2 0d 2
ω
14 = 6,5739 ⋅ 10 рад / с,
(7.57)
рассчитывались частотные характеристики комплексных ионных поляризуемостей молекулы H2O для диапазона длин волн от 10-6 до 3.10-4 м, ко133
торый соответствует области установления рассматриваемого вида поляризации. Во-вторых, на основании полученных числовых массивов рассчитывались частотные характеристики комплексной диэлектрической проницаемости воды в рамках кибернетической модели. В-третьих, с помощью уравнения ε ′(ω ) + ε ′ 2 (ω ) + ε ′′ 2 (ω ) , (7.58) n(ω ) = 2 вычислялась частотная зависимость оптического показателя преломления, значения аргумента которой пересчитывались затем в эквивалентные длины волн по формуле λ = 2πc / ω для получения требуемого длинноволнового спектра n(λ ) . В-четвертых, строились совместные графики аналитически найденной характеристики и ее физического аналога. Характеристики исследуемого свойства воды, полученные в ходе проведенного вычислительного эксперимента, представлены на рис. 7.12. На приведенном графике, точечный массив соответствует практическим измерениям зависимости n(λ ) , сплошная линия отражает результаты имитационного моделирования. Анализ полученных результатов показал, что моделируемый спектр достаточно адекватен реальным оптическим свойствам воды в области упругих ионных колебаний молекулы воды H2O.
Рис. 7.12. Длинноволновый спектр оптического показателя воды на основе модели (7.46) и (7.56).
Проведенное моделирование спектра оптического показателя преломления воды показало, что применение моделей (7.46) и (7.56) более эффективно, чем описание вида (7.41). 134
БИБЛИОГРАФИЧЕСКИЙ СПИСОК
1. Бесекерский В.А., Попов Е.П. Теория систем автоматического регулирования. М.: Наука, 1975. 2. Математические основы теории автоматического регулирования. Т.1 / Под ред. Б.К. Чемоданова. М.: Высш. школа, 1977. 3. Математические основы теории автоматического регулирования. Т.2 / Под ред. Б.К. Чемоданова. М.: Высш. школа, 1977. 4. Методы классической и современной теории автоматического управления. Т.1: Методы современной теории автоматического управления / Под ред. Н.Д. Егу-пова. М.: Изд-во МГТУ им. Н.Э. Баумана, 2000. 135
5. Методы классической и современной теории автоматического управления. Т.2: Синтез регуляторов и теория оптимизации систем автоматического управления / Под ред. Н.Д. Егупова. М.: Изд-во МГТУ им. Н.Э. Баумана, 2000. 6. Методы классической и современной теории автоматического управления. Т.3: Анализ и статистическая динамика систем автоматического управления / Под ред. Н.Д. Егупова. М.: Изд-во МГТУ им. Н.Э. Баумана, 2000. 7. Первозванский А.А. Математические модели в управлении производством. М.: Наука, 1975. 8. Справочник по теории автоматического управления / Под ред. А.А. Красовского. М.: Наука, 1987. 9. Гультяев А.К. MATLAB-5.2. Имитационное моделирование в среде Windows: практическое пособие. М.: Наука. 2000. 10. Дьяконов В., Круглов В. Математические пакеты расширения MATLAB. Специальный справочник. СПб.: Питер, 2001. 11. Еремин Е.Л. Лабораторно-курсовой практикум по ТОАУ с применением MatLab for Windows. Благовещенск: Изд-во АмГУ, 2001. 12. Основы математического моделирования. Построение и анализ моделей с примерами на языке MATLAB / Под ред. А.Л. Фрадкова. СПб.: Изд-во БГТУ, 13. Потемкин В.Г., Рудаков П.И. Система MATLAB-5 для студентов. 2-е изд., испр. и дополн. М.: ДИАЛОГ – МИФИ, 1999. 14. Еремин И.Е., Еремин Е.Л., Костюков Н.С. Имитационное моделирование диэлектрической проницаемости конденсированных материалов: ультрафиолето-вый и видимый спектры частот. Благовещенск: Изд-во АмурКНИИ АНЦ ДВО РАН, 2001. 15. Банышева В.В., Костюков Н.С. Упругая дипольная поляризация // Дальневосточный вестник высшего образования. 2001. №1. С. 62 – 69. 16. Костюков Н.С., Банышева В.В. Поляризационные процессы в воде // Электричество. 2001. №11. С. 66-69 17. Еремин И.Е., Костюков Н.С. Построение модели процесса поляризации диэлектриков с помощью обратных связей // Информатика и системы управления. 2001. № 1. С. 45-53. 18. Еремин И.Е., Костюков Н.С. Построение кибернетической модели оптического показателя преломления // Информатика и системы управления. 2001. № 2. С. 42-49. 19. Банышева В.В., Еремин И.Е., Костюков Н.С. Моделирование длинноволнового спектра оптического показателя преломления воды // Информатика и системы управления. 2002. № 1(3). С. 14-23. 20. Еремина В.В., Костюков Н.С., Тюрина С.Ю. Моделирование оптического спектра воды в области упругих видов поляризации // Информатика и системы управления. 2003. № 2(6). С. 9-14. 21. Костюков Н.С., Еремин И.Е. Кибернетическая модель процесса упругой электронной поляризации диэлектрика // Электричество. 2004. № 1. С. 50-54.
136
Евгений Леонидович ЕРЕМИН профессор кафедры информатики БГПУ, доктор технических наук Виктория Владимировна ЕРЕМИНА доцент кафедры информационных и управляющих систем АмГУ, кандидат физико-математических наук Марина Сергеевна КАПИТОНОВА ассистент кафедры информатики БГПУ МАТЕМАТИЧЕСКОЕ И КОМПЬЮТЕРНОЕ МОДЕЛИРОВАНИЕ Учебное пособие
137