user: 请从给定的汇编指令推导出C源代码:

```asm
<eppO>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0xd8,%rsp
  mov    %rdi,-0xa8(%rbp)
  mov    %rsi,-0xb0(%rbp)
  mov    %rdx,-0xb8(%rbp)
  mov    %rcx,-0xc0(%rbp)
  mov    %r8d,-0xc4(%rbp)
  movsd  %xmm0,-0xd0(%rbp)
  movsd  %xmm1,-0xd8(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x18(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x9c(%rbp)
  movl   $0x0,-0x90(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x80(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x78(%rbp)
  movsd  D266(%rip),%xmm0
  movsd  %xmm0,-0x70(%rbp)
  movsd  D20(%rip),%xmm0
  movapd %xmm0,%xmm2
  divsd  -0xd8(%rbp),%xmm2
  movsd  D20(%rip),%xmm0
  movapd %xmm0,%xmm1
  subsd  %xmm2,%xmm1
  movsd  D20(%rip),%xmm0
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x48(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x50(%rbp)
  movl   $0x1,-0x8c(%rbp)
  mov    -0xc4(%rbp),%eax
  cltq
  shl    $0x2,%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    %rax,-0x40(%rbp)
  movl   $0x0,-0x98(%rbp)
  jmp    L93
L138:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  pxor   %xmm1,%xmm1
  ucomisd %xmm1,%xmm0
  jp     L28
  pxor   %xmm1,%xmm1
  ucomisd %xmm1,%xmm0
  jne    L28
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movl   $0x0,(%rax)
  jmp    L235
L28:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  pxor   %xmm1,%xmm1
  comisd %xmm1,%xmm0
  jbe    L344
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movl   $0x0,(%rax)
  jmp    L122
L344:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  movl   $0x1,(%rax)
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movq   D94(%rip),%xmm1
  xorpd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L122:
  movsd  -0x48(%rbp),%xmm0
  cvttsd2si %xmm0,%edx
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0xc0(%rbp),%rax
  add    %rcx,%rax
  mov    (%rax),%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movsd  -0x80(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x80(%rbp)
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  comisd -0x78(%rbp),%xmm0
  jbe    L255
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x78(%rbp)
L255:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  movsd  -0x70(%rbp),%xmm0
  comisd %xmm1,%xmm0
  jbe    L235
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x70(%rbp)
L235:
  addl   $0x1,-0x98(%rbp)
L93:
  mov    -0x98(%rbp),%eax
  cmp    -0xc4(%rbp),%eax
  jl     L138
  movsd  D20(%rip),%xmm0
  divsd  -0x48(%rbp),%xmm0
  cvttsd2si %xmm0,%edx
  mov    -0x80(%rbp),%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movq   %xmm0,%rax
  mov    %rax,-0x80(%rbp)
  movsd  -0xd0(%rbp),%xmm0
  comisd -0x80(%rbp),%xmm0
  jb     L208
  mov    -0xb0(%rbp),%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0xb8(%rbp),%rax
  add    $0x4,%rax
  movl   $0x0,(%rax)
  mov    (%rax),%edx
  mov    -0xb8(%rbp),%rax
  mov    %edx,(%rax)
  movl   $0x0,-0x98(%rbp)
  jmp    L220
L232:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  test   %eax,%eax
  je     L203
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movq   D94(%rip),%xmm1
  xorpd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L203:
  addl   $0x1,-0x98(%rbp)
L220:
  mov    -0x98(%rbp),%eax
  cmp    -0xc4(%rbp),%eax
  jl     L232
  mov    -0x40(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  jmp    L56
L208:
  movsd  -0x80(%rbp),%xmm0
  subsd  -0xd0(%rbp),%xmm0
  divsd  -0x80(%rbp),%xmm0
  movsd  %xmm0,-0x38(%rbp)
  movsd  -0xd8(%rbp),%xmm0
  comisd D227(%rip),%xmm0
  jbe    L206
  movsd  D20(%rip),%xmm0
  subsd  -0x38(%rbp),%xmm0
  mulsd  -0x70(%rbp),%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <log@plt>
  movq   %xmm0,%rbx
  movsd  -0xd8(%rbp),%xmm0
  movsd  D20(%rip),%xmm1
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0xe0(%rbp)
  movsd  -0x38(%rbp),%xmm0
  movapd %xmm0,%xmm4
  mulsd  -0x70(%rbp),%xmm4
  movq   %xmm4,%rax
  movq   %rax,%xmm0
  call   <log@plt>
  movsd  -0xe0(%rbp),%xmm1
  mulsd  %xmm0,%xmm1
  movq   %rbx,%xmm0
  subsd  %xmm1,%xmm0
  comisd D58(%rip),%xmm0
  jb     L266
  movl   $0x0,-0x98(%rbp)
  jmp    L259
L144:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  test   %eax,%eax
  je     L95
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movq   D94(%rip),%xmm1
  xorpd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L95:
  addl   $0x1,-0x98(%rbp)
L259:
  mov    -0x98(%rbp),%eax
  cmp    -0xc4(%rbp),%eax
  jl     L144
  mov    -0xd0(%rbp),%rdi
  mov    -0xc4(%rbp),%r8d
  mov    -0xc0(%rbp),%rcx
  mov    -0xb8(%rbp),%rdx
  mov    -0xb0(%rbp),%rsi
  mov    -0xa8(%rbp),%rax
  mov    $0x0,%r9d
  movq   %rdi,%xmm0
  mov    %rax,%rdi
  call   <eppInf@plt>
  mov    -0x40(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  jmp    L56
L266:
  movsd  D20(%rip),%xmm0
  subsd  -0x38(%rbp),%xmm0
  mulsd  -0x78(%rbp),%xmm0
  movsd  %xmm0,-0xe0(%rbp)
  movsd  -0xd8(%rbp),%xmm0
  movsd  D20(%rip),%xmm1
  subsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edx
  movsd  -0x38(%rbp),%xmm0
  movapd %xmm0,%xmm5
  mulsd  -0x78(%rbp),%xmm5
  movq   %xmm5,%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movapd %xmm0,%xmm1
  movsd  -0xe0(%rbp),%xmm0
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x60(%rbp)
  movsd  D20(%rip),%xmm0
  subsd  -0x38(%rbp),%xmm0
  mulsd  -0x70(%rbp),%xmm0
  movsd  %xmm0,-0xe0(%rbp)
  movsd  -0xd8(%rbp),%xmm0
  movsd  D20(%rip),%xmm1
  subsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edx
  movsd  -0x38(%rbp),%xmm0
  movapd %xmm0,%xmm6
  mulsd  -0x70(%rbp),%xmm6
  movq   %xmm6,%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movapd %xmm0,%xmm1
  movsd  -0xe0(%rbp),%xmm0
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x58(%rbp)
  jmp    L218
L206:
  movsd  D20(%rip),%xmm0
  subsd  -0x38(%rbp),%xmm0
  mulsd  -0x78(%rbp),%xmm0
  movsd  %xmm0,-0xe0(%rbp)
  movsd  -0xd8(%rbp),%xmm0
  movsd  D20(%rip),%xmm1
  subsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edx
  movsd  -0x38(%rbp),%xmm0
  movapd %xmm0,%xmm7
  mulsd  -0x78(%rbp),%xmm7
  movq   %xmm7,%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movapd %xmm0,%xmm1
  movsd  -0xe0(%rbp),%xmm0
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movsd  D20(%rip),%xmm0
  subsd  -0x38(%rbp),%xmm0
  mulsd  -0x70(%rbp),%xmm0
  movsd  %xmm0,-0xe0(%rbp)
  movsd  -0xd8(%rbp),%xmm0
  movsd  D20(%rip),%xmm1
  subsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%edx
  movsd  -0x38(%rbp),%xmm0
  movapd %xmm0,%xmm3
  mulsd  -0x70(%rbp),%xmm3
  movq   %xmm3,%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movapd %xmm0,%xmm1
  movsd  -0xe0(%rbp),%xmm0
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x60(%rbp)
L218:
  movsd  -0x60(%rbp),%xmm0
  subsd  -0x58(%rbp),%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <fabs@plt>
  test   %eax,%eax
  jg     L239
  movsd  -0x60(%rbp),%xmm0
  movsd  %xmm0,-0x68(%rbp)
  jmp    L274
L239:
  movsd  -0x60(%rbp),%xmm0
  addsd  -0x58(%rbp),%xmm0
  movsd  D227(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x68(%rbp)
L274:
  movl   $0x0,-0x94(%rbp)
L395:
  addl   $0x1,-0x94(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x50(%rbp)
  movl   $0x0,-0x98(%rbp)
  jmp    L21
L20:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm2
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rcx
  movsd  -0x68(%rbp),%xmm1
  movsd  -0xd8(%rbp),%xmm0
  lea    -0x9c(%rbp),%rdx
  lea    -0x88(%rbp),%rax
  movapd %xmm2,%xmm3
  movapd %xmm1,%xmm2
  movapd %xmm0,%xmm1
  movq   %rcx,%xmm0
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <zerofind@plt>
  movsd  -0x88(%rbp),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  subsd  %xmm1,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <fabs@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x20(%rbp),%xmm0
  comisd -0x50(%rbp),%xmm0
  jbe    L148
  movsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x50(%rbp)
L148:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x88(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x9c(%rbp),%eax
  add    %eax,-0x90(%rbp)
  addl   $0x1,-0x98(%rbp)
L21:
  mov    -0x98(%rbp),%eax
  cmp    -0xc4(%rbp),%eax
  jl     L20
  mov    -0xc4(%rbp),%ecx
  mov    -0xd8(%rbp),%rdx
  mov    -0xa8(%rbp),%rax
  mov    %ecx,%esi
  movq   %rdx,%xmm0
  mov    %rax,%rdi
  call   <norm@plt>
  movq   %xmm0,%rax
  mov    %rax,-0x30(%rbp)
  movsd  D20(%rip),%xmm0
  subsd  -0xd8(%rbp),%xmm0
  cvttsd2si %xmm0,%edx
  mov    -0x30(%rbp),%rax
  mov    %edx,%edi
  movq   %rax,%xmm0
  call   <pow@plt>
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  mulsd  -0xd0(%rbp),%xmm0
  subsd  -0x68(%rbp),%xmm0
  movsd  %xmm0,-0x28(%rbp)
  mov    -0x28(%rbp),%rax
  movq   %rax,%xmm0
  call   <fabs@plt>
  test   %eax,%eax
  jle    L242
  movsd  -0x60(%rbp),%xmm0
  subsd  -0x58(%rbp),%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <fabs@plt>
  test   %eax,%eax
  jle    L242
  movsd  -0x28(%rbp),%xmm0
  pxor   %xmm1,%xmm1
  comisd %xmm1,%xmm0
  jbe    L388
  movsd  D23(%rip),%xmm0
  comisd -0x50(%rbp),%xmm0
  jb     L185
  cmpl   $0x0,-0x8c(%rbp)
  je     L0
L185:
  movsd  -0x68(%rbp),%xmm0
  movsd  %xmm0,-0x60(%rbp)
  movl   $0x1,-0x8c(%rbp)
  jmp    L159
L388:
  movsd  D23(%rip),%xmm0
  comisd -0x50(%rbp),%xmm0
  jb     L429
  cmpl   $0x1,-0x8c(%rbp)
  je     L163
L429:
  movsd  -0x68(%rbp),%xmm0
  movsd  %xmm0,-0x58(%rbp)
  movl   $0x0,-0x8c(%rbp)
L159:
  movsd  -0x60(%rbp),%xmm0
  addsd  -0x58(%rbp),%xmm0
  movsd  D227(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movsd  %xmm0,-0x68(%rbp)
  cmpl   $0x3e7,-0x94(%rbp)
  jle    L395
  movsd  -0x60(%rbp),%xmm0
  subsd  -0x58(%rbp),%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <fabs@plt>
  pxor   %xmm1,%xmm1
  cvtsi2sd %eax,%xmm1
  movsd  -0x58(%rbp),%xmm2
  movsd  D23(%rip),%xmm0
  mulsd  %xmm2,%xmm0
  comisd %xmm1,%xmm0
  jae    L256
  mov    $0x3e8,%esi
  lea    D91(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movsd  -0x28(%rbp),%xmm2
  movsd  -0x50(%rbp),%xmm1
  movsd  -0x58(%rbp),%xmm0
  mov    -0x60(%rbp),%rax
  movapd %xmm2,%xmm3
  movapd %xmm1,%xmm2
  movapd %xmm0,%xmm1
  movq   %rax,%xmm0
  lea    D14(%rip),%rax
  mov    %rax,%rdi
  mov    $0x4,%eax
  call   <printf@plt>
  lea    D165(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L56
L0:
  nop
  jmp    L242
L163:
  nop
  jmp    L242
L256:
  nop
L242:
  movl   $0x0,-0x98(%rbp)
  jmp    L417
L236:
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  test   %eax,%eax
  je     L150
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xa8(%rbp),%rax
  add    %rdx,%rax
  movq   D94(%rip),%xmm1
  xorpd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x98(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0xc0(%rbp),%rax
  add    %rdx,%rax
  movq   D94(%rip),%xmm1
  xorpd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
L150:
  addl   $0x1,-0x98(%rbp)
L417:
  mov    -0x98(%rbp),%eax
  cmp    -0xc4(%rbp),%eax
  jl     L236
  mov    -0x40(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  mov    -0xb0(%rbp),%rax
  movsd  -0x68(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0xb8(%rbp),%rax
  mov    -0x94(%rbp),%edx
  mov    %edx,(%rax)
  mov    -0xb8(%rbp),%rax
  lea    0x4(%rax),%rdx
  mov    -0x90(%rbp),%eax
  mov    %eax,(%rdx)
L56:
  mov    -0x18(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L166
  call   <__stack_chk_fail@plt>
L166:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

tool_calls: name: read_data
arguments: tag: D266
datatype: f64
name: read_data
arguments: tag: D20
datatype: f64
name: read_data
arguments: tag: D94
datatype: f32[2]
name: read_data
arguments: tag: D227
datatype: f32[4]
name: read_data
arguments: tag: D58
datatype: f32[4]
name: read_data
arguments: tag: D23
datatype: byte[8]
name: read_data
arguments: tag: D91
datatype: string
name: read_data
arguments: tag: D14
datatype: string
name: read_data
arguments: tag: D165
datatype: string

tool: D266: 10000000000

tool: D20: 1

tool: {"D94": [0.0,-0.0]}

tool: {"D227": [0.0,2.0,0.0,4.1923828125]}

tool: {"D58": [0.0,4.1923828125,-8.1418283642171e20,0.19284650683403015]}

tool: {"D23": [0x3a,0x8c,0x30,0xe2,0x8e,0x79,0x45,0x3e]}

tool: D91: 
 The number of bisection steps exceed %d.

tool: D14: 
 c1=%e, c2=%e, x_diff=%e, f=%e

tool: D165: 
 If you meet with this problem, please contact Jun Liu (j.liu@asu.edu). Thanks!

assistant: ```c
void eppO(double *x, double *cc, int *iter_step, double *v, int n, double rho, double p) {
  int i, *flag, bisStep, newtonStep = 0, totoalStep = 0;
  double vq = 0, epsilon, vmax = 0, vmin = 1e10;
  double q = 1 / (1 - 1 / p), c, c1, c2, root, f, xp;
  double x_diff = 0;
  double temp;
  int p_n = 1;
  flag = (int *)malloc(sizeof(int) * n);
  for (i = 0; i < n; i++) {
    x[i] = 0;
    if (v[i] == 0)
      flag[i] = 0;
    else {
      if (v[i] > 0)
        flag[i] = 0;
      else {
        flag[i] = 1;
        v[i] = -v[i];
      }
      vq += pow(v[i], q);
      if (v[i] > vmax)
        vmax = v[i];
      if (v[i] < vmin)
        vmin = v[i];
    }
  }
  vq = pow(vq, 1 / q);
  if (rho >= vq) {
    *cc = 0;
    iter_step[0] = iter_step[1] = 0;
    for (i = 0; i < n; i++) {
      if (flag[i])
        v[i] = -v[i];
    }
    free(flag);
    return;
  }
  epsilon = (vq - rho) / vq;
  if (p > 2) {
    if (log((1 - epsilon) * vmin) - (p - 1) * log(epsilon * vmin) >= 709) {
      for (i = 0; i < n; i++) {
        if (flag[i])
          v[i] = -v[i];
      }
      eppInf(x, cc, iter_step, v, n, rho, 0);
      free(flag);
      return;
    }
    c1 = (1 - epsilon) * vmax / pow(epsilon * vmax, p - 1);
    c2 = (1 - epsilon) * vmin / pow(epsilon * vmin, p - 1);
  } else {
    c2 = (1 - epsilon) * vmax / pow(epsilon * vmax, p - 1);
    c1 = (1 - epsilon) * vmin / pow(epsilon * vmin, p - 1);
  }
  if (fabs(c1 - c2) <= 1e-8) {
    c = c1;
  } else
    c = (c1 + c2) / 2;
  bisStep = 0;
  while (1) {
    bisStep++;
    x_diff = 0;
    for (i = 0; i < n; i++) {
      zerofind(&root, &newtonStep, v[i], p, c, x[i]);
      temp = fabs(root - x[i]);
      if (x_diff < temp)
        x_diff = temp;
      x[i] = root;
      totoalStep += newtonStep;
    }
    xp = norm(x, p, n);
    f = rho * pow(xp, 1 - p) - c;
    if (fabs(f) <= 1e-8 || fabs(c1 - c2) <= 1e-8)
      break;
    else {
      if (f > 0) {
        if ((x_diff <= 1e-8) && (p_n == 0))
          break;
        c1 = c;
        p_n = 1;
      } else {
        if ((x_diff <= 1e-8) && (p_n == 1))
          break;
        c2 = c;
        p_n = 0;
      }
    }
    c = (c1 + c2) / 2;
    if (bisStep >= 1000) {
      if (fabs(c1 - c2) <= 1e-8 * c2)
        break;
      else {
        printf("\n The number of bisection steps exceed %d.", 1000);
        printf("\n c1=%e, c2=%e, x_diff=%e, f=%e", c1, c2, x_diff, f);
        printf("\n If you meet with this problem, please contact Jun Liu (j.liu@asu.edu). Thanks!");
        return;
      }
    }
  }
  for (i = 0; i < n; i++) {
    if (flag[i]) {
      x[i] = -x[i];
      v[i] = -v[i];
    }
  }
  free(flag);
  *cc = c;
  iter_step[0] = bisStep;
  iter_step[1] = totoalStep;
}
```