CH-01 (523167), страница 6

Файл №523167 CH-01 (Pao - Engineering Analysis) 6 страницаCH-01 (523167) страница 62013-09-15СтудИзба
Просмтор этого файла доступен только зарегистрированным пользователям. Но у нас супер быстрая регистрация: достаточно только электронной почты!

Текст из файла (страница 6)

If the rotationis by an angle x or y, then {P'} = [Rx]{P} or {P'} = [Ry]{P} where [Rx] = [Tx]Tand [Ry] = [Ty]T.Having discussed about transformations and rotations of coordinate systems,we are ready to utilize the derived formulas to demonstrate the concept of animation. Motion can be simulated by first generating a series of rotated views ofa three-dimensional object, and showing them one at a time. By erasing eachdisplayed view and then showing the next one at an adequate speed, a smoothmotion of the object is achievable to produce the desired animation.

ProgramAnimate1.m is developed to demonstrate this concept of animation by using a4 2 3 brick and rotating it about the x-axis by an angle of 25° and thenrotating about the y-axis as many revolutions as desired. The front side of theblock (x-y plane) is marked with a character F, and the right side (y-z plane) ismarked with a character R, and the top side (x-z plane) is marked with a characterT for helping the viewer to have a better three-dimensional perspective of therotated brick (Figure 4).

The x-rotation prior to y-rotation is needed to tilt the topside of the brick toward the front. The speed of animation is controlled by aparameter Damping. This parameter and the desired number of y-revolutions,Ncycle, are both to be interactively specified by the viewer (Figure 5).© 2001 by CRC Press LLCFIGURE 4.

The characters F, R, and T help the viewer to have a better three-dimensionalperspective of the rotated brick.FIGURE 5. The speed of animation is controlled by a parameter Damping. This parameter andthe desired number of y-revolutions, Ncycle, are both to be interactively specified by the viewer.© 2001 by CRC Press LLCFUNCTION ANIMATE1(NCYCLE,DAMPING)Notice that the coordinates for the corners of the brick are defined in arrays xb,yb, and zb. The coordinates of the points to be connected by linear segments fordrawing the characters F, R, ant T are defined in arrays xf, yf, and zf, and xr, yr,and zr, and xt, yt, and zt, respectively.The equations in deriving [Rx] ( = [Tx]T) and [Ry] ( = [Ty]T) are applied for xand y- rotations in the above program.

Angle increments of 5 and 10° are arrangedfor the x- and y-rotations, respectively. The rotated views are plotted using the newcoordinates of the points, (xbn,ybn,zbn), (xfn,yfn,zfn), etc. Not all of these newarrays but only those needed in subsequent plot are calculated in this m file.MATLAB command clg is used to erase the graphic window before a newrotated view the brick is displayed. The speed of animation is retarded by the “hold”loops in both x- and y-rotations involving the interactively entered value of theparameter Damping. The MATLAB command pause enables Figure 4 to be readand requires the viewer to press any key on the keyboard to commence the animation.Notice that a statement begins with a % character making that a comment statement,and that % can also be utilized for spacing purpose.The xs and ys arrays allow the graphic window to be scaled by plotting themand then held (by command hold) so that all subsequent plots are using the same© 2001 by CRC Press LLCFIGURE 6.

Animation of a rotating brick.scales in both x- and y-directions. The values in xs and ys arrays also control whereto properly place the texts in Figure 4 as indicated in the text statements.QUICKBASIC VERSIONA QuickBASIC version of the program Animate1.m called Animate1.QB alsois provided. It uses commands GET and PUT to animate the rotation of the 4 3 2 brick. More features have been added to show the three principal views of thebrick and also the rotated view at the northeast corner of screen, as illustrated inFigure 6.The window-viewport transformation of the rotated brick for displaying on thescreen is implemented through the functions FNTX and FNTY. The actual rangesof the x and y measurements of the points used for drawing the brick are describedby the values of V1 and V2, and V3 and V4, respectively.

These ranges are mappedonto the screen matching the ranges of W1 and W2, and W4 and W3, respectively.The rotated views of the brick are stored in arrays S1 through S10 using theGET command. Animation retrieves these views by application of the PUT command. Presently, animation is set for 10 y-swings (Ncycle = 10 in the programAnimate1.m, arranged in Line 600). The parameter Damping described in theprogram Animate1.m here is set equal to 1500 (in Line 695).© 2001 by CRC Press LLC© 2001 by CRC Press LLC1.6 PROBLEMSMATRIX ALGEBRA1.

Calculate the product [A][B][C] by (1) finding [T] = [A][B] and then[T][C], and (2) finding [T] = [B][C] and then [A][T] where:1[A] = 425366[B] = 42531 −1−3[C ] = −2 −42. Calculate [A][B] of the two matrices given above and then take thetranspose of product matrix. Is it equal to the product of [B]T[A]T?3. Are ([A][B][C])T and the product [C]T[B]T[A]T identical to each other?© 2001 by CRC Press LLC4. Apply the QuickBASIC and FORTRAN versions of the program MatxAlgb to verify the results of Problems 1, 2, and 3.5.

Repeat Problem 4 but use MATLAB.6. Apply the program MatxInvD to find [C]–1 of the matrix [C] given inProblem 1 and also to ([C]T)–1. Is ([C]–1)T equal to ([C]T)–1?7. Repeat Problem 6 but use MATLAB.8. For statistical analysis of a set of N given data X1, X2, …, XN, it is oftennecessary to calculate the mean, m, and standard deviation, 5, by use ofthe formulas:m=1(X + X2 + … + X N )N 1and[]2221σ =  ( X1 − m ) + ( X 2 − m ) + … + ( X N − m ) N0.5Use indicial notation to express the above two equations and then developa subroutine meanSD(X,N,RM,SD) for taking the N values of X tocompute the real value of mean, RM, and standard deviation, SD.9.

Express the ith term in the following series in indicial notation and thenwrite an interactive program SinePgrm allowing input of the x value tocalculate sin(x) by terminating the series when additional term contributesless than 0.001% of the partial sum of series in magnitude:Sin x =x1 x3 x 5− + −…1! 3! 5!Notice that Sin(x) is an odd function so the series contains only terms ofodd powers of x and the series carries alternating signs. Compare theresult of the program SinePgrm with those obtained by application of thelibrary function Sin available in FORTRAN and QuickBASIC.10. Same as Problem 9, but for the cosine series:Cos x = 1 −x2 x 4 x6+−+…2! 4! 6!Notice that Cos(x) is an even function so the series contains only termsof even powers of x and the series also carries alternating signs.11.

Repeat Problem 4 but use Mathematica.12. Repeat Problem 6 but use Mathematica.© 2001 by CRC Press LLCGAUSS1. Run the program GAUSS to solve the problem:14 72583   x1   2  6  x 2  =  8 10   x3  142. Run the program GAUSS to solve the problem:04 72583  x1  −1 6 x 2  =  8 9  x3  14 What kind of problem do you encounter? “Divided by zero” is the message! This happens because the coefficient associated with x1 in the firstequation is equal to zero and the normalization in the program GAUSScannot be implemented.

In this case, the order of the given equationsneeds to be interchanged. That is to put the second equation on top orfind below the first equation an equation which has a coefficient associatedwith x1 not equal to zero and is to be interchanged with the first equation.This procedure is called “pivoting.” Subroutine GauJor has such a featureincorporated, apply it for solving the given matrix equation.3. Modify the program GAUSS by following the Gauss-Jordan eliminationprocedure and excluding the back-substitution steps. Name this new program GauJor and test it by solving the matrix equations given in Problems1 and 2.4.

Show all details of the normalization, elimination, and backward substitution steps involved in solving the following equations by application ofGaussian Elimination method:4x1 + 2x2 – 3x3 = 85x1 – 3x2 + 7x3 = 26–x1 + 9x2 – 8x3 = –105. Present every normalization and elimination steps involved in solving thefollowing system of linear algebraic equations by the Gaussian Elimination Method:5x1 – 2x2 + 2x3 = 9, –2x1 + 7x2 – 2x3 = 9, and 2x1 – 2x2 + 9x3 = 41© 2001 by CRC Press LLC6.

Характеристики

Тип файла
PDF-файл
Размер
821,54 Kb
Тип материала
Учебное заведение
Неизвестно

Список файлов книги

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