Differences between revisions 1 and 2
Revision 1 as of 2010-12-15 12:57:51
Size: 670
Editor: trss
Comment:
Revision 2 as of 2010-12-15 13:02:13
Size: 751
Editor: trss
Comment:
Deletions are marked like this. Additions are marked like this.
Line 11: Line 11:
    return diff(diff(y1)) + y1 == 0 and diff(diff(y2)) + y2 == 0     if diff(diff(y1)) + y1 == 0 and diff(diff(y2)) + y2 == 0:
        return 'solution'
    else:
        return 'not a solution'
Line 13: Line 16:
    return diff(y1/y2) == 0     if diff(y1/y2) == 0:
        return 'const'
    else:
        return 'not a const'
Line 15: Line 21:
if solve(cos(x), sin(x)):
    print 'const'
else:
    print 'not a const'
print solve(cos(x), sin(x))
  • Book

    Advanced Engineering Mathematics

    Author

    Erwin Kreyszig

    Edition

    8th Edition

# page 69 EXAMPLE 6
reset()
def verify(y1, y2):
    if diff(diff(y1)) + y1 == 0 and diff(diff(y2)) + y2 == 0:
        return 'solution'
    else:
        return 'not a solution'
def solve(y1, y2):
    if diff(y1/y2) == 0:
        return 'const'
    else:
        return 'not a const'
print verify(cos(x), sin(x))
print solve(cos(x), sin(x))

  • Solution by:

    • <T R Shyam Sundar>, <Student>, <CMI>

    • <Sonam Kumar>, <Student>, <CMI>

    • <Vignesh Ganapathiraman>, <Student> <CMI>

    • <Pooja Kalra>, <Student>, <Malwa Institute of Technology>

Kreyszig-2.1-6 (last edited 2010-12-17 06:48:27 by trss)