Thread: Non-Urgent

  1. #1
    Registered User
    Join Date
    May 2010
    Posts
    3

    Post Non-Urgent

    at uni weve been given this im in serious need of help!! btw i'm using eclipse as an editor? anyone can help! thanks

    Background
    Computers are often used to simulate real-life scenarios over complex phenomena in order to evaluate
    complex situations or interdependencies. In this project you will write such a program. The skills
    required to complete this project include nested loops, arrays, and if you want to, structures. It will also
    consolidate your skills with functions, and general issues to do with program design. Your programs will
    be assessed for credit, and feedback will be provided.
    Tommy the Telecommunications Tuner
    Tommy the telecommunications tuner works for a large networking company. Tommy is responsible
    for identifying possible locations for network towers for the company’s mobile phone network, and for
    making sure that there are no black spots in which there is no coverage. Tommy has studied Electrical
    Engineering at the University, and has been told that when a mobile phone transmitter t has power Pt
    (in Watts), then the available power Pd (also in Watts) at a distance d (in meters) from the tower can be
    approximated by
    Pd =
    Pt
    (1 + (d/10))4 ,
    where in combination the two constants 10 and 4 reflect the dispersion of the signal as the distance from
    the base station increases, and the absorption of the signal by the intervening atmosphere. (In particular,
    the inverse-square law on power that would arise if the transmitter was a point source and in a vacuum
    does not apply. The difference is caused by energy absorption in the atmosphere, and interference that
    arises between a reflected ground wave and the primary signal. Study advanced telecommunications
    engineering if you want to know more.)
    Signals from different towers use different frequencies, and neither reinforce each other nor conflict
    with each other. A mobile phone is “in range” of a tower if it receives the signal from that tower at a
    power level greater than some minimum Wattage Pmin. In this work we will assume that Pmin = 10−6
    Watts, and that the power output from a base station is fixed. (In practice, the base station can vary its
    power and “reach out” to a distant phone, and the phone can – within limits – save energy by decreasing
    its sensitivity when the signal is strong, but we are going to ignore those options in this project.)
    Tommy is primarily interested in designing a mobile phone network covering the island of Sqone, a
    one kilometer square island located in the Sea of Ignorance that until now has relied on carrier pigeons
    for communications. As a model of the proposed network, he has a data file that contains four columns:
    a one-character identifier for a phone base station; the x location (in meters from the south-west corner
    of the island) of that base station; the y location (in meters, again from the south-west corner) of that
    base station; and the Wattage Pt for that base station. For example, the two data rows
    A 500.0 500.0 0.50
    f 1000.0 0.0 0.25
    represent a phone base station labeled A in the center of Sqone, with a 0.5 Watt signal strength, and
    another base station labeled f of half that strength located in the south-east corner. Tommy’s data files,
    one for each possible model of Sqone’s mobile phone network, contain one such data row for each base
    station that is being suggested as part of that particular model.
    What Tommy wants – and what you are to deliver in this project – is a program that helps Tommy
    visualize each of the proposed network layouts, and alert Tommy to any black spots that might arise.

  2. #2
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Let's see your attempt first.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  3. #3
    Registered User
    Join Date
    May 2010
    Posts
    3
    ill have to show u tomorrow morning wen i get to uni i dont have it on my home comp . but thanks for replying

  4. #4
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Ok, post here when you have something we can look at.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  5. #5
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > Deadline: Programs not submitted by 12:00 noon onMonday 24May will lose penalty marks
    You've got a week - how can this possibly be urgent?
    Title fixed BTW.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  6. #6
    Registered User
    Join Date
    Oct 2008
    Posts
    1,262
    Quote Originally Posted by Salem View Post
    > Deadline: Programs not submitted by 12:00 noon onMonday 24May will lose penalty marks
    You've got a week - how can this possibly be urgent?
    Title fixed BTW.
    That was may 24th of 2009, prick ;-).

  7. #7
    Registered User jephthah's Avatar
    Join Date
    May 2010
    Location
    seattle
    Posts
    49
    Quote Originally Posted by EVOEx View Post
    That was may 24th of 2009, prick ;-).

    well, then it's STILL not urgent. if it's already a year late, there's no point hurrying now.

    and by the way, good job on alienating anyone who might have been inclined to help you, ass ;-)

  8. #8
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    You guys are all wrong.

    The instructor probably forgot to update the year on the assignment. Since the assignment is a PDF I am not even surprised.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  9. #9
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > That was may 24th of 2009, prick ;-).
    WTF are you smoking?
    24th this year is IS a Monday, so whatever it was last year, it certainly wasn't Monday.

    MMX - more than just a line of Intel processors, it's also the year.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  10. #10
    Registered User
    Join Date
    Jun 2009
    Posts
    486
    At least give the guy a chance to show some code before you start jumping all over him and each other. This board gets rabid with the "we won't do your homework" line sometimes. Give him a chance to respond.

  11. #11
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Quote Originally Posted by KBriggs View Post
    At least give the guy a chance to show some code before you start jumping all over him and each other. This board gets rabid with the "we won't do your homework" line sometimes. Give him a chance to respond.
    Yes, and for good reason too. We all did our homework when we were in school, and some of us help our kids with their homework as well. Doing other people's homework on top of that quickly becomes tiring unless that person is willing to show their work and their desire to actually learn something.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  12. #12
    Registered User
    Join Date
    Jun 2009
    Posts
    486
    Sure sure, but he hasn't even posted again yet and everyone is getting mad at him ^_^

  13. #13
    Registered User
    Join Date
    Oct 2008
    Posts
    1,262
    Quote Originally Posted by jephthah View Post
    well, then it's STILL not urgent. if it's already a year late, there's no point hurrying now.

    and by the way, good job on alienating anyone who might have been inclined to help you, ass ;-)
    Note that it was me posting that message. And note that I was not the original poster.

    @Salem:
    That message was obviously a joke. See, it was a referral to all those similar "I need help now!!!!" posts which are way too late anyways to be able to be finished by anyone but someone with a lot of experience.
    Hence the blinking-smiley-face at the end of the line :P.
    I didn't see the "monday" part or I'd have said "X years ago" rather than last year.

  14. #14
    Registered User jephthah's Avatar
    Join Date
    May 2010
    Location
    seattle
    Posts
    49
    Note that it was me posting that message. And note that I was not the original poster.
    well... doh! :-P

    good one, mate.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. urgent help please...
    By peter_hii in forum C++ Programming
    Replies: 11
    Last Post: 10-30-2006, 06:37 AM
  2. urgent please please..
    By peter_hii in forum C++ Programming
    Replies: 4
    Last Post: 10-30-2006, 06:35 AM