Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#5889 closed enhancement (fixed)

[with patch, positive review] random simplicial complexes

Reported by: jhpalmieri Owned by: jhpalmieri
Priority: minor Milestone: sage-4.0
Component: algebraic topology Keywords:
Cc: Merged in: 4.0.alpha0
Authors: John Palmieri Reviewers: Alex Ghitza
Report Upstream: Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Description

Add random simplicial complexes to the class of examples of simplicial complexes, so you can do

sage: simplicial_complexes.RandomComplex(6, 2)

to get a random simplicial complex with 6 vertices, all possible edges, and the possible 2-dimensional simplices (triangles) randomly included (or not).

Attachments (1)

random-complex.patch (2.9 KB) - added by jhpalmieri 10 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 Changed 10 years ago by AlexGhitza

  • Summary changed from [with patch, needs review] random simplicial complexes to [with patch, needs a tiny bit of work] random simplicial complexes

This looks good.

There is one little issue: as far as I know, you do not need to label the doctest with #random. Sage doctests work in such a way that the same random seed is set before testing, so you will get the same results. So the #random should be removed from line 712.

Apart from that, positive review.

Michael, should we have a new trac component labeled "algebraic topology"? It's a bit weird to have this under "misc", and it will probably come in handy at the next Sage Days in Seattle.

comment:2 Changed 10 years ago by jhpalmieri

  • Summary changed from [with patch, needs a tiny bit of work] random simplicial complexes to [with patch, needs review] random simplicial complexes

Okay, this patch is identical to the first one, but without "#random". It passes all tests for me on sage.math, although I would like someone else to double-check that.

Changed 10 years ago by jhpalmieri

comment:3 Changed 10 years ago by AlexGhitza

  • Summary changed from [with patch, needs review] random simplicial complexes to [with patch, positive review] random simplicial complexes

It also passes doctests for me.

comment:4 Changed 10 years ago by mabshoff

  • Component changed from misc to algebraic topology

Alex,

"Algebraic Topology" - here we come. I have made John default owner for now :)

If you want any other component please let me know and I will add them.

Cheers,

Michael

comment:5 Changed 10 years ago by jhpalmieri

Excellent!

comment:6 Changed 10 years ago by mabshoff

  • Resolution set to fixed
  • Status changed from new to closed

Merged in Sage 4.0.alpha0.

Cheers,

Michael

comment:7 Changed 10 years ago by davidloeffler

  • Authors set to John Palmieri
  • Merged in set to 4.0.alpha0
  • Reviewers set to Alex Ghitza
Note: See TracTickets for help on using tickets.