Ok, I did some more research into this problem and I found this:

- on an untrimmed BRep it works (see plane in attached document), but on a trimmed BRep it does not work (see trimmed cylinder in attached document).
- Adding or subtracting RhinoMath.ZeroTolerance to the parameter values of the domain boundaries works in both cases.

I have to wonder about this odd behavior, especially as the cylinder boundaries give *exactly* the same curves with the code below (SelDup works).

trim_aware_isocurve_problem.3dm (35.4 KB)

```
public Result RunCommand(RhinoDoc doc, RunMode mode)
{
ObjRef bRef;
Result res = RhinoGet.GetOneObject("brep", false, ObjectType.Brep, out bRef);
if (res != Result.Success) return res;
Brep b = bRef.Brep();
Interval u = b.Faces[0].Domain(0);
Interval v = b.Faces[0].Domain(1);
double delta = RhinoMath.ZeroTolerance;
// double delta = 0.0; // this does not work
Curve[] tu0 = b.Faces[0].TrimAwareIsoCurve(1, u.T0 + delta);
Curve[] tu1 = b.Faces[0].TrimAwareIsoCurve(1, u.T1 - delta);
Curve[] tv0 = b.Faces[0].TrimAwareIsoCurve(0, v.T0 + delta);
Curve[] tv1 = b.Faces[0].TrimAwareIsoCurve(0, v.T1 - delta);
foreach (var a in new[] {tu0, tu1, tv0, tv1}.Where(a => null != a))
{
foreach (var c in a.Where(c => c != null))
{
doc.Objects.AddCurve(c);
}
}
return Result.Success;
}
```