12.07.2015 Views

COPYRIGHT 2008, PRINCETON UNIVERSITY PRESS

COPYRIGHT 2008, PRINCETON UNIVERSITY PRESS

COPYRIGHT 2008, PRINCETON UNIVERSITY PRESS

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

systems of equations with matrices; data fitting 159θθθθθθFigure 8.1 Left: Two weights connected by three pieces of string and suspended from ahorizontal bar of length L. The angles and the tensions in the strings are unknown. Right: Afreebody diagram for one weight in equilibrium.good fraction of your computer’s random-access memory (RAM), we now advisethat a library routine be used whenever the matrix computations are so numericallyintensive that you must wait for results. In fact, even if the sizes of your matrices aresmall, as may occur in graphical processing, there may be library routines designedjust for that which speed up your computation.Now that you have heard the sales pitch, you may be asking, “What’s the cost?”In the later part of this chapter we pay the costs of having to find what librariesare available, of having to find the name of the routine in that library, of having tofind the names of the subroutines your routine calls, and then of having to figureout how to call all these routines properly. And because some of the libraries arein Fortran, if you are aCprogrammer you may also be taxed by having to call aFortran routine from your C program. However, there are now libraries availablein most languages.8.2 Two Masses on a StringTwo weights (W 1 ,W 2 ) = (10, 20) are hung from three pieces of string with lengths(L 1 ,L 2 ,L 3 )=(3, 4, 4) and a horizontal bar of length L =8(Figure 8.1). The problemis to find the angles assumed by the strings and the tensions exerted by the strings.In spite of the fact that this is a simple problem requiring no more thanfirst-year physics to formulate, the coupled transcendental equations that resultare inhumanely painful to solve analytically. However, we will show you how thecomputer can solve this problem, but even then only by a trial-and-error techniquewith no guarantee of success. Your problem is to test this solution for a variety ofweights and lengths and then to extend it to the three-weight problem (not as easyas it may seem). In either case check the physical reasonableness of your solution;the deduced tensions should be positive and of similar magnitude to the weights of−101<strong>COPYRIGHT</strong> <strong>2008</strong>, PRINCET O N UNIVE R S I T Y P R E S SEVALUATION COPY ONLY. NOT FOR USE IN COURSES.ALLpup_06.04 — <strong>2008</strong>/2/15 — Page 159

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!