aboutsummaryrefslogtreecommitdiff
path: root/vendor/voclient/libvoclient/examples/f77skybot.f
blob: e6e538ef5235cdeea310a4088738d9945f7ab385 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
C
C  F77SKYBOT -- Fortran example task of VOClient SkyBoT interface
C
C  M.Fitzpatrick, NOAO, Aug 2006

	program f77skybot

	double precision ra, dec, sr, epoch, vmag
	character 	name*15
	integer		skybot, nobjs, len, i

 	ra = 0.0
 	dec = 0.0
 	sr = 600.0
 	epoch = 2454545.0

	print *, "#"
	print *, "# ra=", ra, "  dec=", dec, " sr=", sr, " epoch=", epoch
	print *, "#"
	call vfskybot (ra, dec, sr, sr, epoch, skybot)
	call vfskybotnobjs (skybot, nobjs)

	print *, "#"
	print *, "# Found ", nobjs, " objects"
	print *, "#"

	do 10 i = 1, nobjs
	  call vfskybotstr (skybot, "name", i, name, len)
	  call vfskybotdbl (skybot, "ra", i, ra)
	  call vfskybotdbl (skybot, "dec", i, dec)
	  call vfskybotdbl (skybot, "vmag", i, vmag)

	  print *, "Obj: ", name, "  ra=", ra, "  dec=", dec, " Mv=", vmag

10	continue

	stop
	end