diff options
author | priyanka | 2015-06-24 15:03:17 +0530 |
---|---|---|
committer | priyanka | 2015-06-24 15:03:17 +0530 |
commit | b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch) | |
tree | ab291cffc65280e58ac82470ba63fbcca7805165 /24/CH3/EX3.7 | |
download | Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2 Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip |
initial commit / add all books
Diffstat (limited to '24/CH3/EX3.7')
-rwxr-xr-x | 24/CH3/EX3.7/Example3_7.sce | 12 | ||||
-rwxr-xr-x | 24/CH3/EX3.7/Example3_7_result.txt | 3 |
2 files changed, 15 insertions, 0 deletions
diff --git a/24/CH3/EX3.7/Example3_7.sce b/24/CH3/EX3.7/Example3_7.sce new file mode 100755 index 000000000..666626389 --- /dev/null +++ b/24/CH3/EX3.7/Example3_7.sce @@ -0,0 +1,12 @@ +exec("degree_rad.sci",-1)
+exec("cross_product.sci",-1)
+
+//Given that
+a = [18 * cos(dtor(250)), 18 * sin(dtor(250)),0]
+b = [0,0,12]
+
+//Sample Problem 3-7
+printf("**Sample Problem 3-7**\n")
+cross_ab = crossproduct(a,b)
+angle_x = acos(cross_ab(1)/norm(cross_ab))
+printf("The magnitude of cross product of given vectors is %f \n and angle with the x axis in degrees is %f", norm(cross_ab),rtod(angle_x))
\ No newline at end of file diff --git a/24/CH3/EX3.7/Example3_7_result.txt b/24/CH3/EX3.7/Example3_7_result.txt new file mode 100755 index 000000000..26300f6d3 --- /dev/null +++ b/24/CH3/EX3.7/Example3_7_result.txt @@ -0,0 +1,3 @@ +**Sample Problem 3-7**
+The magnitude of cross product of given vectors is 216.000000
+ and angle with the x axis in degrees is 160.000000
\ No newline at end of file |