search for: atan2

Displaying 20 results from an estimated 92 matches for "atan2".

Did you mean: ata2
2007 Nov 22
0
5 commits - libswfdec/swfdec_as_interpret.c libswfdec/swfdec_bits.c libswfdec/swfdec_bits.h libswfdec/swfdec_debugger.c libswfdec/swfdec_movie.c libswfdec/swfdec_script.c libswfdec/swfdec_sprite_movie.c libswfdec/swfdec_tag.c libswfdec/swfdec_text_field.c
...ts.h | 3 +-- libswfdec/swfdec_debugger.c | 2 +- libswfdec/swfdec_movie.c | 2 +- libswfdec/swfdec_script.c | 2 +- libswfdec/swfdec_sprite_movie.c | 4 ++-- libswfdec/swfdec_tag.c | 4 ++-- libswfdec/swfdec_text_field.c | 4 ++-- test/trace/atan2-5.swf |binary test/trace/atan2-5.swf.trace | 6 ++++++ test/trace/atan2-6.swf |binary test/trace/atan2-6.swf.trace | 6 ++++++ test/trace/atan2-7.swf |binary test/trace/atan2-7.swf.trace | 6 ++++++ test/trace/atan2-8.swf |binary test/trace/...
2006 Mar 28
2
atan2(1,1i)
Hi ?atan2 says that atan2(y,x)=atan(y/x) for x and y numeric or complex vectors. Well, I would expect atan2(1,1i) to be equal to atan(-1i), but > atan2(1,1i) Error in atan2(y, x) : Non-numeric argument to mathematical function > R.version _ platform powerpc-apple-darwin8.5.0...
2006 Mar 28
2
atan2(1,1i)
Hi ?atan2 says that atan2(y,x)=atan(y/x) for x and y numeric or complex vectors. Well, I would expect atan2(1,1i) to be equal to atan(-1i), but > atan2(1,1i) Error in atan2(y, x) : Non-numeric argument to mathematical function > R.version _ platform powerpc-apple-darwin8.5.0...
2005 Apr 14
1
Strange behavior of atan2
Dear all, I've got a problem with the function atan2. For a couple of coordinates x and y, This function returns the angle between the vector of coordinates (x, y) and the abscissa axis, i.e. it is the same as atan(y/x) (as indicated on the help page). If we consider the vector with coordinates x = 0 and y = 0, we have the following result: &gt...
2007 Nov 27
3
[LLVMdev] Other Intrinsics?
...perations. What is the criteria for adding an intrinsic or a built-in operation? For example, could the 'frem' instruction be an intrinsic? Could you remove it from LLVM entirely and make it an external function? What distinguishes 'frem' from 'sin', 'pow', 'atan2', etc.? Regards, Jon
2007 Oct 17
0
curly bracket in plot (reply)
.... library(grid) # function to draw curly braces in red # x1...y2 are the ends of the brace # for upside down braces, x1 > x2 and y1 > y2 Brack <- function(x1,y1,x2,y2,h) { x2 <- x2-x1; y2 <- y2-y1 v1 <- viewport(x=x1,y=y1,width=sqrt(x2^2+y2^2), height=h,angle=180*atan2(y2,x2)/pi, just=c("left","bottom"),gp=gpar(col="red")) pushViewport(v1) grid.curve(x2=0,y2=0,x1=.125,y1=.5,curvature=.5) grid.move.to(.125,.5) grid.line.to(.375,.5) grid.curve(x1=.375,y1=.5,x2=.5,y2=1,curvature=.5) grid.curve(x2=1,y2=0,x1=.875,y1=.5,curv...
2007 Nov 27
0
[LLVMdev] Other Intrinsics?
...t is the criteria for adding an intrinsic or a built-in operation? > For example, could the 'frem' instruction be an intrinsic? Could you > remove it from LLVM entirely and make it an external function? What > distinguishes 'frem' from 'sin', 'pow', 'atan2', etc.? The main difference from my perspective between intrinsics and instructions is that intrinsics don't require bitcode format changes. If someone wants an atan2 intrinsic for example, it would be fairly easy, and we wouldn't have to worry very much about collisions with other peo...
2011 Aug 09
1
rgl how to plot a cylinder like arrow3d?
..., e1=cbind(0, 0, 1), e2=cbind(1, 0, 0), sides=10 ) # ... rotate cylinder horizontally and scale it len=sqrt(sum(abs(end)*abs(end))) c=scale3d(c,0.1,0.1,len) c=rotate3d(c,-(pi/2),0,1,0) # ... rotation angles theta = atan2(end[2],end[1]) # angle in yx-plane for Z-achses rotation phi = atan2(end[3],sqrt(end[1]^2+end[1]^2)) # angle in zx for Y-achses rotation # ... rotation c=rotate3d(c,phi,0,1,0) # Y-achses rotation c=rotate3d(c, -theta,0,0,1) # Z-achses rotation shade3d(addNormals(c), col=mycol) } open3d() vector...
2008 May 21
1
colorspace package does not compile on ubuntu 7.04 32 bit
...orspace.c: In function ?XYZ_to_HLAB?: colorspace.c:170: warning: implicit declaration of function ?sqrt? colorspace.c:170: warning: incompatible implicit declaration of built-in function ?sqrt? colorspace.c: In function ?LAB_to_polarLAB?: colorspace.c:203: warning: implicit declaration of function ?atan2? colorspace.c:203: warning: incompatible implicit declaration of built-in function ?atan2? colorspace.c:207: warning: incompatible implicit declaration of built-in function ?sqrt? colorspace.c: In function ?polarLAB_to_LAB?: colorspace.c:216: warning: implicit declaration of function ?cos? colorspa...
2009 Oct 24
2
ifelse
When I run this code from an R-script: ddd = 360 + round ( atan2(-u,-v) / d2r ) print(class(ddd)) print(ddd) ifelse ( ddd>360, ddd-360, ddd ) print(ddd) I get this output: [1] "numeric" [1] 461 213 238 249 251 [1] 461 213 238 249 251 Why does ifelse not change the 461 to 101? I recreated the vector ddd an...
2017 Mar 28
2
A trap for young players with the lapply() function.
On 28/03/17 15:26, Charles C. Berry wrote: > On Mon, 27 Mar 2017, Rolf Turner wrote: > >> >> From time to time I get myself into a state of bewilderment when using >> apply() by calling it with FUN equal to a function which has an >> "optional" argument named "X". >> >> E.g. >> >> xxx <-
2008 Jan 06
3
Can a dynamic graphic produced by rgl be saved?
Dear r-helpers, Can one save a dynamic graphic produced by rgl, e.g.: open3d(); x <- sort(rnorm(1000)); y <- rnorm(1000); z <- rnorm(1000) + atan2(x,y); plot3d(x, y, z, col=rainbow(1000), size=2) as a dynamic figure that can be embedded in a pdf? _____________________________ Professor Michael Kubovy University of Virginia Department of Psychology USPS: P.O.Box 400400 Charlottesville, VA 22904-4400 Parcels: Room 102 Gilmer...
2011 Jan 20
1
Generating time progressing line for Google Earth
...vals for(i in 1 : numberOfIntervals) { distance = i * distance_slice ang_dist = distance / 6371.0 lon_1 = Radians(start_point.Long); lat_1 = Radians(start_point.Lat); lat_2 = Radians(end_point.Lat); lon_diff = Radians(end_point.Long - start_point.Long); # First calculate the bearing bearing = atan2( sin(lon_diff) * cos(lat_2), (cos(lat_1) * sin(lat_2)) - (sin(lat_1) * cos(lat_2) * cos(lon_diff)) ); # Then use the bearing and the start point to find the destination new_lat_rad = asin(sin(lat_1) * cos(ang_dist) + cos(lat_1) * sin(ang_dist) * cos(bearing)); new_lon_rad = lon_1 + atan2( sin(bear...
1998 Sep 16
2
R-beta: (0+0i)^2
The following behaviour (in R 0.62.3) is disturbing: > (0+0i)^2 [1] NaN+NaNi Is it deliberate?? Laimonis Kavalieris -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To:
1998 Sep 16
2
R-beta: (0+0i)^2
The following behaviour (in R 0.62.3) is disturbing: > (0+0i)^2 [1] NaN+NaNi Is it deliberate?? Laimonis Kavalieris -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To:
2020 Oct 08
2
unable to plot bode - phase with control package
...am of a siso model using the 'bodeplot' command in the control package fail due to error in 'issiso' evaluation... Error in if (issiso(sys)) {: then I try by myself some retro-engineering :) the problem is when I use H <- freqresp(syst, w) mag = 20*log10(abs(H)) phase <- atan2(Im(H), Re(H)) * 180/pi if the order of the system is higher than 2 it is wrong (result will be only between -pi / pi) how to proceed ? for each evaluated point take a derivative and evaluate the order to add the proper number of pi ? Thanks for the help ! Best Fr?d?ric
2009 Mar 23
1
Axes in 3D plots
I am wondering if anyone knows how to change or rotate the default axes on a 3D scatterplot. I would like to change which sides of the cube the 3 axes are displayed on. Many thanks, Leah Gerber [[alternative HTML version deleted]]
2017 Mar 28
0
A trap for young players with the lapply() function.
...med "X", "FUN", "USE.NAMES", etc. and perhaps make use of R's lexical scoping to avoid having to use many arguments to the function. E.g., instead of sapply(1:5, sin) use sapply(1:5, function(theta) sin(theta)) or instead of myY <- 3 sapply(1:5, atan2, y=myY) use myY <- 3 sapply(1:5, function(x) atan2(myY, x)) Bill Dunlap TIBCO Software wdunlap tibco.com On Tue, Mar 28, 2017 at 2:30 PM, Rolf Turner <r.turner at auckland.ac.nz> wrote: > On 28/03/17 15:26, Charles C. Berry wrote: >> >> On Mon, 27 Mar 2017, Rolf T...
2008 Nov 17
2
How to calculate the linear distance between 2 points
Deemed colleagues I would appreciate your help with a sentence to calculate the linear distance between 2 geographical points (coordinates in UTM). In advance thnks for your attention, -- Ricardo Bandin Llanos rbandin@udec.cl Estudiante - Magíster Cs. m. Pesquerías Universidad de Concepción, Región del Bio-Bio, Chile Celular: (0056-41) 97949957 [[alternative HTML version deleted]]
2007 Nov 27
2
[LLVMdev] Other Intrinsics?
...riteria for adding an intrinsic or a built-in operation? >> For example, could the 'frem' instruction be an intrinsic? Could you >> remove it from LLVM entirely and make it an external function? What >> distinguishes 'frem' from 'sin', 'pow', 'atan2', etc.? > > The main difference from my perspective between intrinsics and instructions > is that intrinsics don't require bitcode format changes. If someone wants an > atan2 intrinsic for example, it would be fairly easy, and we wouldn't have > to worry very much about c...