user: Please show me the C implementation that matches the assembly code listed below:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x60,%rsp
  mov    %edi,-0x44(%rbp)
  mov    %rsi,-0x50(%rbp)
  cmpl   $0x4,-0x44(%rbp)
  je     L9
  lea    D81(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D53(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    D204(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  mov    $0x1,%edi
  call   <exit@plt>
L9:
  movss  D174(%rip),%xmm0
  movss  %xmm0,-0x40(%rbp)
  mov    -0x50(%rbp),%rax
  add    $0x8,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atof@plt>
  movd   %xmm0,%eax
  mov    %eax,-0x3c(%rbp)
  mov    -0x50(%rbp),%rax
  add    $0x10,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atof@plt>
  movd   %xmm0,%eax
  mov    %eax,-0x38(%rbp)
  mov    -0x50(%rbp),%rax
  add    $0x18,%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <atof@plt>
  movd   %xmm0,%eax
  mov    %eax,-0x34(%rbp)
  pxor   %xmm5,%xmm5
  cvtss2sd -0x3c(%rbp),%xmm5
  movq   %xmm5,%rax
  movq   %rax,%xmm0
  lea    D169(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm7,%xmm7
  cvtss2sd -0x38(%rbp),%xmm7
  movq   %xmm7,%rax
  movq   %rax,%xmm0
  lea    D33(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm5,%xmm5
  cvtss2sd -0x34(%rbp),%xmm5
  movq   %xmm5,%rax
  movq   %rax,%xmm0
  lea    D50(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  movss  -0x3c(%rbp),%xmm0
  mulss  -0x40(%rbp),%xmm0
  movss  %xmm0,-0x3c(%rbp)
  movss  -0x38(%rbp),%xmm0
  mulss  -0x40(%rbp),%xmm0
  movss  %xmm0,-0x38(%rbp)
  movss  -0x34(%rbp),%xmm0
  mulss  -0x40(%rbp),%xmm0
  movss  %xmm0,-0x34(%rbp)
  mov    -0x38(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  %xmm0,-0x58(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm6
  mulsd  -0x58(%rbp),%xmm6
  movsd  %xmm6,-0x58(%rbp)
  movss  -0x3c(%rbp),%xmm0
  addss  %xmm0,%xmm0
  movd   %xmm0,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x58(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movss  -0x38(%rbp),%xmm0
  movaps %xmm0,%xmm5
  addss  %xmm0,%xmm5
  movd   %xmm5,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  %xmm0,-0x60(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm2
  mulsd  -0x60(%rbp),%xmm2
  movsd  %xmm2,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm3
  mulsd  -0x60(%rbp),%xmm3
  movsd  %xmm3,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x60(%rbp),%xmm0
  addsd  -0x58(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0x30(%rbp)
  mov    -0x38(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  %xmm0,-0x58(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm7
  mulsd  -0x58(%rbp),%xmm7
  movsd  %xmm7,-0x58(%rbp)
  movss  -0x3c(%rbp),%xmm0
  addss  %xmm0,%xmm0
  movd   %xmm0,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x58(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movss  -0x38(%rbp),%xmm0
  movaps %xmm0,%xmm4
  addss  %xmm0,%xmm4
  movd   %xmm4,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  %xmm0,-0x60(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm5
  mulsd  -0x60(%rbp),%xmm5
  movsd  %xmm5,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm6
  mulsd  -0x60(%rbp),%xmm6
  movsd  %xmm6,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  mulsd  -0x60(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  subsd  %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  cvtsd2ss %xmm1,%xmm0
  movss  %xmm0,-0x2c(%rbp)
  movss  -0x30(%rbp),%xmm0
  addss  -0x2c(%rbp),%xmm0
  cvtss2sd %xmm0,%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0x28(%rbp)
  mov    -0x38(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  %xmm0,-0x58(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm4
  mulsd  -0x58(%rbp),%xmm4
  movsd  %xmm4,-0x58(%rbp)
  movss  -0x3c(%rbp),%xmm0
  addss  %xmm0,%xmm0
  movd   %xmm0,%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  mulsd  -0x58(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movss  -0x38(%rbp),%xmm0
  movaps %xmm0,%xmm2
  addss  %xmm0,%xmm2
  movd   %xmm2,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movsd  D106(%rip),%xmm1
  movapd %xmm0,%xmm3
  mulsd  %xmm1,%xmm3
  movsd  %xmm3,-0x60(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm5
  mulsd  -0x60(%rbp),%xmm5
  movsd  %xmm5,-0x60(%rbp)
  movss  -0x3c(%rbp),%xmm0
  movaps %xmm0,%xmm6
  addss  %xmm0,%xmm6
  movd   %xmm6,%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x60(%rbp),%xmm0
  addsd  -0x58(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,-0x24(%rbp)
  mov    -0x38(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movsd  %xmm0,-0x58(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm7
  mulsd  -0x58(%rbp),%xmm7
  movsd  %xmm7,-0x58(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  mulsd  -0x58(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movss  -0x38(%rbp),%xmm0
  movaps %xmm0,%xmm4
  addss  %xmm0,%xmm4
  movd   %xmm4,%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movsd  %xmm0,-0x60(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm3
  mulsd  -0x60(%rbp),%xmm3
  movsd  %xmm3,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x60(%rbp),%xmm0
  addsd  -0x58(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0x20(%rbp)
  mov    -0x38(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movsd  %xmm0,-0x58(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movapd %xmm0,%xmm2
  mulsd  -0x58(%rbp),%xmm2
  movsd  %xmm2,-0x58(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  mulsd  -0x58(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movss  -0x38(%rbp),%xmm0
  movaps %xmm0,%xmm6
  addss  %xmm0,%xmm6
  movd   %xmm6,%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  movsd  %xmm0,-0x60(%rbp)
  mov    -0x34(%rbp),%eax
  movd   %eax,%xmm0
  call   <sin@plt>
  movapd %xmm0,%xmm4
  mulsd  -0x60(%rbp),%xmm4
  movsd  %xmm4,-0x60(%rbp)
  mov    -0x3c(%rbp),%eax
  movd   %eax,%xmm0
  call   <cos@plt>
  mulsd  -0x60(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  subsd  %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  cvtsd2ss %xmm1,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0x1c(%rbp)
  lea    D61(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  pxor   %xmm4,%xmm4
  cvtss2sd -0x1c(%rbp),%xmm4
  pxor   %xmm3,%xmm3
  cvtss2sd -0x20(%rbp),%xmm3
  pxor   %xmm2,%xmm2
  cvtss2sd -0x24(%rbp),%xmm2
  pxor   %xmm1,%xmm1
  cvtss2sd -0x28(%rbp),%xmm1
  pxor   %xmm0,%xmm0
  cvtss2sd -0x2c(%rbp),%xmm0
  pxor   %xmm5,%xmm5
  cvtss2sd -0x30(%rbp),%xmm5
  movq   %xmm5,%rax
  movapd %xmm4,%xmm5
  movapd %xmm3,%xmm4
  movapd %xmm2,%xmm3
  movapd %xmm1,%xmm2
  movapd %xmm0,%xmm1
  movq   %rax,%xmm0
  lea    D45(%rip),%rax
  mov    %rax,%rdi
  mov    $0x6,%eax
  call   <printf@plt>
  movss  -0x30(%rbp),%xmm0
  movss  %xmm0,-0x18(%rbp)
  movss  -0x2c(%rbp),%xmm0
  movss  %xmm0,-0x14(%rbp)
  movss  -0x28(%rbp),%xmm0
  movss  %xmm0,-0x10(%rbp)
  pxor   %xmm0,%xmm0
  cvtss2sd -0x24(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0xc(%rbp)
  movss  -0x20(%rbp),%xmm0
  movss  %xmm0,-0x8(%rbp)
  pxor   %xmm0,%xmm0
  cvtss2sd -0x1c(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  D214(%rip),%xmm1
  xorps  %xmm1,%xmm0
  movss  %xmm0,-0x4(%rbp)
  lea    D101(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  pxor   %xmm3,%xmm3
  cvtss2sd -0x10(%rbp),%xmm3
  movq   %xmm3,%rax
  movq   %rax,%xmm0
  lea    D218(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm6,%xmm6
  cvtss2sd -0x18(%rbp),%xmm6
  movq   %xmm6,%rax
  movq   %rax,%xmm0
  lea    D213(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm7,%xmm7
  cvtss2sd -0x14(%rbp),%xmm7
  movq   %xmm7,%rax
  movq   %rax,%xmm0
  lea    D212(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm4,%xmm4
  cvtss2sd -0x8(%rbp),%xmm4
  movq   %xmm4,%rax
  movq   %rax,%xmm0
  lea    D12(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm2,%xmm2
  cvtss2sd -0x4(%rbp),%xmm2
  movq   %xmm2,%rax
  movq   %rax,%xmm0
  lea    D190(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  pxor   %xmm3,%xmm3
  cvtss2sd -0xc(%rbp),%xmm3
  movq   %xmm3,%rax
  movq   %rax,%xmm0
  lea    D112(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  leave
  ret
```

tool_calls: name: read_data
arguments: label: D81
type: string
name: read_data
arguments: label: D53
type: string
name: read_data
arguments: label: D204
type: string
name: read_data
arguments: label: D174
type: f32
name: read_data
arguments: label: D169
type: string
name: read_data
arguments: label: D33
type: string
name: read_data
arguments: label: D50
type: string
name: read_data
arguments: label: D214
type: byte[4]
name: read_data
arguments: label: D106
type: f64
name: read_data
arguments: label: D61
type: string
name: read_data
arguments: label: D45
type: string
name: read_data
arguments: label: D101
type: string
name: read_data
arguments: label: D218
type: string
name: read_data
arguments: label: D213
type: string
name: read_data
arguments: label: D212
type: string
name: read_data
arguments: label: D12
type: string
name: read_data
arguments: label: D190
type: string
name: read_data
arguments: label: D112
type: string

tool: D81: 
Double Couple - Moment Tensor Converter (by Onur TAN)

tool: D53: Usage : dc2mt Strike Dip Rake (in degrees)

tool: D204: Output Aki&Richards1980:  Mxx  Myy  Mzz  Mxy  Mxz  Myz 


tool: D174: 0.017453293

tool: D169: 
Strike = %9.5f degrees


tool: D33: Dip = %9.5f degrees


tool: D50: Rake/Slip = %9.5f degrees


tool: {"D214": [0x00,0x00,0x00,0x80]}

tool: D106: 0.5

tool: D61: 
Output Aki&Richards1980:  Mxx  Myy  Mzz  Mxy  Mxz  Myz 

tool: D45: %9.5f %9.5f %9.5f %9.5f %9.5f %9.5f


tool: D101: 
Output Harvard CMTSOLUTION:  Mrr Mtt Mpp Mrt Mrp Mtp

tool: D218: Mrr: %9.5f


tool: D213: Mtt: %9.5f


tool: D212: Mpp: %9.5f


tool: D12: Mrt: %9.5f


tool: D190: Mrp: %9.5f


tool: D112: Mtp: %9.5f



assistant: ```c
int main(int argc, char *argv[]) {
  float S, D, R, d2r;
  float Mxx, Myy, Mzz, Mxy, Mxz, Myz;
  float Mrr, Mtt, Mpp, Mrt, Mrp, Mtp;
  if (argc != 4) {
    printf("\nDouble Couple - Moment Tensor Converter (by Onur TAN)\n");
    printf("Usage : dc2mt Strike Dip Rake (in degrees)\n");
    printf("Output Aki&Richards1980:  Mxx  Myy  Mzz  Mxy  Mxz  Myz \n\n");
    exit(1);
  }
  d2r = 0.017453293;
  S = atof(argv[1]);
  D = atof(argv[2]);
  R = atof(argv[3]);
  printf("\nStrike = %9.5f degrees\n", S);
  printf("Dip = %9.5f degrees\n", D);
  printf("Rake/Slip = %9.5f degrees\n", R);
  S *= d2r;
  D *= d2r;
  R *= d2r;
  Mxx = -1.0 * (sin(D) * cos(R) * sin(2 * S) + sin(2 * D) * sin(R) * sin(S) * sin(S));
  Myy = (sin(D) * cos(R) * sin(2 * S) - sin(2 * D) * sin(R) * cos(S) * cos(S));
  Mzz = -1.0 * (Mxx + Myy);
  Mxy = (sin(D) * cos(R) * cos(2 * S) + 0.5 * sin(2 * D) * sin(R) * sin(2 * S));
  Mxz = -1.0 * (cos(D) * cos(R) * cos(S) + cos(2 * D) * sin(R) * sin(S));
  Myz = -1.0 * (cos(D) * cos(R) * sin(S) - cos(2 * D) * sin(R) * cos(S));
  printf("\nOutput Aki&Richards1980:  Mxx  Myy  Mzz  Mxy  Mxz  Myz \n");
  printf("%9.5f %9.5f %9.5f %9.5f %9.5f %9.5f\n", Mxx, Myy, Mzz, Mxy, Mxz, Myz);
  Mtt = Mxx;
  Mpp = Myy;
  Mrr = Mzz;
  Mtp = Mxy * -1.;
  Mrt = Mxz;
  Mrp = Myz * -1.;
  printf("\nOutput Harvard CMTSOLUTION:  Mrr Mtt Mpp Mrt Mrp Mtp\n");
  printf("Mrr: %9.5f\n", Mrr);
  printf("Mtt: %9.5f\n", Mtt);
  printf("Mpp: %9.5f\n", Mpp);
  printf("Mrt: %9.5f\n", Mrt);
  printf("Mrp: %9.5f\n", Mrp);
  printf("Mtp: %9.5f\n\n", Mtp);
}
```