title: Creating directory with name containing real number in FORTRAN
body: <p>In my program I need to store result files for different cases. I have decided to create separate directories to store these result files. To explain the exact situation here is a pseudo code.</p>
  
  <pre><code>do i=1,N     ! N cases of my analysis
      U=SPEED(i)
      call write_files(U)     !Create a new directory for this case and Open files (1 = a.csv, 2 = b.csv) to write data
      call postprocess()      !Write data in files (a.csv, b.csv)
      call close_files()      !Close all files (1,2)
  end do
  
  subroutine write_files(i)
      !Make directory i
      !Open file a.csv and b.csv with unit 1 &amp; 2
      !Write header information in file a.csv and b.csv
  close subroutine
  </code></pre>
  
  <p>I am struggling in converting the real variable U to a character variable so that I can use <code>call system('mkdir out/' trim(U))</code> to create separate folders to store my results. </p>
  
  <p>I would also like to mention that my variable U is speed which is like <code>0.00000, 1.00000, 1.50000</code> etc. Is there a way I can simplify my directory name so it is like <code>0,1,1.5</code> etc.</p>
  
  <p>Hope my explanation is clear. If not let me know, I will try to edit as required.</p>
  
  <p>Thank you for help.</p>