// File: /workspace/github_cpp_makefile_star2_O1/snesic[P]stochastic_thin_films/read_write_msg.cpp
// Function: write_in_File(double*, int, double, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
int write_in_File(double *h, int L, double dx, int j_time, string dir) // write data into files.
{
    int i;
    ofstream dat;
    string file_name;                        // Were results will be written
    stringstream sim_name;
    
    
    sim_name.str("");
    sim_name << j_time;
    
    file_name= dir + "/droplet_at_" + sim_name.str()+ ".txt";
    dat.open(file_name.c_str(), ios::out);
	dat.precision(10);
	dat<< scientific;
    for(i=0;i<L;i++)
        dat << scientific << i*dx << "  " << scientific << h[i] << endl;
    dat.close();

return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x438, %rsp            # imm = 0x438
movq %rcx, %r14
movl %edx, %r12d
movsd %xmm0, 0xa8(%rsp)
movl %esi, %ebp
movq %rdi, 0xa0(%rsp)
leaq 0xb0(%rsp), %rdi
callq 0x22e0
leaq 0x90(%rsp), %r15
movq %r15, -0x10(%r15)
movq $0x0, -0x8(%r15)
movb $0x0, (%r15)
leaq 0x2b0(%rsp), %rdi
callq 0x2120
leaq 0x50(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x312c(%rip), %rdx      # 0x8c29
leaq 0x40(%rsp), %rdi
movq %rdx, %rsi
callq 0x2c5a
leaq 0x2c8(%rsp), %r15
leaq 0x40(%rsp), %rsi
movq %r15, %rdi
callq 0x2280
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x5b36
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21e0
leaq 0x2c0(%rsp), %rdi
movl %r12d, %esi
callq 0x22f0
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rsp, %rdi
callq 0x43bc
leaq 0x2eef(%rip), %rsi      # 0x8a58
movq %rsp, %rdi
callq 0x2370
leaq 0x60(%rsp), %rdi
movq %r15, %rsi
callq 0x22c0
movq (%rsp), %rcx
movq 0x8(%rsp), %r8
movq 0x68(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %esi
cmpq %r12, %rcx
je 0x5b9f
movq 0x10(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x5bbe
leaq 0x70(%rsp), %rdi
movl $0xf, %esi
cmpq %rdi, -0x10(%rdi)
je 0x5bb9
movq 0x70(%rsp), %rsi
cmpq %rsi, %rax
jbe 0x5bcd
movq 0x60(%rsp), %rsi
movq %rsp, %rdi
callq 0x2080
jmp 0x5bdb
leaq 0x60(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x21f0
leaq 0x30(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x5bff
movq %rsi, 0x20(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x30(%rsp)
jmp 0x5c07
movupd (%rcx), %xmm0
movupd %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x28(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x2fe6(%rip), %rsi      # 0x8c11
leaq 0x20(%rsp), %rdi
callq 0x2370
movq %r13, 0x40(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x5c58
movq %rdx, 0x40(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x50(%rsp)
jmp 0x5c62
movupd (%rcx), %xmm0
movupd %xmm0, (%r13)
movq 0x8(%rax), %rdx
leaq 0x40(%rsp), %r14
movq %rdx, 0x8(%r14)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x80(%rsp), %rdi
movq %r14, %rsi
callq 0x2220
movq (%r14), %rdi
cmpq %r13, %rdi
je 0x5ca3
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21e0
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5cbe
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x21e0
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5cd9
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x21e0
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x5cef
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x21e0
movq 0x80(%rsp), %rsi
leaq 0xb0(%rsp), %rdi
movl $0x10, %edx
callq 0x2050
movq 0xb0(%rsp), %rax
movq -0x18(%rax), %rcx
movq $0xa, 0xb8(%rsp,%rcx)
movq -0x18(%rax), %rax
movl $0xfffffefb, %r13d      # imm = 0xFFFFFEFB
movl 0xc8(%rsp,%rax), %ecx
andl %r13d, %ecx
orl $0x100, %ecx            # imm = 0x100
movl %ecx, 0xc8(%rsp,%rax)
testl %ebp, %ebp
jle 0x5e11
movl %ebp, %ebp
xorl %ebx, %ebx
leaq 0xb0(%rsp), %r14
leaq 0x3060(%rip), %r15      # 0x8dbd
movq 0xb0(%rsp), %rax
movq -0x18(%rax), %rax
movl 0xc8(%rsp,%rax), %ecx
andl %r13d, %ecx
orl $0x100, %ecx            # imm = 0x100
movl %ecx, 0xc8(%rsp,%rax)
xorps %xmm0, %xmm0
cvtsi2sd %ebx, %xmm0
mulsd 0xa8(%rsp), %xmm0
movq %r14, %rdi
callq 0x22d0
movq %rax, %r12
movl $0x2, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x2200
movq (%r12), %rax
movq -0x18(%rax), %rax
movl 0x18(%r12,%rax), %ecx
andl %r13d, %ecx
orl $0x100, %ecx            # imm = 0x100
movl %ecx, 0x18(%r12,%rax)
movq 0xa0(%rsp), %rax
movsd (%rax,%rbx,8), %xmm0
movq %r12, %rdi
callq 0x22d0
movq %rax, %r12
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r12, %rdi
movl $0xa, %esi
callq 0x21c0
movsbl %al, %esi
movq %r12, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x2110
incq %rbx
cmpq %rbx, %rbp
jne 0x5d5d
leaq 0xb0(%rsp), %rdi
callq 0x2260
movq 0x5193(%rip), %rsi      # 0xafb8
leaq 0x2b0(%rsp), %rdi
callq 0x2140
leaq 0x330(%rsp), %rdi
callq 0x2090
movq 0x80(%rsp), %rdi
leaq 0x90(%rsp), %rax
cmpq %rax, %rdi
je 0x5e64
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x21e0
movq 0x5165(%rip), %rax      # 0xafd0
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0xb8(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0xb0(%rsp,%rcx)
callq 0x2170
leaq 0x1a8(%rsp), %rdi
callq 0x2090
xorl %eax, %eax
addq $0x438, %rsp            # imm = 0x438
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5ed3
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x21e0
jmp 0x5ed3
movq %rax, %rbx
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5ef5
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x21e0
jmp 0x5ef5
jmp 0x5ef2
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x5f2f
movq 0x10(%rsp), %rsi
jmp 0x5f19
jmp 0x5f2c
movq %rax, %rbx
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x5f2f
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x21e0
jmp 0x5f2f
jmp 0x5f2c
movq %rax, %rbx
jmp 0x5f58
jmp 0x5f2c
movq %rax, %rbx
movq 0x5082(%rip), %rsi      # 0xafb8
leaq 0x2b0(%rsp), %rdi
callq 0x2140
leaq 0x330(%rsp), %rdi
callq 0x2090
leaq 0x90(%rsp), %r15
movq 0x80(%rsp), %rdi
cmpq %r15, %rdi
je 0x5f75
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x21e0
leaq 0xb0(%rsp), %rdi
callq 0x2270
movq %rbx, %rdi
callq 0x2310