Suppose you were setting out to implement a neural network simulation a) Give Ja
ID: 3665650 • Letter: S
Question
Suppose you were setting out to implement a neural network simulation
a) Give Java code that captures all of the attributes of a neuron cell body. No methods are required, just the data attributes.
b) Give Java code that captures all of the attributes of an axon. Again, no methods are required, just the data attributes.
c) Give Java code that captures all of the attributes of a synapse. Again, no methods, just the data attributes.
d) Comment briefly on the correctness of this statement: There would be no loss of generality if axons and synapses were folded together into a single class combining the attributes of both.
Explanation / Answer
(a)(b)(c)
class cell_body
{
String cell_body;
String nucleus;
String dendrite[];
Integer joint_positions[]; /* position where dendrites are attached */
}
class Neuron
{
Cell_body c;
Axon a;
Synapse s;
}
class Axon
{
String myelin_sheath[];
String cell[];
String node_of_ranvier[];
String hillock; /* Point of connection to cell */
Integer connect_cell_sheath[];
Integer connect_node_sheath[];
}
class Synapse
{
String type;
String signal_to_be_transmitted;
}
(d)
The statement is true. It is clearly visible from the classes above that if the two are merged, then also the functionality will not be affected; the data will not get disturbed. This is because the two have totally different attributes & those attributes also store different data.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.