Q3. Write a python code to do the following operations. 1. Create a stress tensor and a strain tensor in form of NumPy arrays: 1.0 -0.2 0.5 a= -0.2 4.3 0.0 0.5 0.0 5.2, 2. The hydrostatic stress is ayd 0.02 -0.01 0.03 0.2 -0.05 = -0.01 0.03 - (100) 1. -0.05 0.4 and the deviatoric stress is dey-hyd Define a function stress_hyd_dev () which takes in a stress tensor and returns the hydrostatic stress and the deviatoric stress. Then, apply this function to calculate the hydrostatic stress and the deviatoric stress of the stress defined in Question 1. 3. If we rotate the material, the representation of the stress tensor will change. Suppose that the coordinate system is (e₁,e.es). If we rotate the material about an axis - (₁.2. My) (a unit vector) by the angle e, the representation of the stress tensor will become o-Ro, where R is the rotation matrix cos@+u(1-cos) R=(1-cos) + ay sin ₁₂(1-cos 9)-, sin cos@+(1-cos) uyu(1-cos)+u, sin 6 (1-cos@)-₂ sine cos+u(1-cos) Define a function stress rot() which takes in a stress tensor, rotation axis and rotation angle and returns the stress tensor after rotation. Then, apply this function to calculate the stress tensor after rotating the material about u= (1, 1, 1) by the angle x/6. uu(1-cos) + ₂ sin ₂(1-cos)-₁ sin

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
Q3. Write a python code to do the following operations.
1. Create a stress tensor and a strain tensor in form of NumPy arrays:
-0.2 0.5
4.3 0.0
5.2
1.0
a= -0.2
0.5
0.0
2. The hydrostatic stress is
0.02 -0.01 0.03
€= -0.01 0.2 -0.05
0.03 -0.05 0.4
Ohyd = (tro) 1.
and the deviatoric stress is
deyddyd
Define a function stress hyd_dev () which takes in a stress tensor and returns the hydrostatic stress and the deviatoric stress. Then, apply this
function to calculate the hydrostatic stress and the deviatoric stress of the stress defined in Question 1.
where R is the rotation matrix
3. If we rotate the material, the representation of the stress tensor will change. Suppose that the coordinate system is (e₁,e₂, es). If we rotate the material
about an axis u= (₁,42,43) (a unit vector) by the angle 6, the representation of the stress tensor will become
oRo,
cos @ + u(1-cos)
R=424(1-cos) + 3 sin
u₁u₂(1-cos 9)-uy sin
cos+u(1-cos)
uu₂(1-cos 8) + u, sin 0
uu(1-cos 0) + u₂ sin 0
₂(1-cos)-uj sin 0
cos 9+ (1-cos 8)
₁₁ (1-cos)-u₂ sin
Define a function stress_rot() which takes in a stress tensor, rotation axis and rotation angle and returns the stress tensor after rotation. Then, apply
this function to calculate the stress tensor after rotating the material about u= (1, 1, 1) by the angle x/6.
Transcribed Image Text:Q3. Write a python code to do the following operations. 1. Create a stress tensor and a strain tensor in form of NumPy arrays: -0.2 0.5 4.3 0.0 5.2 1.0 a= -0.2 0.5 0.0 2. The hydrostatic stress is 0.02 -0.01 0.03 €= -0.01 0.2 -0.05 0.03 -0.05 0.4 Ohyd = (tro) 1. and the deviatoric stress is deyddyd Define a function stress hyd_dev () which takes in a stress tensor and returns the hydrostatic stress and the deviatoric stress. Then, apply this function to calculate the hydrostatic stress and the deviatoric stress of the stress defined in Question 1. where R is the rotation matrix 3. If we rotate the material, the representation of the stress tensor will change. Suppose that the coordinate system is (e₁,e₂, es). If we rotate the material about an axis u= (₁,42,43) (a unit vector) by the angle 6, the representation of the stress tensor will become oRo, cos @ + u(1-cos) R=424(1-cos) + 3 sin u₁u₂(1-cos 9)-uy sin cos+u(1-cos) uu₂(1-cos 8) + u, sin 0 uu(1-cos 0) + u₂ sin 0 ₂(1-cos)-uj sin 0 cos 9+ (1-cos 8) ₁₁ (1-cos)-u₂ sin Define a function stress_rot() which takes in a stress tensor, rotation axis and rotation angle and returns the stress tensor after rotation. Then, apply this function to calculate the stress tensor after rotating the material about u= (1, 1, 1) by the angle x/6.
Expert Solution
steps

Step by step

Solved in 3 steps with 3 images

Blurred answer
Knowledge Booster
Array
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education