Programs to solve the nonlinear algebraic equations, Programming Languages

Assignment Help:

Introduction

Each module of the course includes a programming project. However, for Modules 5 and 6 we will do a single project to cover both. The purpose of the programming project is to solve problems that cannot be solved with analytical tools (e.g., using methods of algebra and calculus to solve the equations of motion). In a programming environment we can use numerical analysis tools to solve more complex problems. In a programming environment we will see the equations a little differently. Furthermore, the programming environment forces you to get the details of calculation right (persistence pays off).

Assessment

The project reports will be evaluated in three areas (with equal importance):

(1)Accuracy and completeness of computations

You have to get the analysis right and you have to develop a plausible argument to "prove" that your analysis is correct.

(2) Interest of study and insight into relevant phenomena

The purpose of computation is to gain insight. It is not sufficient to simply develop analysis tools. It is important to use them to discover something about the problem you are solving. Each student will explore a unique aspect of the subject problem.

(3) Quality of the report

Communication of ideas is important. The aspects that are part of the quality include English usage, report layout, and presentation of graphics.

Ultimately, the report has to convey an idea in a way that the reader can easily appreciate. The reports do not need to be long, they need to be good.

The computing projects provide a distinctly different opportunity, compared with the examinations, to demonstrate your mastery of the ideas covered in the Modules.

Program Double Pendulum

Modules 5 extended the ideas of rigid body dynamics to bodies rotating about a fixed axis (but with loads and mass distributed over a region). Module 6 extends these ideas to multiple bodies that are constrained in some way to move together. As such, the concepts of Module 6 are not new, but the solution of problems is a bit more complex. The computing project is called Double Pendulum. The concept is to model the motion of two rods with one hinged at a fixed point and the other hinged to the end of the first one. Assume that the mass is uniformly distributed over the length of each rod and that the weights are W1 and W2 , respectively. The two rods rotate independently with their motion influenced by the force shared between them. In addition we can anticipate that there is an extra applied force (which we will prescribe as input) and that the double pendulum is swinging in a fluid (e.g., air) and thus has fluid drag (like pendulum did in the last project). The extra feature over the Module 4 project pendulum is the added degree of freedom (there are two angles to track in this problem rather than just one). This project explores the interaction of these two rods as a dynamical system.

What you need to do

The key learning objective of this project is to experience the complete cycle of problem formulation, implementation, and verification. In past programming projects, the equations have been given to you. In this project you need to derive them yourself. Derive the equations using balance of linear and angular momentum. Check your equations by computing the potential and kinetic energy and then observing that (at least for the case where energy is conserved) the rate of change of the total energy with respect to time is zero. If you do both derivation approaches then you gain confidence in the answer. If you implement your equations in the program and compute sensible results (or better yet verify the program by applying it to a case where the results are known), then you gain confidence in your results. That is the nature of closing the loop in engineering calculations. Include your derivation and your equations in your report.

The basic numerical algorithm for time integration is the same as the one that was implemented in program pendulum.m. The key difference between pendulum and double pendulum is that there are two angle variables (call them 1  and 2 ) rather than just one.

You will need to establish the initial positions and initial angular velocities for both bodies.

You will need to implement Newton's method to solve the nonlinear algebraic equations that comprise the equation of motion at the new state, just as you did for pendulum. In this case we have two nonlinear equations in two unknowns; pendulum only had a single equation in a single unknown. You will need to derive the equations to use in the Newton "while" loop. The handout from the Module 4 project should be helpful in figuring outhow to do that (and, if that-and Wikipedia-is not enough help then ask me for some additional guidance).

Once you get the program running you need to verify it with some known solution. The challenge with a multi-degree-of-freedom system is that the response is pretty complex.

Perhaps you can give limiting (or near limiting) values to some of the parameters to trick the program into thinking it is a single pendulum (e.g., can you make the length of the second bar zero? Can you give one of the bars a very small weight? What other things are possible that might help to verify the code?).

As these projects transfer more and more of the responsibility on to you, you need to adjust your management milestones accordingly. If you do not have good equations then you cannot write a program; if you do not have a working program then you cannot write a good report. So work backwards from the due date to assure that you give yourself a fighting chance to get the help you need when you need it. A suggestion:

1. Complete and correct equations of motion by 10.31.2012. If you target this date then you can get help with the equations at the extra help sessions on 10.29.2012 and 10.31.2012 or otherwise get help from the instructional team. The equations you should have at this point include the Newton iteration equations that need to be implemented in the code.

2. Working code by 11.05.2012. If you are nearly done by this date then you can still ask questions at the extra help session on 11.05.2012 of otherwise get help from the instructional team. By this time your code should be able to do the verification problems. Note that "working code" does not mean a code with no MATLAB syntax errors it means a code that computes correct numbers. Any time beyond this starts to squeeze the time available to complete the report (and remember doing the report is not just a matter of running a case and pasting your code into a Word file-you actually have to do something thoughtful).

3. Complete report by 11.07.2012 (the due date). By this date you should be at the polishing stage (i.e., the report is basically drafted but you might have a few loose ends to clean up).

This project has enough parts to warrant this level of management and planning. Time management does not necessarily change the amount of time you need to devote to a given project, but it can dramatically change the resources available to you to sort out problems that come up (and you know there will be problems!).


Related Discussions:- Programs to solve the nonlinear algebraic equations

Software problem program, On December 27, 2011, Seymour Gravel, at the urgi...

On December 27, 2011, Seymour Gravel, at the urging of his wife, Mary Walford, has brought you his preliminary figures for his business. Seymour carries on a business writing and e

Program to output a triangle wave, 1.) Write a flowchart and program to do ...

1.) Write a flowchart and program to do the following: A pressure sensor in a cooling system measures the pressure of the refrigerant and is connected to Port -1 of the 8051. If th

Windows presentation foundation, Windows Presentation Foundation Designed b...

Windows Presentation Foundation Designed by Microsoft Technologies, the Microsoft Technologies windows Display Groundwork (or WPF) is a computer-software graphic subsystem for maki

Python, Write a python script that will take two file names as input (src, ...

Write a python script that will take two file names as input (src, dest). Open src reading each line in the file, and replacing any occurrences of name with the string "redacted".

Complex roots, We will be assuming here that our roots are of the form, in ...

We will be assuming here that our roots are of the form, in this case, r 1,2 = l + mi If we take the first root we'll find the following solution. x l + m i It i

Example problem of modularity, Example problem Imagine that  you  requ...

Example problem Imagine that  you  require  to create  a robot  that  will  roll up  close to a light  lamp  and  stop  a fixed distance from it.  The first question is, how w

Modularity, Modularity, Abstraction, and Modelling Whether proving a t...

Modularity, Abstraction, and Modelling Whether proving a theorem by creating up from lemmas to simple basic theorems to more accurate results, or designing a circuit by creati

Program 3, An apartment complex has several apartments to rent. The apartme...

An apartment complex has several apartments to rent. The apartments are all similar, and all rent for $750 per month. Currently, all units are occupied. The management, being in bu

Explain cascading style sheets, Question: (a) In JavaScript, the Windo...

Question: (a) In JavaScript, the Window Object is commonly used to request information from a user or to output some results. Give three ways how to create instances of the

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd