# How to remove these curly brackets?

Given that I have the following code:

points = N@Solve[{x^2 + 3 x - 1 + y - 1 == 0, 3 x - y^2 + 1 - 1 == 0}, Reals];
{x, y} /. points


Which gives me the output:

{{0.93389, -1.67382}, {0.311843, 0.967227}}

In this case, how can I remove the first curly brackets in order to obtain:

{0.93389, -1.67382}, {0.311843, 0.967227}

I tried with

Row[{x, y} /. points]


but I am missing the commas. I need this because I am trying to make a grid, that is why I need the comma.

I do not know if it is allowed to ask two questions on the same post, but, is it possible in the above case to switch automatically between NSolve and Solve?

• Sequence @@ ({x, y} /. points)? At first, it might not look as if it was what you are looking for, but it becomes clearer when you evaluate bla[Sequence @@ ({x, y} /. points)]... You may look up Apply in order to learn why it works. – Henrik Schumacher Jan 29 '18 at 23:53
• With respect to the second question: What do you mean by switching automatically? When would you prefer NSolve and when Solve? – Henrik Schumacher Jan 29 '18 at 23:56
• @HenrikSchumacher I am sorry I did not specify. When the solution involves Root or when it is very complicated, I would prefer NSolve, instead when the solution is simple and can be expressed in "closed form" I would prefer Solve. – DMH16 Jan 29 '18 at 23:59
• @HenrikSchumacher How would I access the elements inside bla? After the evaluation I obtain bla[{0.93389, -1.67382}, {0.311843, 0.967227}] – DMH16 Jan 30 '18 at 0:03
• Maybe Row[{x, y} /. points, ","]? – user1066 Jan 30 '18 at 0:44

## 1 Answer

With respect to the second question: Here is something to start with. Use it in the same way as you would use Solve.

MySolve[args___] := Module[{sol, threashold, b = True},
threashold = 100;
sol = Solve[args];
Which[
! MissingQ[FirstPosition[sol, _Root]],
Print["NSolve used because of Root expressions."];
sol = N[sol];
,
LeafCount[sol] > threashold,
Print["NSolve used because expression was too complicated."];
sol = NSolve[args];
,
Head[sol] === Solve,
Print["NSolve used because Solve returned unevaluated expression."];
sol = NSolve[args];
];
sol
]

• If sol contains a Root object you don't need to solve again with NSolve, just use sol = sol//N – Bob Hanlon Jan 30 '18 at 0:28
• @BobHanlon Good point. – Henrik Schumacher Jan 30 '18 at 0:29