another graph pattern

1

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow на русском Meta

Вопросы и ответы о сайте для программистов

create table #out (x float, label varchar(20), y float)
declare @x float, @y float, @c int

set @c = 1
set @y = 0
while @y <= 2925
  begin
  set @x = sin(.5*cos(@y))
  insert into #out (x,label,y) values (@x, 'c'+convert(varchar,@c) , @y)  --replicate(' ',@c) 
    set @y = @y + 0.1
    if @c=10 set @c=1 else set @c=@c+1
  end
  

select * from #out

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results