SICP sicp 131: 3.62 exercises 1313.62 and

Source: Internet
Author: User

SICP sicp 131: 3.62 exercises 1313.62 and
Exercise 3-62 original

Exercise 3.62. use the results of exercises 3.60 and 3.61 to define a procedure div-series that divides two power series. div-series shocould work for any two series, provided that the denominator series begins with a nonzero constant term. (If the denominator has a zero constant term, then div-series showould signal an error .) show how to use div-series together with the result of exercise 3.59 to generate the power series for tangent.

Code
(Define (div-series s1 s2) (let (c (stream-car s2) (if (= c 0) (error "constant term of s2 can't be 0! ") (Scale-stream (mul-series s1 (reciprocal-series (scale-stream s2 (/1 c) (/1 c ))))) (define tane-series (div-series sine-series cosine-series ))

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.