Question
Please note that this question requiere to use common lisp as the programming language, not python, C or java. Question : (Common Lisp)Write a lisp
Please note that this question requiere to use common lisp as the programming language, not python, C or java.
Question :
(Common Lisp)Write a lisp program to compute series for functions ln (1+ x) and ex depending on a switch variable s. Write a function that takes in three arguments e.g. function compute-trig(x, s, n), where s is the switch variable that decides which function to evaluate, n is the precision variable and x is the parameter variable. Parameters s and x should be defined as keyword parameters and n should be an optional parameter with default value of n=5. You are not allowed to use any inbuilt functions except predicate functions to check value type. Your program should print an apt error for string and decimal values for s and n. Additionally, there is a limit for x with s=2.
Write a lisp program to compute series for functions In (1+ x) and e depending on a switch variable s. Write a function that takes in three arguments e.g. function compute-trig(x, s, n), where x2 x3 xx" + ex = 1 + x + 2, +-+-- 3! compute-trig (x, s, n) = s is the switch variable that decides which function to evaluate, n is the precision variable and x is the parameter variable. Parameters s and x should be defined as keyword parameters and n should be an optional parameter with default value of n=5. You are not allowed to use any inbuilt functions except predicate functions to check value type. Your program should print an apt error for string and decimal values for s and n. Additionally, there is a limit for x with s-2Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started