Question: Done in mathematica Our goal in this problem is to create a n m matrix with the following properties: the entries are randomly chosen from

Done in mathematica
Our goal in this problem is to create a nm matrix with the following properties: the entries are randomly chosen from the integers 0,-1 and 1. However, these entries are not equally
likely. There should be an 80% chance that an entry is a 0, a 10% chance of a 1 and a 10% chance of a -1.
Write two versions of a function that will produce such matrices. One version should involve procedural programming. (Using some combination of Do, For, While, If, Which, Switch
and/or related constructs, though you don't need to use them all). The second version should be functional (nesting of built-in functions, possibly using Map, Thread, Apply, etc...). For
the functional version, it's OK to use the built-in "If" if you need to.
 Done in mathematica Our goal in this problem is to create

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!