Thread: Help - Assignment

  1. #1
    Registered User
    Join Date
    Jun 2009
    Location
    Sri Lanka
    Posts
    5

    Help - Assignment

    Please help me to write this program. This is an assignment. PLEASE help me. I have no idea about this. Thank you.

    I attached the assignment. Please help me with this. Can somebody write this program for me. Deadline is tomorrow. Please guys..
    Last edited by Salem; 06-07-2009 at 02:17 AM. Reason: removed font abuse - then ignored you, you selfish brat

  2. #2
    Registered User valaris's Avatar
    Join Date
    Jun 2008
    Location
    RING 0
    Posts
    507
    Nope (Wanted to just say no but there is a 4 character limit on posts).

    http://cboard.cprogramming.com/c-pro...-homework.html btw.

  3. #3
    Registered User
    Join Date
    Jun 2009
    Location
    Sri Lanka
    Posts
    5
    What does that mean? I am new to this community. Please help me if you can. Thanks.

  4. #4
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Unless you start taking school seriously, you're going to fail. Leaving an assignment like this until the last minute is a very bad idea. Begging people to write it for you is even worse.

  5. #5
    Registered User
    Join Date
    Jun 2009
    Location
    Sri Lanka
    Posts
    5
    I know that I am wrong. I had my semester final exams and was studying for other subjects. Its my bad I know that. Couldn't concentrate on this subject as I was really busy with other subjects. Sorry if I troubled you.

  6. #6
    Registered User
    Join Date
    Jun 2009
    Location
    Sri Lanka
    Posts
    5
    Ok help me in this part. I included math.h library to the program. I have to include this formula

    Vout = Vin * (1-e^(-t/CR))

    Where; R-Resistor C-Capacitor, Vout-Output voltage, Vin-Input voltage, t-time

    I wrote it like this and it is not working

    v_out=v_in*(1-double exp(double pow(-time/(res*cap))))

    What is the error there? This is the 1st time I am using math.h library. Thanks in advance.

  7. #7
    Registered User valaris's Avatar
    Join Date
    Jun 2008
    Location
    RING 0
    Posts
    507
    if you are trying to cast it to a double then add () around double, otherwise remove them.

  8. #8
    Registered User
    Join Date
    Jun 2009
    Location
    Sri Lanka
    Posts
    5
    Quote Originally Posted by valaris View Post
    if you are trying to cast it to a double then add () around double, otherwise remove them.
    Thank you so much.

  9. #9
    Deathray Engineer MacGyver's Avatar
    Join Date
    Mar 2007
    Posts
    3,210
    Not that you need to cast the results of exp() and pow() to double....

    At this point it appears the student has not given any attention to the professor.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Menu
    By Krush in forum C Programming
    Replies: 17
    Last Post: 09-01-2009, 02:34 AM
  2. Assignment Operator, Memory and Scope
    By SevenThunders in forum C++ Programming
    Replies: 47
    Last Post: 03-31-2008, 06:22 AM
  3. Screwy Linker Error - VC2005
    By Tonto in forum C++ Programming
    Replies: 5
    Last Post: 06-19-2007, 02:39 PM
  4. Help with a pretty big C++ assignment
    By wakestudent988 in forum C++ Programming
    Replies: 1
    Last Post: 10-30-2006, 09:46 PM
  5. Replies: 1
    Last Post: 10-27-2006, 01:21 PM