Computer algebra system and term-rewriting functional programming language from Wolfram Research. Not to be confused with "mathematics". New dedicated Mathematica SE site: http://mathematica.stackexchange.com/

learn more… | top users | synonyms

2
votes
1answer
575 views

Fill upper triangular matrix from a list

I am looking a good way to fill up the elements of a lower triangular matrix from a list, in Mathematica. Currently I have the very ugly ...
4
votes
0answers
142 views

nested if conditional in Mathematica

Do you know If and how can I rewrite the code below in a better form for different values of m,k,l? It is a nested if contitional construct that I want to to check b for all m,k,l, but the code below ...
1
vote
0answers
418 views

Fastest way to find all neighbours of a vertex in a graph

I'm looking for the fastest way to find all neighbours of a vertex in an undirected Graph. Please improve on the code if possible. ...
5
votes
1answer
340 views

Directed graph similarity calculation — optimizing Mathematica code

I am looking to optimize the following computation. First, some explanations: Explanation I have a directed graph whose adjacency matrix may only contain 1s and 0s. The similarity of nodes i and j ...
1
vote
1answer
196 views

List of integer factorization into n terms

I want the fastest way in Mathematica 7 to generate a list of the factors (not prime factors) of an integer into a specified number of terms, with each factor greater than one. For example, 240 into ...
4
votes
3answers
336 views

Simplier/shorter implementation of lists' intersection keeping elements' order

I could use function Intersection, but it returns sorted list. That's why I have to do my own, but it looks too big. I hope it could be done shorter. ...