From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 608/CH23/EX23.05/23_05.sce | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 608/CH23/EX23.05/23_05.sce (limited to '608/CH23/EX23.05') diff --git a/608/CH23/EX23.05/23_05.sce b/608/CH23/EX23.05/23_05.sce new file mode 100755 index 000000000..d2a7ea51a --- /dev/null +++ b/608/CH23/EX23.05/23_05.sce @@ -0,0 +1,13 @@ +//Problem 23.05: Convert (5,-132°) into a + ib form correct to four significant figures. + +//initializing the variables: +r = 5; // magnitude +theta = -132; // in degree + +//calculation: +x = r*sin(theta*%pi/180) +y = r*cos(theta*%pi/180) +z = x+%i*y + +printf("\n\n Result \n\n") +printf("\n Z is %.3f + (%.3f)i", x,y) \ No newline at end of file -- cgit