Questions tagged [coordinate]

Refers to mathematical tasks involving geometric coordinates. Please consider also including language specific tags to better direct users to your question.

A coordinate is a representation of a position in space. You can find more information here:

https://en.wikipedia.org/wiki/Coordinate_system

333 questions
46
votes
12 answers

Java: What is a good data structure for storing a coordinate map for an infinite game world?

I am used to coding in PHP but I am not really proficient with Java and this has been a problem for some time now. I expect it to be a fairly easy solution, however I cannot find any good example code any way I search it, so here goes: I am…
Aykın
  • 629
  • 1
  • 7
  • 11
40
votes
6 answers

Faster numpy cartesian to spherical coordinate conversion?

I have an array of 3 million data points from a 3-axiz accellerometer (XYZ), and I want to add 3 columns to the array containing the equivalent spherical coordinates (r, theta, phi). The following code works, but seems way too slow. How can I do…
BobC
  • 3,320
  • 5
  • 24
  • 30
20
votes
3 answers

How to get object in WebGL 3d space from a mouse click coordinate

I'm building a boardgame in WebGL. The board can be rotated/zoomed. I need a way to translate a click on the canvas element (x,y) into the relevant point in 3D space (x, y, z). The ultimate result is that I want to know the (x, y, z) coordinate that…
seibelj
  • 890
  • 2
  • 10
  • 22
19
votes
3 answers

Convert Quaternion representing rotation from one coordinate system to another

I am getting a quaternion from sensor data that is in the coordinate system Y=up, X=right, and Z= backwards.Mine is X=forward, Y=right, Z=up. So OX=Y, OY=Z and OZ=-X. I have a function that can convert quaternions into 4by4 matrices, but no idea…
Craig Delancy
  • 191
  • 1
  • 1
  • 3
19
votes
2 answers

How get bottom y coordinate

How can I get the bottom left coordinate, i.e. the maximum y coordinate, of a view in obj-c and Swift?
Alessio Vinaccia
  • 211
  • 1
  • 2
  • 5
13
votes
6 answers

How to find out Y coordinate of specific point in bezier curve in canvas?

I need to find out Y coordinate of specific point of bezier curve in canvas. Do you know, how to find it out? Thank you
Jan Kožušník
  • 683
  • 3
  • 16
  • 30
12
votes
2 answers

ggplot2 polar plot axis label location

This is just a extension for a old question ggplot2 polar plot arrows You will find the x axis is out of the most_out circle. In ggplot2, I use "panel.grid.major = theme_line(colour = "black", size = 0.2, linetype=2)" to get the dashed circle,…
boyang
  • 377
  • 1
  • 4
  • 8
11
votes
3 answers

What is this algorithm mapping coordinates to numbers called?

I'm writing a program for visualizing crystals. As a part of the program, I have to generate all different basic points in a lattice structure. For those that aren't familiar with crystallography, you can find the most general cases of these…
10
votes
1 answer

Row-major order indices

I'm currently working on project of where 2d terrain maps are saved into a one-dimensional array. Each block in the map is indexed by xy coordinates. So, to save the map into a one-dimensional array, I used the row-major order method…
BizarreCake
  • 662
  • 5
  • 14
10
votes
2 answers

MySQL GIS Lat/Lon to X/Y: which is which?

Is there a convention for whether GIS points in MySQL should be stored as POINT($latitude $longitude) or POINT($longitude $latitude)? Having longitude correspond to X on a cartesian map would visually make more sense with north pointing up, but…
erjiang
  • 44,417
  • 10
  • 64
  • 100
8
votes
1 answer

How to rotate coordinate system?

I am trying to find the new value of a coordinate if I rotate around the origin. For example, say I have the point (1,1). If I rotate the coordinate axis 45 degrees around the origin, the transformed coordinate would be (0,1.414) Is there a way to…
xcoder
  • 967
  • 2
  • 11
  • 24
8
votes
2 answers

Using GeoTools: What is the Latitude and Longitude in com.vividsolutions.jts.geom.Coordinate class?

I will use com.vividsolutions.jts.geom.Coordinate as my coordinate class. But don't find any document which is the correct order of the coordinate. is it standard? Here's the java doc link ->…
eros
  • 4,946
  • 18
  • 53
  • 78
8
votes
1 answer

How to get 3D coordinate Axes of head pose estimation in Dlib C++

Dlib C++ can detect landmark and estimate face pose very well. However, how can I get 3D coordinate Axes direction (x,y,z) of head pose?
Rain Maker
  • 152
  • 1
  • 3
  • 6
7
votes
1 answer

How to convert Earth Centered Inertial (ECI) coordinates to Earth Centered Earth Fixed (ECEF) AstroPy? Other?

I have position (x,y,z) and velocity (Vx,Vy,Vz) vectors in Earth Centered Inertial Coordinates (ECI) for a satellite orbit, and ultimately want to end up with geodetic coordinates (Latitude, Longitude, & Altitude). According to this other Stack…
7
votes
3 answers

How to store GPS coordinate and search places in a radius from a NoSQL DBMS (like DynamoDB)

My team needs a DBMS like DynamoDB to store large amount of data, principally places and coordinates. I've considered to use some GIS-based DBMS (like PostGIS) with an index on the POINT, but DynamoDB seems great for our use. What is the best method…
Marco Sero
  • 460
  • 6
  • 18
1
2 3
22 23