// File: /workspace/github_c_makefile_star2_O2/markpeerdeman[P]mbemm/src/emath/post.c
// Function: U_write_mises
void U_write_mises(mesh themesh)
{ double zx, zy, zz;     /* midpoint coords */
  double sx, sy, sz, a1; /* vector s with length a1 */
  double wx, wy, wz;     /* vector w */
  double w_x, w_y, w_z;  /* vector w in local coordinates */
  double v1x, v1y, v1z;  /* local base vector 1 */
  double v2x, v2y, v2z;  /* local base vector 2 */
  double v3x, v3y, v3z;  /* local base vector 3 */
  double u1x, u1y, u1z;  /* displacements of node 1 in local system */
  double u2x, u2y, u2z;  /* displacements of node 2 in local system */
  double u3x, u3y, u3z;  /* displacements of node 3 in local system */
  double t1x, t1y, t1z;  /* tractions of node 1 in local system */
  double t2x, t2y, t2z;  /* tractions of node 2 in local system */
  double t3x, t3y, t3z;  /* tractions of node 3 in local system */
  double p1, p2, p3;     /* vector p */
  double q1, q2, q3;     /* vector q */
  matrix gradient;       /* gradient matrix */
  matrix strain;         /* strain matrix */
  matrix stress;         /* stress matrix */
  matrix analytical;
  vector principal_stresses;
  double trace1;          /* trace of the strain matrix */
  double trace2;          /* trace of the strain matrix */
  double diff;
  double s1, s2, s3;     /* principal stresses */
  double s1a, s2a, s3a;     /* principal stresses */
  double mises;          /* von mises stress */
  double misesa;          /* von mises stress */
  element e;
  point node1, node2, node3;
  double tz1, tz2, tz3;  /* traction vector components in midpoint (local) */

  gradient = (matrix)newmatrix(3,3);
  strain   = (matrix)newmatrix(3,3);
  stress   = (matrix)newmatrix(3,3);
  analytical   = (matrix)newmatrix(3,3);
  principal_stresses = (vector)newvector(3);

  printf("    -1\n");
  printf("  2414\n");
  printf("         3\n");
  printf(" von Mises stresses\n");
  printf("         2\n");
  printf("ElastoMath BEM results\n");
  printf("ELASTOMATH_SOLVE\n");
  printf("LOAD SET 1\n");
  printf("Analysis time was     8-May-66       14:24:27\n");
  printf("NONE\n");
  printf("         1         1         1         2         2         1\n");
  printf("       -10         0         1         1         1         0");
  printf("         0         0\n");
  printf("         2         0\n");
  printf("  0.00000E+00  0.00000E+00  0.00000E+00  0.00000E+00  0.00000E+00");
  printf("  0.00000E+00\n");
  printf("  0.00000E+00  0.00000E+00  0.00000E+00  0.00000E+00  0.00000E+00");
  printf("  0.00000E+00\n");


e=(element)element_dll(themesh->mesh_e,START,0);
while (e!=(element)NULL)
{
  node1 = (point)point_dll(themesh->mesh_p,SEARCH,e->p1);
  node2 = (point)point_dll(themesh->mesh_p,SEARCH,e->p2);
  node3 = (point)point_dll(themesh->mesh_p,SEARCH,e->p3);


  /* some element constant vectors in the global system: */

  zx = 1.0/3.0 * ( node1->x + node2->x + node3->x );
  zy = 1.0/3.0 * ( node1->y + node2->y + node3->y );
  zz = 1.0/3.0 * ( node1->z + node2->z + node3->z );

  sx = node1->x - zx; 
  sy = node1->y - zy; 
  sz = node1->z - zz; 
  a1 = sqrt( sx*sx + sy*sy + sz*sz );

  wx = node2->x - zx;
  wy = node2->y - zy;
  wz = node2->z - zz;


  /* determine the local system of coordinates { v1, v2, v3 }: */
 
  v1x = sx/a1;
  v1y = sy/a1;
  v1z = sz/a1;

  v2x = e->ny*v1z - e->nz*v1y;
  v2y = e->nz*v1x - e->nx*v1z;
  v2z = e->nx*v1y - e->ny*v1x;

  v3x = e->nx;
  v3y = e->ny;
  v3z = e->nz;


  /* determine the components of the disps and tracts local: */

  u1x = node1->dx*v1x + node1->dy*v1y + node1->dz*v1z;
  u1y = node1->dx*v2x + node1->dy*v2y + node1->dz*v2z;
  u1z = node1->dx*v3x + node1->dy*v3y + node1->dz*v3z;

  u2x = node2->dx*v1x + node2->dy*v1y + node2->dz*v1z;
  u2y = node2->dx*v2x + node2->dy*v2y + node2->dz*v2z;
  u2z = node2->dx*v3x + node2->dy*v3y + node2->dz*v3z;

  u3x = node3->dx*v1x + node3->dy*v1y + node3->dz*v1z;
  u3y = node3->dx*v2x + node3->dy*v2y + node3->dz*v2z;
  u3z = node3->dx*v3x + node3->dy*v3y + node3->dz*v3z;

  t1x = node1->fx*v1x + node1->fy*v1y + node1->fz*v1z;
  t1y = node1->fx*v2x + node1->fy*v2y + node1->fz*v2z;
  t1z = node1->fx*v3x + node1->fy*v3y + node1->fz*v3z;

  t2x = node2->fx*v1x + node2->fy*v1y + node2->fz*v1z;
  t2y = node2->fx*v2x + node2->fy*v2y + node2->fz*v2z;
  t2z = node2->fx*v3x + node2->fy*v3y + node2->fz*v3z;

  t3x = node3->fx*v1x + node3->fy*v1y + node3->fz*v1z;
  t3y = node3->fx*v2x + node3->fy*v2y + node3->fz*v2z;
  t3z = node3->fx*v3x + node3->fy*v3y + node3->fz*v3z;

  /* modify w to w_ the local system of coordinates: */

  w_x = wx*v1x + wy*v1y + wz*v1z;
  w_y = wx*v2x + wy*v2y + wz*v2z;
  w_z = 0.0;

  /* determine the vectors p and q: */

  p1 = (2.0*u1x - u2x - u3x)/3.0/a1; 
  p2 = (2.0*u1y - u2y - u3y)/3.0/a1; 
  p3 = (2.0*u1z - u2z - u3z)/3.0/a1; 

  q1 = ((2.0*u2x - u3x - u1x)/3.0-w_x*p1)/w_y;
  q2 = ((2.0*u2y - u3y - u1y)/3.0-w_x*p2)/w_y;
  q3 = ((2.0*u2z - u3z - u1z)/3.0-w_x*p3)/w_y;

 
  /* determine the gradient matrix (partial): */

  M(gradient,1,1) = p1;
  M(gradient,2,1) = p2;
  M(gradient,3,1) = p3;
  M(gradient,1,2) = q1;
  M(gradient,2,2) = q2;
  M(gradient,3,2) = q3;


  /* determine the strain matrix: */

  M(strain,1,1) = M(gradient,1,1);
  M(strain,2,2) = M(gradient,2,2);
  M(strain,1,2) = 0.5*( M(gradient,1,2) + M(gradient,2,1) );
  M(strain,2,1) = M(strain,1,2);
  M(strain,3,1) = M(strain,1,3);
  M(strain,3,2) = M(strain,2,3);

  
  /* determine the stress matrix: */

  tz1 = (node1->fx + node2->fx + node3->fx)/3.0;
  tz2 = (node1->fy + node2->fy + node3->fy)/3.0;
  tz3 = (node1->fz + node2->fz + node3->fz)/3.0;

  M(stress,1,3) = tz1;
  M(stress,3,1) = tz1;
  M(stress,3,2) = tz2;
  M(stress,2,3) = tz2;
  M(stress,3,3) = tz3;
  M(stress,1,2) = 2.0*MU*M(strain,1,2);
  M(stress,2,1) = M(stress,1,2);
  M(stress,1,1) = 1.0/(1.0-NU) * ( 2.0*MU*( M(strain,1,1)+NU*M(strain,2,2) ) +NU*tz3 );
  M(stress,2,2) = 1.0/(1.0-NU) * ( 2.0*MU*( M(strain,2,2)+NU*M(strain,1,1) ) +NU*tz3 );


  M(analytical,1,1) = zx;
  M(analytical,2,2) = zy;
  M(analytical,1,2) = zy;
  M(analytical,2,1) = M(analytical,1,2);
  M(analytical,3,3) = 0.0;
  M(analytical,1,3) = -2.0*zz;
  M(analytical,3,1) = M(analytical,1,3);
  M(analytical,2,3) = -zz;
  M(analytical,3,2) = M(analytical,2,3);
  


  /* calculate the von Mises stress for this element: */

  eigenval(stress,principal_stresses);
  s1 = V(principal_stresses,1);
  s2 = V(principal_stresses,2);
  s3 = V(principal_stresses,3); 

  mises = 1.0/sqrt(2.0)*sqrt( (s1-s2)*(s1-s2)+(s1-s3)*(s1-s3)+(s2-s3)*(s2-s3) );

  /* calculate the ANALYTICAL von Mises stress for this element: */

  eigenval(analytical,principal_stresses);
  s1a = V(principal_stresses,1);
  s2a = V(principal_stresses,2);
  s3a = V(principal_stresses,3);

  misesa = 1.0/sqrt(2.0)*sqrt( (s1a-s2a)*(s1a-s2a)+(s1a-s3a)*(s1a-s3a)+(s2a-s3a)*(s2a-s3a) );
  printf("%10d%10d\n",e->label,1);
  printf(" % 1.5E\n",(double)mises); 
  /* printf("mises calculated is % 8.8 E, mises (analytical) is % 8.8 E, diff. is % 8.8 E, rel diff is % 8.8 E\n",
          mises,misesa, mises-misesa, (mises-misesa)/misesa ); */
 
  e=e->NEXT;
}

  printf("    -1\n");

  delmatrix(gradient);
  delmatrix(strain);
  delmatrix(stress);
  delmatrix(analytical);
  delvector(principal_stresses);

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %r14
pushq $0x3
popq %rbx
movl %ebx, %edi
movl %ebx, %esi
callq 0xb24c
movq %rax, 0x40(%rsp)
movl %ebx, %edi
movl %ebx, %esi
callq 0xb24c
movq %rax, 0x38(%rsp)
movl %ebx, %edi
movl %ebx, %esi
callq 0xb24c
movq %rax, 0x30(%rsp)
movl %ebx, %edi
movl %ebx, %esi
callq 0xb24c
movq %rax, 0x28(%rsp)
movl %ebx, %edi
callq 0xb358
movq %rax, %rbp
leaq 0xa504(%rip), %rdi      # 0xdda0
callq 0x1060
leaq 0xa408(%rip), %rdi      # 0xdcb0
callq 0x1060
leaq 0xa351(%rip), %rdi      # 0xdc05
callq 0x1060
leaq 0xa350(%rip), %rdi      # 0xdc10
callq 0x1060
leaq 0xa3eb(%rip), %rdi      # 0xdcb7
callq 0x1060
leaq 0xa3fb(%rip), %rdi      # 0xdcd3
callq 0x1060
leaq 0xa406(%rip), %rdi      # 0xdcea
callq 0x1060
leaq 0xa40b(%rip), %rdi      # 0xdcfb
callq 0x1060
leaq 0xa40a(%rip), %rdi      # 0xdd06
callq 0x1060
leaq 0xa42c(%rip), %rdi      # 0xdd34
callq 0x1060
leaq 0xa33c(%rip), %rdi      # 0xdc50
callq 0x1060
leaq 0x9cab(%rip), %rdi      # 0xd5cb
xorl %eax, %eax
callq 0x1090
leaq 0xa448(%rip), %rdi      # 0xdd76
callq 0x1060
leaq 0xa451(%rip), %rdi      # 0xdd8b
callq 0x1060
leaq 0x9cc2(%rip), %rbx      # 0xd608
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1090
leaq 0x9ce5(%rip), %r15      # 0xd63c
movq %r15, %rdi
callq 0x1060
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1090
movq %r15, %rdi
callq 0x1060
movq 0x8(%r14), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xad45
movq %rax, %rbx
pushq $0x2
popq %r13
testq %rbx, %rbx
je 0x410a
movq (%r14), %rdi
movl 0x18(%rbx), %edx
movl %r13d, %esi
callq 0xc14c
movq %rax, %r15
movq (%r14), %rdi
movl 0x1c(%rbx), %edx
movl %r13d, %esi
callq 0xc14c
movq %rax, %r12
movq (%r14), %rdi
movl 0x20(%rbx), %edx
movl %r13d, %esi
callq 0xc14c
movsd 0x20(%r15), %xmm9
movsd 0x28(%r15), %xmm7
movsd 0x20(%r12), %xmm0
movsd %xmm0, 0xa8(%rsp)
movsd 0x28(%r12), %xmm3
movsd %xmm3, 0xa0(%rsp)
movapd %xmm9, %xmm1
addsd %xmm0, %xmm1
addsd 0x20(%rax), %xmm1
movapd %xmm7, %xmm2
addsd %xmm3, %xmm2
addsd 0x28(%rax), %xmm2
movsd 0x9a43(%rip), %xmm0     # 0xd450
mulsd %xmm0, %xmm1
movapd %xmm1, %xmm3
movsd %xmm1, 0x60(%rsp)
mulsd %xmm0, %xmm2
movsd %xmm2, 0x58(%rsp)
movsd 0x30(%r15), %xmm10
movsd 0x30(%r12), %xmm6
movsd %xmm6, 0x98(%rsp)
movapd %xmm10, %xmm1
addsd %xmm6, %xmm1
addsd 0x30(%rax), %xmm1
mulsd %xmm0, %xmm1
movapd %xmm1, 0xb0(%rsp)
subsd %xmm3, %xmm9
subsd %xmm2, %xmm7
subsd %xmm1, %xmm10
movapd %xmm7, %xmm0
mulsd %xmm7, %xmm0
movapd %xmm9, %xmm1
mulsd %xmm9, %xmm1
addsd %xmm0, %xmm1
movapd %xmm10, %xmm0
mulsd %xmm10, %xmm0
addsd %xmm1, %xmm0
sqrtsd %xmm0, %xmm0
movsd %xmm0, 0x90(%rsp)
divsd %xmm0, %xmm9
divsd %xmm0, %xmm7
movsd %xmm7, 0x80(%rsp)
divsd %xmm0, %xmm10
movsd %xmm10, 0x50(%rsp)
movsd 0xa0(%rbx), %xmm12
movsd 0xa8(%rbx), %xmm3
movsd 0xb0(%rbx), %xmm0
movapd %xmm7, %xmm1
mulsd %xmm0, %xmm1
movapd %xmm3, %xmm2
movsd %xmm3, 0x48(%rsp)
mulsd %xmm10, %xmm2
subsd %xmm1, %xmm2
movsd %xmm2, 0x88(%rsp)
mulsd %xmm12, %xmm10
movsd 0x60(%r15), %xmm1
movsd %xmm1, 0x20(%rsp)
movsd %xmm1, 0x18(%rsp)
mulsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
movsd 0x60(%r12), %xmm14
movsd %xmm14, 0x10(%rsp)
movsd %xmm14, 0x78(%rsp)
mulsd %xmm0, %xmm14
movsd 0x60(%rax), %xmm1
movsd %xmm1, 0x70(%rsp)
movsd %xmm1, 0x68(%rsp)
mulsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
movapd %xmm0, %xmm7
mulsd %xmm9, %xmm7
subsd %xmm10, %xmm7
movapd %xmm9, %xmm15
mulsd %xmm3, %xmm15
movsd 0x50(%r15), %xmm0
movapd %xmm0, %xmm3
movapd %xmm0, %xmm5
mulsd %xmm12, %xmm0
movsd 0x50(%r12), %xmm4
movapd %xmm4, %xmm6
movapd %xmm4, %xmm8
mulsd %xmm12, %xmm4
movsd 0x50(%rax), %xmm10
movapd %xmm10, %xmm11
movapd %xmm10, %xmm13
mulsd %xmm12, %xmm10
movsd 0x80(%rsp), %xmm2
mulsd %xmm2, %xmm12
subsd %xmm15, %xmm12
movsd 0x58(%r15), %xmm15
movapd %xmm2, %xmm1
mulsd %xmm15, %xmm1
mulsd %xmm9, %xmm3
addsd %xmm1, %xmm3
movsd 0x20(%rsp), %xmm1
mulsd 0x50(%rsp), %xmm1
addsd %xmm3, %xmm1
movsd %xmm1, 0x20(%rsp)
movsd 0x48(%rsp), %xmm1
mulsd %xmm15, %xmm1
mulsd %xmm7, %xmm15
movsd 0x88(%rsp), %xmm3
mulsd %xmm3, %xmm5
addsd %xmm15, %xmm5
movsd 0x18(%rsp), %xmm15
mulsd %xmm12, %xmm15
addsd %xmm5, %xmm15
movsd %xmm15, 0x18(%rsp)
addsd %xmm1, %xmm0
movsd (%rsp), %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
movsd 0x58(%r12), %xmm0
movapd %xmm2, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm9, %xmm6
addsd %xmm1, %xmm6
movsd 0x50(%rsp), %xmm5
movsd 0x10(%rsp), %xmm1
mulsd %xmm5, %xmm1
addsd %xmm6, %xmm1
movsd %xmm1, 0x10(%rsp)
movapd %xmm7, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm3, %xmm8
addsd %xmm1, %xmm8
movsd 0x78(%rsp), %xmm1
mulsd %xmm12, %xmm1
addsd %xmm8, %xmm1
movapd %xmm1, %xmm8
movsd 0x48(%rsp), %xmm6
mulsd %xmm6, %xmm0
addsd %xmm0, %xmm4
addsd %xmm4, %xmm14
movsd 0x58(%rax), %xmm0
movapd %xmm2, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm9, %xmm11
addsd %xmm1, %xmm11
movsd 0x70(%rsp), %xmm15
mulsd %xmm5, %xmm15
addsd %xmm11, %xmm15
movapd %xmm7, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm3, %xmm13
movapd %xmm3, %xmm4
addsd %xmm1, %xmm13
movsd 0x68(%rsp), %xmm11
mulsd %xmm12, %xmm11
addsd %xmm13, %xmm11
movapd %xmm11, %xmm13
movapd %xmm6, %xmm1
mulsd %xmm0, %xmm1
addsd %xmm1, %xmm10
movsd 0x8(%rsp), %xmm6
addsd %xmm10, %xmm6
movsd %xmm6, 0x8(%rsp)
movsd 0xa8(%rsp), %xmm0
subsd 0x60(%rsp), %xmm0
movsd 0xa0(%rsp), %xmm1
subsd 0x58(%rsp), %xmm1
mulsd %xmm1, %xmm2
mulsd %xmm0, %xmm9
addsd %xmm2, %xmm9
movsd 0x98(%rsp), %xmm2
subsd 0xb0(%rsp), %xmm2
mulsd %xmm2, %xmm5
addsd %xmm9, %xmm5
movapd %xmm5, %xmm3
mulsd %xmm1, %xmm7
movapd %xmm4, %xmm1
mulsd %xmm0, %xmm1
addsd %xmm7, %xmm1
mulsd %xmm2, %xmm12
addsd %xmm1, %xmm12
movsd 0x20(%rsp), %xmm9
movapd %xmm9, %xmm0
addsd %xmm9, %xmm0
movsd 0x10(%rsp), %xmm7
subsd %xmm7, %xmm0
subsd %xmm15, %xmm0
movsd 0x96c5(%rip), %xmm10    # 0xd458
divsd %xmm10, %xmm0
movsd 0x90(%rsp), %xmm1
divsd %xmm1, %xmm0
movsd 0x18(%rsp), %xmm2
movapd %xmm2, %xmm4
addsd %xmm2, %xmm4
subsd %xmm8, %xmm4
subsd %xmm11, %xmm4
divsd %xmm10, %xmm4
divsd %xmm1, %xmm4
movsd (%rsp), %xmm11
movapd %xmm11, %xmm5
addsd %xmm11, %xmm5
subsd %xmm14, %xmm5
subsd %xmm6, %xmm5
divsd %xmm10, %xmm5
divsd %xmm1, %xmm5
addsd %xmm7, %xmm7
subsd %xmm15, %xmm7
subsd %xmm9, %xmm7
divsd %xmm10, %xmm7
movapd %xmm3, %xmm1
mulsd %xmm0, %xmm1
subsd %xmm1, %xmm7
addsd %xmm8, %xmm8
subsd %xmm13, %xmm8
subsd %xmm2, %xmm8
divsd %xmm10, %xmm8
movapd %xmm3, %xmm1
mulsd %xmm4, %xmm1
subsd %xmm1, %xmm8
addsd %xmm14, %xmm14
subsd 0x8(%rsp), %xmm14
subsd %xmm11, %xmm14
divsd %xmm10, %xmm14
mulsd %xmm5, %xmm3
subsd %xmm3, %xmm14
divsd %xmm12, %xmm7
divsd %xmm12, %xmm8
divsd %xmm12, %xmm14
movq 0x40(%rsp), %rcx
movq 0x8(%rcx), %rcx
movq (%rcx), %rsi
movsd %xmm0, (%rsi)
movq 0x8(%rcx), %rdi
movsd %xmm4, (%rdi)
movq 0x10(%rcx), %rcx
movsd %xmm5, (%rcx)
movsd %xmm7, 0x8(%rsi)
movsd %xmm8, 0x8(%rdi)
movsd %xmm14, 0x8(%rcx)
movsd (%rsi), %xmm0
movq 0x38(%rsp), %rcx
movq 0x8(%rcx), %r8
movq (%r8), %rcx
movsd %xmm0, (%rcx)
movsd 0x8(%rdi), %xmm0
movq 0x8(%r8), %rdx
movsd %xmm0, 0x8(%rdx)
movsd 0x8(%rsi), %xmm0
addsd (%rdi), %xmm0
movsd 0x95a6(%rip), %xmm5     # 0xd460
mulsd %xmm5, %xmm0
movsd %xmm0, 0x8(%rcx)
movsd %xmm0, (%rdx)
movsd 0x10(%rcx), %xmm0
movq 0x10(%r8), %rsi
movsd %xmm0, (%rsi)
movsd 0x10(%rdx), %xmm0
movsd %xmm0, 0x8(%rsi)
movsd 0x48(%r15), %xmm0
addsd 0x48(%r12), %xmm0
addsd 0x48(%rax), %xmm0
divsd %xmm10, %xmm0
movq 0x30(%rsp), %rdi
movq 0x8(%rdi), %r9
movq (%r9), %rsi
movq 0x10(%r9), %r8
movupd 0x38(%r15), %xmm1
movupd 0x38(%r12), %xmm2
addpd %xmm1, %xmm2
movupd 0x38(%rax), %xmm1
addpd %xmm2, %xmm1
divpd 0x9519(%rip), %xmm1     # 0xd440
movlpd %xmm1, 0x10(%rsi)
movupd %xmm1, (%r8)
movq 0x8(%r9), %rax
movhpd %xmm1, 0x10(%rax)
movsd %xmm0, 0x10(%r8)
leaq 0x104b1(%rip), %r8      # 0x143f8
movsd (%r8), %xmm1
mulsd %xmm5, %xmm1
leaq 0x104a9(%rip), %r9      # 0x14400
movsd (%r9), %xmm2
movsd 0x90a4(%rip), %xmm6     # 0xd008
addsd %xmm6, %xmm2
divsd %xmm2, %xmm1
addsd %xmm1, %xmm1
mulsd 0x8(%rcx), %xmm1
movsd %xmm1, 0x8(%rsi)
movsd %xmm1, (%rax)
movsd (%r9), %xmm1
movapd %xmm6, %xmm2
subsd %xmm1, %xmm2
movapd %xmm6, %xmm3
divsd %xmm2, %xmm3
movsd (%r8), %xmm2
mulsd %xmm5, %xmm2
movapd %xmm1, %xmm4
addsd %xmm6, %xmm4
divsd %xmm4, %xmm2
movapd %xmm0, %xmm4
mulsd %xmm1, %xmm4
mulsd 0x8(%rdx), %xmm1
addsd (%rcx), %xmm1
addsd %xmm2, %xmm2
mulsd %xmm2, %xmm1
addsd %xmm4, %xmm1
mulsd %xmm3, %xmm1
movsd %xmm1, (%rsi)
movsd (%r9), %xmm1
movapd %xmm6, %xmm2
subsd %xmm1, %xmm2
movapd %xmm6, %xmm3
divsd %xmm2, %xmm3
movsd (%r8), %xmm2
mulsd %xmm5, %xmm2
movapd %xmm1, %xmm4
addsd %xmm6, %xmm4
divsd %xmm4, %xmm2
mulsd %xmm1, %xmm0
mulsd (%rcx), %xmm1
addsd 0x8(%rdx), %xmm1
addsd %xmm2, %xmm2
mulsd %xmm2, %xmm1
addsd %xmm0, %xmm1
mulsd %xmm3, %xmm1
movsd %xmm1, 0x8(%rax)
movq 0x28(%rsp), %r15
movq 0x8(%r15), %rax
movq (%rax), %rcx
movsd 0x60(%rsp), %xmm0
movsd %xmm0, (%rcx)
movq 0x8(%rax), %rdx
movsd 0x58(%rsp), %xmm0
movsd %xmm0, 0x8(%rdx)
movsd %xmm0, 0x8(%rcx)
movsd %xmm0, (%rdx)
movq 0x10(%rax), %rax
andq $0x0, 0x10(%rax)
movapd 0xb0(%rsp), %xmm1
movapd %xmm1, %xmm0
mulsd 0x9403(%rip), %xmm0     # 0xd468
movsd %xmm0, 0x10(%rcx)
movsd %xmm0, (%rax)
xorpd 0x8faa(%rip), %xmm1     # 0xd020
movlpd %xmm1, 0x10(%rdx)
movlpd %xmm1, 0x8(%rax)
movq %rbp, %rsi
callq 0xbbb7
movq 0x8(%rbp), %rax
movsd (%rax), %xmm0
movsd 0x8(%rax), %xmm1
movsd 0x10(%rax), %xmm2
movapd %xmm0, %xmm3
subsd %xmm1, %xmm3
subsd %xmm2, %xmm0
mulsd %xmm0, %xmm0
mulsd %xmm3, %xmm3
addsd %xmm0, %xmm3
subsd %xmm2, %xmm1
mulsd %xmm1, %xmm1
addsd %xmm3, %xmm1
sqrtsd %xmm1, %xmm0
mulsd 0x93a6(%rip), %xmm0     # 0xd470
movsd %xmm0, (%rsp)
movq %r15, %rdi
movq %rbp, %rsi
callq 0xbbb7
movl 0x14(%rbx), %esi
leaq 0x95ba(%rip), %rdi      # 0xd69e
pushq $0x1
popq %rdx
xorl %eax, %eax
callq 0x1090
leaq 0x9555(%rip), %rdi      # 0xd64a
movsd (%rsp), %xmm0
movb $0x1, %al
callq 0x1090
movq 0x8(%rbx), %rbx
jmp 0x3985
leaq 0x9c8f(%rip), %rdi      # 0xdda0
callq 0x1060
movq 0x40(%rsp), %rdi
callq 0xb3b2
movq 0x38(%rsp), %rdi
callq 0xb3b2
movq 0x30(%rsp), %rdi
callq 0xb3b2
movq 0x28(%rsp), %rdi
callq 0xb3b2
movq %rbp, %rdi
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xb43d