# How to Re-write: Set @@@

**URL:** <https://community.wolfram.com/t/how-to-re-write-set/4748>\
**Category:** Questions\
**Tags:** mathematica\
**Created:** [February 5, 2015, 4:36am UTC](https://community.wolfram.com/t/how-to-re-write-set/4748 "2015-02-05T04:36:59Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gregwhammond](https://avatars.discourse-cdn.com/v4/letter/g/96bed5/32.png) [@gregwhammond](https://community.wolfram.com/u/gregwhammond)\
**Post date:** [February 5, 2015, 4:36am UTC](https://community.wolfram.com/t/how-to-re-write-set/4748/1 "2015-02-05T04:36:59Z")

</div>

Hello,

I don’t understand how “Set @@@” works in the following example, how can I rewrite it? It looks like the Apply[] function is the way to do it, but I have not been able to get it to work.

```auto
Clear[a, b]
sol = Solve[a + b^2 == 10, {a, b}, -\[CapitalZeta]];
Set @@@ First@sol
Plot[a, {b, -4, 4}, AxesLabel -> {"b", "a"}]

```

Thanks,

Greg

---

<div class="post-metadata">

**Author:** ![dlkeith](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/dlkeith/32/31494_2.png) [@dlkeith](https://community.wolfram.com/u/dlkeith)\
**Post date:** [February 5, 2015, 5:34pm UTC](https://community.wolfram.com/t/how-to-re-write-set/4748/2 "2015-02-05T17:34:37Z")

</div>

Hi Greg,

@@@ is an operator form of Apply[f,exp,{1}], which replaces the Heads of exp at level 1 with f. So it is like @@, but acts one level down in the expression. Set@@@exp then replaces the heads of exp one level down with Set. And Set is the operator we usually use in the infix form: x=y means Set[x,y].

If we look at the full form of sol we get: List[List[Rule[a,Plus[10,Times[-1,Power[b,2]]]]]]

First@sol removes one level to give List[Rule[a,Plus[10,Times[-1,Power[b,2]]]]]

So Set@@@First@sol replaces the Rule with Set. Mathematica evaluates this and this results in executing a = 10-b^2, so now a has that value and can be plotted by evaluating it with a range of values for b.

Alternatively, you could not use that statement, but could plot directly using the rule which specifies the replacement for a.

```
Plot[a /. sol, {b, -4, 4}, AxesLabel -> {"b", "a"}]

```

Note that this does not set a to a value, but makes the substitution only for the purpose of plotting.

Best regards, David

---

<div class="post-metadata">

**Author:** ![murta](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/murta/32/7023_2.png) [@murta](https://community.wolfram.com/u/murta)\
**Post date:** [February 5, 2015, 10:08pm UTC](https://community.wolfram.com/t/how-to-re-write-set/4748/3 "2015-02-05T22:08:29Z")

</div>

Here is a thread about @@@:

[http://mathematica.stackexchange.com/a/37050/2266](http://mathematica.stackexchange.com/a/37050/2266)
