Difference between revisions of "Comparison of solitons and waves"
From Department of Theoretical and Applied Mechanics
(Created page with "Кафедра ТМ > Проект "Термокристалл" > Compare soliton with wave <HR> Виртуальная лаборатория > Compare...") |
|||
(4 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
− | [[ТМ|Кафедра ТМ]] > [[Проект "Термокристалл"]] > [[Compare soliton with wave]] <HR> | + | [[ru:Сравнение солитона с волной]] |
− | [[Виртуальная лаборатория]] > [[Compare soliton with wave]] <HR> | + | <!--[[ТМ|Кафедра ТМ]] > [[Проект "Термокристалл"]] > [[Compare soliton with wave]] <HR> |
+ | [[Виртуальная лаборатория]] > [[Compare soliton with wave]] <HR>--> | ||
− | To | + | To demonstrate a soliton propagation, we numerically solve the Korteweg–de Vries equation. It has the form: |
::<math>\dot U + UU' + CU''' = 0</math>. | ::<math>\dot U + UU' + CU''' = 0</math>. | ||
− | + | To obtain a numerical solution we successively calculate derivatives <math>U'</math>, <math>U''</math> and <math>U'''</math>, using the central difference method: | |
::<math>U' = \frac{U_{n+1} - U_{n-1}}{2\Delta x}</math>, | ::<math>U' = \frac{U_{n+1} - U_{n-1}}{2\Delta x}</math>, | ||
::<math>U'' = \frac{U_{n+2} - 2U_{n} + U_{n-2}}{4\Delta x} \approx \frac{U_{n+1} - 2U_{n} + U_{n-1}}{2\Delta x}</math>, | ::<math>U'' = \frac{U_{n+2} - 2U_{n} + U_{n-2}}{4\Delta x} \approx \frac{U_{n+1} - 2U_{n} + U_{n-1}}{2\Delta x}</math>, | ||
::<math>U''' = \frac{U_{n+2} - 2U_{n+1} + 2U_{n-1} - U_{n-2}}{4\Delta x}</math>. | ::<math>U''' = \frac{U_{n+2} - 2U_{n+1} + 2U_{n-1} - U_{n-2}}{4\Delta x}</math>. | ||
− | + | The soliton is indicated by the <span style="color:#808">purple outline</span>, the moving wave is shown by a <span style="background-color:#0bb">turquoise gradient</span>. | |
{{#widget:Iframe |url=http://tm.spbstu.ru/htmlets/Tcvetkov/Equations/Soliton_Wave_compare_v1/Equations.html |width=830 |height=640 |border=0 }} | {{#widget:Iframe |url=http://tm.spbstu.ru/htmlets/Tcvetkov/Equations/Soliton_Wave_compare_v1/Equations.html |width=830 |height=640 |border=0 }} | ||
− | + | Coded by [[Tsvetkov Denis]], the code written by Alexander Yavorsky ([https://github.com/yavalvas/kdf-equation/blob/master/kdf_equation.cpp link]) was used to accomplish the work. | |
− | [[Category: Виртуальная лаборатория]] | + | <!--[[Category: Виртуальная лаборатория]] |
− | [[Category: Проект "Термокристалл"]] | + | [[Category: Проект "Термокристалл"]]--> |
Latest revision as of 18:53, 18 January 2017
To demonstrate a soliton propagation, we numerically solve the Korteweg–de Vries equation. It has the form:
- .
To obtain a numerical solution we successively calculate derivatives
, and , using the central difference method:- ,
- ,
- .
The soliton is indicated by the purple outline, the moving wave is shown by a turquoise gradient.
Coded by Tsvetkov Denis, the code written by Alexander Yavorsky (link) was used to accomplish the work.