// Interval
        public Interval IntervalToSpeckle(RH.Interval interval)
        {
            var speckleInterval = new Interval(interval.T0, interval.T1);

            return(speckleInterval);
        }
        // Proper explosion of polycurves:
        // (C) The Rutten David https://www.grasshopper3d.com/forum/topics/explode-closed-planar-curve-using-rhinocommon
        public bool CurveSegments(List <RH.Curve> L, RH.Curve crv, bool recursive)
        {
            if (crv == null)
            {
                return(false);
            }

            PolyCurve polycurve = crv as PolyCurve;

            if (polycurve != null)
            {
                if (recursive)
                {
                    polycurve.RemoveNesting();
                }

                RH.Curve[] segments = polycurve.Explode();

                if (segments == null)
                {
                    return(false);
                }

                if (segments.Length == 0)
                {
                    return(false);
                }

                if (recursive)
                {
                    foreach (RH.Curve S in segments)
                    {
                        CurveSegments(L, S, recursive);
                    }
                }
                else
                {
                    foreach (RH.Curve S in segments)
                    {
                        L.Add(S.DuplicateShallow() as RH.Curve);
                    }
                }

                return(true);
            }

            //Nothing else worked, lets assume it's a nurbs curve and go from there...
            var nurbs = crv.ToNurbsCurve();

            if (nurbs == null)
            {
                return(false);
            }

            double t0 = nurbs.Domain.Min;
            double t1 = nurbs.Domain.Max;
            double t;

            int LN = L.Count;

            do
            {
                if (!nurbs.GetNextDiscontinuity(Continuity.C1_locus_continuous, t0, t1, out t))
                {
                    break;
                }

                var trim = new RH.Interval(t0, t);
                if (trim.Length < 1e-10)
                {
                    t0 = t;
                    continue;
                }

                var M = nurbs.DuplicateCurve();
                M = M.Trim(trim);
                if (M.IsValid)
                {
                    L.Add(M);
                }

                t0 = t;
            } while (true);

            if (L.Count == LN)
            {
                L.Add(nurbs);
            }

            return(true);
        }