|
def | sDF (r, xc, yc, x, y) |
|
def | gradSdf (xc, yc, x, y) |
|
def | hessSdf (xc, yc, x, y) |
|
def | __init__ (self, Xc, Yc, Zc, diameter) |
|
def | sDF (self, x, y, z) |
|
def | gradSdf (self, x, y, z) |
|
def | hessSdf (self, x, y, z) |
|
def | __init__ (self, Xc, Yc, Zc, diameter) |
|
def | sDF (self, x, y, z) |
|
def | gradSdf (self, x, y, z) |
|
def | hessSdf (self, x, y, z) |
|
def | __init__ (self, Xc, Yc, Zc, diameter) |
|
def | sDF (self, x, y, z) |
|
def | gradSdf (self, x, y, z) |
|
def | hessSdf (self, x, y, z) |
|
Definition at line 37 of file sdf.py.
◆ __init__() [1/3]
def sdf.CylinderZ.__init__ |
( |
|
self, |
|
|
|
Xc, |
|
|
|
Yc, |
|
|
|
Zc, |
|
|
|
diameter |
|
) |
| |
Definition at line 85 of file sdf.py.
85 def __init__(self, Xc, Yc, Zc, diameter):
97 self.radius = diameter/2
◆ __init__() [2/3]
def sdf.CylinderZ.__init__ |
( |
|
self, |
|
|
|
Xc, |
|
|
|
Yc, |
|
|
|
Zc, |
|
|
|
diameter |
|
) |
| |
Definition at line 55 of file sdf.py.
55 def __init__(self, Xc, Yc, Zc, diameter):
67 self.radius = diameter/2
◆ __init__() [3/3]
def sdf.CylinderZ.__init__ |
( |
|
self, |
|
|
|
Xc, |
|
|
|
Yc, |
|
|
|
Zc, |
|
|
|
diameter |
|
) |
| |
Definition at line 85 of file sdf.py.
85 def __init__(self, Xc, Yc, Zc, diameter):
97 self.radius = diameter/2
◆ gradSdf() [1/4]
def sdf.CylinderZ.gradSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 72 of file sdf.py.
72 def gradSdf(self, x, y, z):
73 a = (x-self.xc)**2 + (y-self.yc)**2
74 c_val_A = 1./np.sqrt(a)
75 c_val_dx = c_val_A * (x-self.xc)
76 c_val_dy = c_val_A * (y-self.yc)
77 c_val_dz = np.zeros_like(c_val_dy)
79 return np.hstack([c_val_dx.reshape((-1,1)), c_val_dy.reshape((-1,1)), c_val_dz.reshape((-1,1))])
◆ gradSdf() [2/4]
def sdf.CylinderZ.gradSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 108 of file sdf.py.
108 def gradSdf(self, x, y, z):
109 a = (x-self.xc)**2 + (y-self.yc)**2
112 c_val_dx = c_val_A * (x-self.xc)
113 c_val_dy = c_val_A * (y-self.yc)
114 c_val_dz = np.zeros_like(c_val_dy)
116 c_val_dx = c_val_dx.reshape((-1,1))
117 c_val_dy = c_val_dy.reshape((-1,1))
118 c_val_dz = c_val_dz.reshape((-1,1))
119 grad_array = np.hstack([c_val_dx,c_val_dy,c_val_dz])
◆ gradSdf() [3/4]
def sdf.CylinderZ.gradSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 108 of file sdf.py.
108 def gradSdf(self, x, y, z):
109 a = (x-self.xc)**2 + (y-self.yc)**2
112 c_val_dx = c_val_A * (x-self.xc)
113 c_val_dy = c_val_A * (y-self.yc)
114 c_val_dz = np.zeros_like(c_val_dy)
116 c_val_dx = c_val_dx.reshape((-1,1))
117 c_val_dy = c_val_dy.reshape((-1,1))
118 c_val_dz = c_val_dz.reshape((-1,1))
119 grad_array = np.hstack([c_val_dx,c_val_dy,c_val_dz])
◆ gradSdf() [4/4]
def sdf.CylinderZ.gradSdf |
( |
|
xc, |
|
|
|
yc, |
|
|
|
x, |
|
|
|
y |
|
) |
| |
Definition at line 44 of file sdf.py.
44 def gradSdf(xc, yc, x, y):
45 a = pow(x-xc, 2)+pow(y-yc, 2)
48 c_val_dx = c_val_A * (x-xc)
49 c_val_dy = c_val_A * (y-yc)
51 return [c_val_dx, c_val_dy, 0]
◆ hessSdf() [1/4]
def sdf.CylinderZ.hessSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 81 of file sdf.py.
81 def hessSdf(self, x, y, z):
82 a = (x-self.xc)**2 + (y-self.yc)**2
83 c_val_A = 1./np.sqrt(a)
84 c_val_B = 1./(a**(3./2.))
85 Hxx = c_val_A - c_val_B * (x-self.xc)**2
86 Hxy = -c_val_B * (x-self.xc)*(y-self.yc)
87 Hyy = c_val_A - c_val_B * (y-self.yc)**2
88 zeros = np.zeros_like(Hxx).reshape((-1,1))
90 return np.hstack([Hxx.reshape((-1,1)), Hxy.reshape((-1,1)), zeros, Hyy.reshape((-1,1)), zeros, zeros])
◆ hessSdf() [2/4]
def sdf.CylinderZ.hessSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 122 of file sdf.py.
122 def hessSdf(self, x, y, z):
123 a = (x-self.xc)**2 + (y-self.yc)**2
126 c_val_B = 1./(a**(3./2.))
127 Hxx = c_val_A - c_val_B * (x-self.xc)**2
128 Hxy = -c_val_B * (x-self.xc)*(y-self.yc)
129 Hyy = c_val_A - c_val_B * (y-self.yc)**2
131 Hxx = Hxx.reshape((-1,1))
132 Hzx = np.zeros_like(Hxx)
133 Hxy = Hxy.reshape((-1,1))
134 Hyy = Hyy.reshape((-1,1))
135 Hzy = np.zeros_like(Hxx)
136 Hzz = np.zeros_like(Hxx)
137 hess_array = np.hstack([Hxx, Hxy, Hzx, Hyy, Hzy, Hzz])
◆ hessSdf() [3/4]
def sdf.CylinderZ.hessSdf |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 122 of file sdf.py.
122 def hessSdf(self, x, y, z):
123 a = (x-self.xc)**2 + (y-self.yc)**2
126 c_val_B = 1./(a**(3./2.))
127 Hxx = c_val_A - c_val_B * (x-self.xc)**2
128 Hxy = -c_val_B * (x-self.xc)*(y-self.yc)
129 Hyy = c_val_A - c_val_B * (y-self.yc)**2
131 Hxx = Hxx.reshape((-1,1))
132 Hzx = np.zeros_like(Hxx)
133 Hxy = Hxy.reshape((-1,1))
134 Hyy = Hyy.reshape((-1,1))
135 Hzy = np.zeros_like(Hxx)
136 Hzz = np.zeros_like(Hxx)
137 hess_array = np.hstack([Hxx, Hxy, Hzx, Hyy, Hzy, Hzz])
◆ hessSdf() [4/4]
def sdf.CylinderZ.hessSdf |
( |
|
xc, |
|
|
|
yc, |
|
|
|
x, |
|
|
|
y |
|
) |
| |
Definition at line 53 of file sdf.py.
53 def hessSdf(xc, yc, x, y):
54 a = pow(x-xc, 2)+pow(y-yc, 2)
57 c_val_B = 1./pow(a, 3./2.)
58 c_val_dx_dx = c_val_A - c_val_B * pow(x-xc, 2)
59 c_val_dx_dy = -c_val_B * (x-xc)*(y-yc)
60 c_val_dy_dy = c_val_A - c_val_B * pow(y-yc, 2)
62 return [c_val_dx_dx, c_val_dx_dy, 0, c_val_dy_dy, 0, 0]
◆ sDF() [1/4]
def sdf.CylinderZ.sDF |
( |
|
r, |
|
|
|
xc, |
|
|
|
yc, |
|
|
|
x, |
|
|
|
y |
|
) |
| |
Definition at line 39 of file sdf.py.
39 def sDF(r, xc, yc, x, y):
40 a = pow(x-xc, 2)+pow(y-yc, 2)
41 c_val = math.sqrt(a)-r
◆ sDF() [2/4]
def sdf.CylinderZ.sDF |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 69 of file sdf.py.
69 def sDF(self, x, y, z):
70 return np.sqrt((x - self.xc)**2 + (y - self.yc)**2) - self.radius
◆ sDF() [3/4]
def sdf.CylinderZ.sDF |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 99 of file sdf.py.
99 def sDF(self, x, y, z):
100 a = (x-self.xc)**2 + (y-self.yc)**2
101 gap = np.sqrt(a)-self.radius
103 self.normal = self.gradSdf(x,y,z)
104 self.dNormal = self.hessSdf(x,y,z)
◆ sDF() [4/4]
def sdf.CylinderZ.sDF |
( |
|
self, |
|
|
|
x, |
|
|
|
y, |
|
|
|
z |
|
) |
| |
Definition at line 99 of file sdf.py.
99 def sDF(self, x, y, z):
100 a = (x-self.xc)**2 + (y-self.yc)**2
101 gap = np.sqrt(a)-self.radius
103 self.normal = self.gradSdf(x,y,z)
104 self.dNormal = self.hessSdf(x,y,z)
◆ dNormal
◆ normal
◆ radius
◆ Xc
◆ xc
◆ Yc
◆ yc
◆ Zc
◆ zc
The documentation for this class was generated from the following file:
- /mofem_install/jupyter/lukasz/mofem_install/mofem-cephas/jupyter/skel/ukacm_autumn_school/multifield_plasticity/sdf.py