Strange result at the end of alignment

Hi,

I have another question when placing points on an alignment.

When changing the station of my last point to 1050 there are new elements placed at the end of the alignment?

See screen capture.

https://vimeo.com/323685455

Parents
  • Hi Christiaan,

    This looks like the planes for the left and right track intersections are creating additional intersection points at the tail end of the respective alignment curves. Even though that is less than helpful in your situation, this is what is expected: if multiple intersection points between the plane and the curve exist, all of those intersection points are generated. 

    Perhaps using extracted track regions as curve inputs like you have done for the coordinate system may help for the points on the left rail and right rail, too.

    Another approach would be to filter the intersection points to take only those which are within an expected proximity of the intersection plane. That would eliminate the intersection points on the other ends of the curves, too.

    HTH,

         Volker

       

  • Hi Volker, Do you mean by filter the point with another range and if yes where do I have to hook it in the script.... May be it's good to have the possibility to set a distance range from the origin point on the alignment?

    As you can see it's getting a real mess now.

    //Christiaan

  • Hi Christiaan,

    Looking at an improvised, hopefully sufficiently general test case, I have come to the conclusion that filtering may require writing a function that scans through the intersection planes and the intersection points, finding the closest intersection points whenever a plane generates more than one.

    I am attaching the script and my test alignment in a ZIP-archive. Please deposit the two files in the Designs folder of a WorkSet and open intersectionPointFiltering.dgn and run the script in it. The filtering functions are in transactions 9 and 12. That second Point.ByFunction is a copy of the first, just with the other alignment as input.

    The filtering function looks like this:

    function (Plane[] intersectionPlanes, Point[] intersectionPoints)
    {
        Point pntList = {};
        
        for (int i = 0; i < intersectionPlanes.Count; ++i)
        {
            if(intersectionPoints[i].Rank() < 1)
            {
                pntList.Add(intersectionPoints[i]);
            }
            else
            {
                int k = 0;
                double minDist = 0.0;
                
                for (int j = 0; j < intersectionPoints[i].Count; ++j)
                {
                    if (j == 0)
                        minDist = Distance(intersectionPlanes[i], intersectionPoints[i][j]);
                    else
                    {
                        double dist = Distance(intersectionPlanes[i], intersectionPoints[i][j]);
                        if (dist < minDist)
                        {
                            minDist = dist;
                            k = j;
                        }
                    }
                }
                pntList.Add(intersectionPoints[i][k]);
            }
      
        }
        return pntList;
    }

    intersectionPointFiltering.zip

    HTH,

         Volker

       

Reply
  • Hi Christiaan,

    Looking at an improvised, hopefully sufficiently general test case, I have come to the conclusion that filtering may require writing a function that scans through the intersection planes and the intersection points, finding the closest intersection points whenever a plane generates more than one.

    I am attaching the script and my test alignment in a ZIP-archive. Please deposit the two files in the Designs folder of a WorkSet and open intersectionPointFiltering.dgn and run the script in it. The filtering functions are in transactions 9 and 12. That second Point.ByFunction is a copy of the first, just with the other alignment as input.

    The filtering function looks like this:

    function (Plane[] intersectionPlanes, Point[] intersectionPoints)
    {
        Point pntList = {};
        
        for (int i = 0; i < intersectionPlanes.Count; ++i)
        {
            if(intersectionPoints[i].Rank() < 1)
            {
                pntList.Add(intersectionPoints[i]);
            }
            else
            {
                int k = 0;
                double minDist = 0.0;
                
                for (int j = 0; j < intersectionPoints[i].Count; ++j)
                {
                    if (j == 0)
                        minDist = Distance(intersectionPlanes[i], intersectionPoints[i][j]);
                    else
                    {
                        double dist = Distance(intersectionPlanes[i], intersectionPoints[i][j]);
                        if (dist < minDist)
                        {
                            minDist = dist;
                            k = j;
                        }
                    }
                }
                pntList.Add(intersectionPoints[i][k]);
            }
      
        }
        return pntList;
    }

    intersectionPointFiltering.zip

    HTH,

         Volker

       

Children
No Data