[go: up one dir, main page]

Menu

[r34]: / common / dierckx / fpgivs.f  Maximize  Restore  History

Download this file

21 lines (20 with data), 497 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
subroutine fpgivs(piv,ww,cos,sin)
c subroutine fpgivs calculates the parameters of a givens
c transformation .
c ..
c ..scalar arguments..
real piv,ww,cos,sin
c ..local scalars..
real dd,one,store
c ..function references..
real abs,sqrt
c ..
one = 0.1e+01
store = abs(piv)
if(store.ge.ww) dd = store*sqrt(one+(ww/piv)**2)
if(store.lt.ww) dd = ww*sqrt(one+(piv/ww)**2)
cos = ww/dd
sin = piv/dd
ww = dd
return
end