~~waves~~

1

Please login or register to vote for this query.

(click on this box to dismiss)

RUN query, then click the GRAPH tab to view

Physical Fitness Meta

Q&A about the site for physical fitness professionals, athletes, trainers, and those providing health-related needs

declare @Radius float =500                                          --units radius (Radius=Diameter÷2)
declare @numberOfPositions float = 360                              --how many dots to draw for a circle
declare @radiansPerPosition float=(360/@numberOfPositions)*pi()/180 --'radians = degrees × pi / 180°
declare @x float, @y float
create table #xy (x float, label varchar(1000), y float)

set @x=0
while @x <= @numberOfPositions - 1  --Create circle
  begin
    set @y = Cos(2* @radiansPerPosition * @x) *@Radius 
    insert into #xy(x,label,y) values (@x,' ',@y) 
    set @x=@x+1
  end

set @x=0
while @x <= @numberOfPositions - 1  --Create circle
  begin
    
    set @y = Sin(2* @radiansPerPosition * @x) * @Radius 
    insert into #xy(x,label,y) values (@x,'  ',@y) 
    set @x=@x+1
  end


select * from #xy

Enter Parameters

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