GWtool
Gravitational-wave tool
 All Classes Files Functions Variables Pages
gw_q2eta.f90
Go to the documentation of this file.
1 !> \file gw_q2eta.f90 Compute the symmetric mass ratio eta from the asymmetric mass ratio q
2 
3 !
4 ! GWtool: Simple tools for working with gravitational waves
5 ! http://gwtool.sourceforge.net/
6 !
7 !
8 ! Copyright 2007-2013 AstroFloyd - astrofloyd.org
9 !
10 !
11 ! This file is part of GWtool.
12 !
13 ! GWtool is free software: you can redistribute it and/or modify
14 ! it under the terms of the GNU General Public License as published by
15 ! the Free Software Foundation, either version 3 of the License, or
16 ! (at your option) any later version.
17 !
18 ! GWtool is distributed in the hope that it will be useful,
19 ! but WITHOUT ANY WARRANTY; without even the implied warranty of
20 ! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ! GNU General Public License for more details.
22 !
23 ! You should have received a copy of the GNU General Public License
24 ! along with GWtool. If not, see <http://www.gnu.org/licenses/>.
25 
26 
27 
28 !***********************************************************************************************************************************
29 !> \brief Compute the symmetric mass ratio eta from the asymmetric mass ratio q
30 
31 program gw_q2eta
32  use sufr_kinds, only: double
33  use sufr_system, only: syntax_quit
34 
35  implicit none
36  real(double) :: q, eta
37  character :: tmpstr*(99)
38 
39  if(command_argument_count().eq.1) then
40  call get_command_argument(1,tmpstr)
41  read(tmpstr,*) q
42  else
43  call syntax_quit('<q>', 0, 'This program converts the asymmetric mass ratio q to the asymmetric mass ratio eta')
44  end if
45 
46  eta = q/(1.d0+q)**2
47 
48  write(6,'(/,2x,A,F11.8,/)') 'Eta:', eta
49 
50 end program gw_q2eta
51 !***********************************************************************************************************************************
52 
program gw_q2eta
Compute the symmetric mass ratio eta from the asymmetric mass ratio q.
Definition: gw_q2eta.f90:31