# ChromaticPolynomial just stop for GridGraph\[{7,8}\] ?

**URL:** <https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156>\
**Category:** Questions\
**Tags:** algebra, discrete-mathematics, graphs-and-networks\
**Created:** [May 30, 2019, 5:14am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156 "2019-05-30T05:14:25Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![stipins2764](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@stipins2764](https://community.wolfram.com/u/stipins2764)\
**Post date:** [May 30, 2019, 5:14am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/1 "2019-05-30T05:14:25Z")

</div>

Hello all, my apologies for the newbie question, but… I can run this:

```
ChromaticPolynomial[GridGraph[{7,7}], z]

```

and after a few seconds I get an answer. But if I try it with {7,8}, the evaluation just stops after a few seconds, and the result is the same expression with a pictorial representation of the graph inside the square brackets.

Why is the evaluation stopping? Am I running out of memory? Is there any way to force it to continue, even if it takes a long time? Am I running into some time limit due to the fact that this is a free trial?

Thanks in advance for any insight.

---

<div class="post-metadata">

**Author:** ![rohitnamjoshi](https://avatars.discourse-cdn.com/v4/letter/r/f1d935/32.png) [@rohitnamjoshi](https://community.wolfram.com/u/rohitnamjoshi)\
**Post date:** [May 30, 2019, 3:16pm UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/2 "2019-05-30T15:16:59Z")

</div>

When I try it on `12.0.0 for Mac OS X x86 (64-bit) (April 7, 2019)` the kernel just dies. Looks like a bug. You should [report](http://www.wolfram.com/support/contact/email/) it.

---

<div class="post-metadata">

**Author:** ![stipins2764](https://avatars.discourse-cdn.com/v4/letter/s/df788c/32.png) [@stipins2764](https://community.wolfram.com/u/stipins2764)\
**Post date:** [May 30, 2019, 3:27pm UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/3 "2019-05-30T15:27:53Z")

</div>

The same thing happens on Wolfram Alpha, so I thought that it might not be Mac-specific.

So it’s not expected behavior that a computation just suddenly quits when it runs into some kind of resource limit?

---

<div class="post-metadata">

**Author:** ![szhorvat](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/szhorvat/32/3531_2.png) [@szhorvat](https://community.wolfram.com/u/szhorvat)\
**Post date:** [May 31, 2019, 10:16am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/4 "2019-05-31T10:16:21Z")

</div>

> So it’s not expected behavior that a computation just suddenly quits when it runs into some kind of resource limit?

No. This is most certainly a bug.

---

<div class="post-metadata">

**Author:** ![szhorvat](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/szhorvat/32/3531_2.png) [@szhorvat](https://community.wolfram.com/u/szhorvat)\
**Post date:** [May 31, 2019, 10:18am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/5 "2019-05-31T10:18:56Z")

</div>

BTW what are you trying to do with the chromatic polynomial?

---

<div class="post-metadata">

**Author:** ![lczhangmath](https://avatars.discourse-cdn.com/v4/letter/l/e9bcb4/32.png) [@lczhangmath](https://community.wolfram.com/u/lczhangmath)\
**Post date:** [June 1, 2019, 6:50am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/6 "2019-06-01T06:50:39Z")

</div>

It doesn’t work on mathematica 12 in my computer either. So I try it on maple 2019, and work it out.

```
restart:
with(GraphTheory):
with(SpecialGraphs):
G := GridGraph(7, 8): 
DrawGraph(G);
expand(ChromaticPolynomia

```

[chromaticpolynomialofgreigraph.pdf](https://community.wolfram.com/uploads/short-url/8LW07yBO7Bq9rosJlenuwuBaWgF.pdf) (275 KB)

---

<div class="post-metadata">

**Author:** ![szhorvat](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/szhorvat/32/3531_2.png) [@szhorvat](https://community.wolfram.com/u/szhorvat)\
**Post date:** [June 2, 2019, 11:08am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/7 "2019-06-02T11:08:43Z")

</div>

`TuttePolynomial` is similarly affected.

`TuttePolynomial[GridGraph[{7, 7}], {x, y}]` works.

`TuttePolynomial[GridGraph[{7, 8}], {x, y}]` does not.

---

<div class="post-metadata">

**Author:** ![lczhangmath](https://avatars.discourse-cdn.com/v4/letter/l/e9bcb4/32.png) [@lczhangmath](https://community.wolfram.com/u/lczhangmath)\
**Post date:** [June 4, 2019, 6:25am UTC](https://community.wolfram.com/t/chromaticpolynomial-just-stop-for-gridgraph-7-8/14156/8 "2019-06-04T06:25:08Z")

</div>

Is it a setup problem? May be bug. If you find a solution, Could you share it. It is strange.
