{"id":41,"date":"2011-07-17T14:13:18","date_gmt":"2011-07-17T12:13:18","guid":{"rendered":"http:\/\/jaran.de\/goodbits\/?p=41"},"modified":"2016-02-14T12:33:31","modified_gmt":"2016-02-14T11:33:31","slug":"calculating-an-intercept-course-to-a-target-with-constant-direction-and-velocity-in-a-2-dimensional-plane","status":"publish","type":"post","link":"http:\/\/jaran.de\/goodbits\/2011\/07\/17\/calculating-an-intercept-course-to-a-target-with-constant-direction-and-velocity-in-a-2-dimensional-plane\/","title":{"rendered":"Calculating an intercept course to a target with constant direction and velocity (in a 2-dimensional plane)"},"content":{"rendered":"<p>For some game idea I worked on a bit some time ago I needed a bit of maths. Luckily all that was needed was taught at school and with a bit of thinking (and trying) it all worked out:<br \/>\n<img src=\"http:\/\/jaran.de\/files\/pics\/20110716_intercept_course\/intercept2d.png\" alt=\"diagram of a moving object to be intercepted by a projectile\" title=\"diagram of a moving object to be intercepted by a projectile\" \/><\/p>\n<p>Let&#8217;s consider an object at point <img src='http:\/\/s0.wp.com\/latex.php?latex=A&#038;bg=T&#038;fg=000000&#038;s=0' alt='A' title='A' class='latex' \/> moving with the constant speed vector <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Bv%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{v}' title='\\vec{v}' class='latex' \/>. At point <img src='http:\/\/s0.wp.com\/latex.php?latex=B&#038;bg=T&#038;fg=000000&#038;s=0' alt='B' title='B' class='latex' \/> we got the ability to fire a projectile with speed <img src='http:\/\/s0.wp.com\/latex.php?latex=s&#038;bg=T&#038;fg=000000&#038;s=0' alt='s' title='s' class='latex' \/>. Where do we have to aim at to hit the object with our projectile? In other words: what is the location of point <img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/> or what would be the vector <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Bx%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{x}' title='\\vec{x}' class='latex' \/>?<\/p>\n<p>Now let us derive the necessary maths and put it into code&#8230; (requires understanding of vectors and quadratic equations)<\/p>\n<p><!--more--><\/p>\n<p>If <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> denotes the time (such that at <img src='http:\/\/s0.wp.com\/latex.php?latex=t%3D0&#038;bg=T&#038;fg=000000&#038;s=0' alt='t=0' title='t=0' class='latex' \/> we got our object at point <img src='http:\/\/s0.wp.com\/latex.php?latex=A&#038;bg=T&#038;fg=000000&#038;s=0' alt='A' title='A' class='latex' \/> and our &#8220;gun&#8221; at point <img src='http:\/\/s0.wp.com\/latex.php?latex=B&#038;bg=T&#038;fg=000000&#038;s=0' alt='B' title='B' class='latex' \/> then the point of interception will be <img src='http:\/\/s0.wp.com\/latex.php?latex=I+%3D+%5Cvec%7Ba%7D%2Bt%5Ccdot%5Cvec%7Bv%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='I = \\vec{a}+t\\cdot\\vec{v}' title='I = \\vec{a}+t\\cdot\\vec{v}' class='latex' \/>. We also have <img src='http:\/\/s0.wp.com\/latex.php?latex=I+%3D+%5Cvec%7Bb%7D%2Bt%5Ccdot%5Cvec%7Bx%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='I = \\vec{b}+t\\cdot\\vec{x}' title='I = \\vec{b}+t\\cdot\\vec{x}' class='latex' \/> since we&#8217;re trying to find the point at which object and projectile are at the same place (<img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/>) at the same time (<img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/>). If we can calculate <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> we can also calculate <img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/>.<\/p>\n<p>A first attempt would be to set equal our two (equal) locations of <img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/> that is <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Ba%7D%2Bt%5Ccdot%5Cvec%7Bv%7D+%3D+%5Cvec%7Bb%7D%2Bt%5Ccdot%5Cvec%7Bx%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{a}+t\\cdot\\vec{v} = \\vec{b}+t\\cdot\\vec{x}' title='\\vec{a}+t\\cdot\\vec{v} = \\vec{b}+t\\cdot\\vec{x}' class='latex' \/>. However, we don&#8217;t know vector <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Bx%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{x}' title='\\vec{x}' class='latex' \/> but only its length (i.e. the speed of our projectile) <img src='http:\/\/s0.wp.com\/latex.php?latex=%7C%5Cvec%7Bx%7D%7C+%3D+s&#038;bg=T&#038;fg=000000&#038;s=0' alt='|\\vec{x}| = s' title='|\\vec{x}| = s' class='latex' \/>. Using that last information you can set up an equation system and try to solve it. It&#8217;s possible, but very nasty, so let&#8217;s take a different approach:<\/p>\n<p>Since the projectile needs time <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> to get from <img src='http:\/\/s0.wp.com\/latex.php?latex=B&#038;bg=T&#038;fg=000000&#038;s=0' alt='B' title='B' class='latex' \/> to <img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/> we can divide this distance by the known speed <img src='http:\/\/s0.wp.com\/latex.php?latex=s&#038;bg=T&#038;fg=000000&#038;s=0' alt='s' title='s' class='latex' \/> to just derive that <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/>. The distance from <img src='http:\/\/s0.wp.com\/latex.php?latex=B&#038;bg=T&#038;fg=000000&#038;s=0' alt='B' title='B' class='latex' \/> to <img src='http:\/\/s0.wp.com\/latex.php?latex=I&#038;bg=T&#038;fg=000000&#038;s=0' alt='I' title='I' class='latex' \/> is <img src='http:\/\/s0.wp.com\/latex.php?latex=%7C%5Cvec%7Ba%7D%2Bt%5Ccdot%5Cvec%7Bv%7D+-+%5Cvec%7Bb%7D%7C&#038;bg=T&#038;fg=000000&#038;s=0' alt='|\\vec{a}+t\\cdot\\vec{v} - \\vec{b}|' title='|\\vec{a}+t\\cdot\\vec{v} - \\vec{b}|' class='latex' \/> and thus we get <img src='http:\/\/s0.wp.com\/latex.php?latex=t%3D%5Cfrac%7B%7C%5Cvec%7Ba%7D%2Bt%5Ccdot%5Cvec%7Bv%7D+-+%5Cvec%7Bb%7D%7C%7D%7Bs%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='t=\\frac{|\\vec{a}+t\\cdot\\vec{v} - \\vec{b}|}{s}' title='t=\\frac{|\\vec{a}+t\\cdot\\vec{v} - \\vec{b}|}{s}' class='latex' \/>. Now we got the problem that our <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> is on both sides of the equation which unfortunately cannot be solved by &#8220;simple&#8221; means like multiplying and dividing both sides of the equation with whatever. It appears we&#8217;ve got to get rid of the vectors first but before doing so let&#8217;s clean up things a bit:<\/p>\n<p>The numerator contains the term <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Ba%7D+-+%5Cvec%7Bb%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{a} - \\vec{b}' title='\\vec{a} - \\vec{b}' class='latex' \/> which are two known figures in our problem. Hence we will just use <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Bo%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{o}' title='\\vec{o}' class='latex' \/> (o like offset between a and b) instead, that is <img src='http:\/\/s0.wp.com\/latex.php?latex=%5Cvec%7Bo%7D+%3D+%5Cvec%7Ba%7D+-+%5Cvec%7Bb%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='\\vec{o} = \\vec{a} - \\vec{b}' title='\\vec{o} = \\vec{a} - \\vec{b}' class='latex' \/> which gives us the simpler equation <img src='http:\/\/s0.wp.com\/latex.php?latex=t%3D%5Cfrac%7B%7C%5Cvec%7Bo%7D%2Bt%5Ccdot%5Cvec%7Bv%7D%7C%7D%7Bs%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='t=\\frac{|\\vec{o}+t\\cdot\\vec{v}|}{s}' title='t=\\frac{|\\vec{o}+t\\cdot\\vec{v}|}{s}' class='latex' \/>. To get rid of the fraction we also multiply both sides with <img src='http:\/\/s0.wp.com\/latex.php?latex=s&#038;bg=T&#038;fg=000000&#038;s=0' alt='s' title='s' class='latex' \/> and get <img src='http:\/\/s0.wp.com\/latex.php?latex=s+%5Ccdot+t+%3D+%7C%5Cvec%7Bo%7D+%2B+t+%5Ccdot+%5Cvec%7Bv%7D%7C&#038;bg=T&#038;fg=000000&#038;s=0' alt='s \\cdot t = |\\vec{o} + t \\cdot \\vec{v}|' title='s \\cdot t = |\\vec{o} + t \\cdot \\vec{v}|' class='latex' \/>. Now that&#8217;s better! Just let&#8217;s get rid of the vectors and their <a href=\"http:\/\/en.wikipedia.org\/wiki\/Euclidean_vector#Length\">vector length operator<\/a> in one fell swoop.<\/p>\n<p>Since the length of a vector is the square root of the sum of the squares of its components we get <img src='http:\/\/s0.wp.com\/latex.php?latex=s+%5Ccdot+t+%3D+%5Csqrt%7B%28o_x+%2B+t+%5Ccdot+v_x%29%5E2%2B%28o_y+%2B+t+%5Ccdot+v_y%29%5E2%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='s \\cdot t = \\sqrt{(o_x + t \\cdot v_x)^2+(o_y + t \\cdot v_y)^2}' title='s \\cdot t = \\sqrt{(o_x + t \\cdot v_x)^2+(o_y + t \\cdot v_y)^2}' class='latex' \/>, where the subscripts denote the respective components of the vectors. By squaring both sides we can also get rid of the square root: <img src='http:\/\/s0.wp.com\/latex.php?latex=s%5E2+%5Ccdot+t%5E2+%3D+%28o_x+%2B+t+%5Ccdot+v_x%29%5E2%2B%28o_y+%2B+t+%5Ccdot+v_y%29%5E2&#038;bg=T&#038;fg=000000&#038;s=0' alt='s^2 \\cdot t^2 = (o_x + t \\cdot v_x)^2+(o_y + t \\cdot v_y)^2' title='s^2 \\cdot t^2 = (o_x + t \\cdot v_x)^2+(o_y + t \\cdot v_y)^2' class='latex' \/>. Now we finally have a chance to sort out all the variables by simple transformations. The brackets can be squared out either manually or by binomic equivalences and then we can factor out <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> and order the terms to finally get <img src='http:\/\/s0.wp.com\/latex.php?latex=t%5E2%5Ccdot%28v_x%5E2+%2B+v_y%5E2+-+s%5E2%29+%2B+t%5Ccdot2%5Ccdot%28o_x+%5Ccdot+v_x+%2B+o_y+%5Ccdot+v_y%29+%2B+o_x%5E2+%2B+o_y%5E2%3D+0&#038;bg=T&#038;fg=000000&#038;s=0' alt='t^2\\cdot(v_x^2 + v_y^2 - s^2) + t\\cdot2\\cdot(o_x \\cdot v_x + o_y \\cdot v_y) + o_x^2 + o_y^2= 0' title='t^2\\cdot(v_x^2 + v_y^2 - s^2) + t\\cdot2\\cdot(o_x \\cdot v_x + o_y \\cdot v_y) + o_x^2 + o_y^2= 0' class='latex' \/> which is a <a href=\"http:\/\/en.wikipedia.org\/wiki\/Quadratic_equation\">quadratic equation<\/a> that can be solved. Before doing so however we take a look at its components and try to simplify our calculation. Since we could fill in numbers for all variables but <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> we do so by substituting with simpler &#8220;helper&#8221; variables denoted by the following definitions: <img src='http:\/\/s0.wp.com\/latex.php?latex=h_1+%3A%3D+v_x%5E2+%2B+v_y%5E2+-+s%5E2&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_1 := v_x^2 + v_y^2 - s^2' title='h_1 := v_x^2 + v_y^2 - s^2' class='latex' \/>;<img src='http:\/\/s0.wp.com\/latex.php?latex=h_2+%3A%3D+o_xv_x+%2B+o_yv_y&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_2 := o_xv_x + o_yv_y' title='h_2 := o_xv_x + o_yv_y' class='latex' \/>;<img src='http:\/\/s0.wp.com\/latex.php?latex=h_3+%3D+o_x%5E2%2Bo_y%5E2&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_3 = o_x^2+o_y^2' title='h_3 = o_x^2+o_y^2' class='latex' \/>. Thus, by dividing our last equation by <img src='http:\/\/s0.wp.com\/latex.php?latex=h_1&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_1' title='h_1' class='latex' \/> we get the simple quadratic equation <img src='http:\/\/s0.wp.com\/latex.php?latex=t%5E2+%2Bt%5Ccdot+2%5Ccdot+h_2+%2B+h_3&#038;bg=T&#038;fg=000000&#038;s=0' alt='t^2 +t\\cdot 2\\cdot h_2 + h_3' title='t^2 +t\\cdot 2\\cdot h_2 + h_3' class='latex' \/> which, being quadratic, gives us two (or one, or none) solutions: <img src='http:\/\/s0.wp.com\/latex.php?latex=t_%7B1%2C2%7D+%3D+-%5Cfrac%7Bh_2%7D%7Bh_1%7D+%5Cpm+%5Csqrt%7B%28%5Cfrac%7Bh_2%7D%7Bh_1%7D%29%5E2+-+%5Cfrac%7Bh_3%7D%7Bh_1%7D%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='t_{1,2} = -\\frac{h_2}{h_1} \\pm \\sqrt{(\\frac{h_2}{h_1})^2 - \\frac{h_3}{h_1}}' title='t_{1,2} = -\\frac{h_2}{h_1} \\pm \\sqrt{(\\frac{h_2}{h_1})^2 - \\frac{h_3}{h_1}}' class='latex' \/>.<\/p>\n<p>If the expression under the square root is negative the equation got no solution and we can never hit the object with our projectile since it is too slow. If the square root works out to some positive value we got two solutions. Solutions with a negative value for <img src='http:\/\/s0.wp.com\/latex.php?latex=t&#038;bg=T&#038;fg=000000&#038;s=0' alt='t' title='t' class='latex' \/> can be thrown away too, unless you shoot with <a href=\"http:\/\/en.wikipedia.org\/wiki\/Tachyon\">Tachyon-bullets<\/a> \ud83d\ude09<\/p>\n<p>There remains one case to be taken care of: <img src='http:\/\/s0.wp.com\/latex.php?latex=h_1&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_1' title='h_1' class='latex' \/> might be 0 which would result in a division by 0 in the aproach shown above. But actually the case where <img src='http:\/\/s0.wp.com\/latex.php?latex=h_1&#038;bg=T&#038;fg=000000&#038;s=0' alt='h_1' title='h_1' class='latex' \/> is 0 is the mathematically simpler case. The quadratic equation collapses and all that remains is the simple equation <img src='http:\/\/s0.wp.com\/latex.php?latex=t%5Ccdot2%5Ccdot+h_2+%2B+h_3+%3D+0&#038;bg=T&#038;fg=000000&#038;s=0' alt='t\\cdot2\\cdot h_2 + h_3 = 0' title='t\\cdot2\\cdot h_2 + h_3 = 0' class='latex' \/> which of course results in <img src='http:\/\/s0.wp.com\/latex.php?latex=t+%3D+-%5Cfrac%7Bh_3%7D%7B2h_2%7D&#038;bg=T&#038;fg=000000&#038;s=0' alt='t = -\\frac{h_3}{2h_2}' title='t = -\\frac{h_3}{2h_2}' class='latex' \/>. Thanks to David (see comments below) for pointing that out. It got rid of an ugly &#8216;quick fix&#8217; I used before.<\/p>\n<p>And now in the form of Java code:<\/p>\n<pre lang=\"Java\" line=\"1\"> \r\n\t\/**\r\n\t * Calculates the point of interception for one object starting at point\r\n\t * <code>a<\/code> with speed vector <code>v<\/code> and another object\r\n\t * starting at point <code>b<\/code> with a speed of <code>s<\/code>.\r\n\t * \r\n\t * @see <a\r\n\t *      href=\"http:\/\/jaran.de\/goodbits\/2011\/07\/17\/calculating-an-intercept-course-to-a-target-with-constant-direction-and-velocity-in-a-2-dimensional-plane\/\">Calculating\r\n\t *      an intercept course to a target with constant direction and velocity\r\n\t *      (in a 2-dimensional plane)<\/a>\r\n\t * \r\n\t * @param a\r\n\t *            start vector of the object to be intercepted\r\n\t * @param v\r\n\t *            speed vector of the object to be intercepted\r\n\t * @param b\r\n\t *            start vector of the intercepting object\r\n\t * @param s\r\n\t *            speed of the intercepting object\r\n\t * @return vector of interception or <code>null<\/code> if object cannot be\r\n\t *         intercepted or calculation fails\r\n\t * \r\n\t * @author Jens Seiler\r\n\t *\/\r\n\tpublic static Point2D calculateInterceptionPoint(final Point2D a, final Point2D v, final Point2D b, final double s) {\r\n\t\tfinal double ox = a.getX() - b.getX();\r\n\t\tfinal double oy = a.getY() - b.getY();\r\n\t\t\r\n\t\tfinal double h1 = v.getX() * v.getX() + v.getY() * v.getY() - s * s;\r\n\t\tfinal double h2 = ox * v.getX() + oy * v.getY();\r\n\t\tdouble t;\r\n\t\tif (h1 == 0) { \/\/ problem collapses into a simple linear equation \r\n\t\t\tt = -(ox * ox + oy * oy) \/ (2*h2);\r\n\t\t} else { \/\/ solve the quadratic equation\r\n\t\t\tfinal double minusPHalf = -h2 \/ h1;\r\n\t\t\t \r\n\t\t\tfinal double discriminant = minusPHalf * minusPHalf - (ox * ox + oy * oy) \/ h1; \/\/ term in brackets is h3\r\n\t\t\tif (discriminant < 0) { \/\/ no (real) solution then...\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\t \r\n\t\t\tfinal double root = Math.sqrt(discriminant);\r\n\t\t \r\n\t\t\tfinal double t1 = minusPHalf + root;\r\n\t\t\tfinal double t2 = minusPHalf - root;\r\n\t\t \r\n\t\t\tfinal double tMin = Math.min(t1, t2);\r\n\t\t\tfinal double tMax = Math.max(t1, t2);\r\n\t\t \r\n\t\t\tt = tMin > 0 ? tMin : tMax; \/\/ get the smaller of the two times, unless it's negative\r\n\t\t\tif (t < 0) { \/\/ we don't want a solution in the past\r\n\t\t\t\treturn null;\r\n\t\t\t}\r\n\t\t}\r\n\t \r\n\t\t\/\/ calculate the point of interception using the found intercept time and return it\r\n\t\treturn new Point2D.Double(a.getX() + t * v.getX(), a.getY() + t * v.getY());\r\n\t}\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>For some game idea I worked on a bit some time ago I needed a bit of maths. Luckily all that was needed was taught at school and with a bit of thinking (and trying) it all worked out: Let&#8217;s &hellip;<\/p>\n<p class=\"read-more\"><a href=\"http:\/\/jaran.de\/goodbits\/2011\/07\/17\/calculating-an-intercept-course-to-a-target-with-constant-direction-and-velocity-in-a-2-dimensional-plane\/\">Read more &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0},"categories":[5,8,9],"tags":[],"_links":{"self":[{"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/posts\/41"}],"collection":[{"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/comments?post=41"}],"version-history":[{"count":43,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/posts\/41\/revisions"}],"predecessor-version":[{"id":475,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/posts\/41\/revisions\/475"}],"wp:attachment":[{"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/media?parent=41"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/categories?post=41"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/jaran.de\/goodbits\/wp-json\/wp\/v2\/tags?post=41"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}