Tags:
create new tag
view all tags

Objects and Interfaces lab: Neurons: Spring 2026

Learning Objective(s)

  1. Design and develop a program using objects
  2. Use interfaces
  3. Learn about neural networks

Overview of the Program

Design and implement a neuron that can be used for a neural network

Specifics

  • No code or data files are provided for this lab until after the design is turned in. Once the design is turned in, a correct interface for the neuron will be provided and must be used to create the final Neuron.java code. The code using the Neuron will have been compiled using that interface.
  • The code should be Neuron
  • A neuron has an array of neurons that are inputs and for which it is an input.
  • The input neurons each has its own weight.
  • The neuron needs to allow for training
  • If the value of the computed average is less than the threshold, it should output 0.0 otherwise it should output a 1.0;
  • A neuron needs to be copied to allow for a creation of a similar network.
  • Classes should include any "helper" methods that are appropriate. This helps in testing and debugging

Prelab: Reading for details

  1. Complete the reading for detail quiz at least 24 hours ahead of time.
  2. If you pass with a 90% you are done.
  3. If you score less than 90%, you must take a hard copy of this lab and highlight where the answers are to the quiz and bring it to lab. The quiz questions will be reposted about 24 hours before the lab so you can do this task.

Phase 1

Design the program and develop a testing plan.
  • Create an interface for a neuron.
  • The design must include a complete UML diagram and should correctly include all major functions
  • Develop a unit test for your neuron. You should be able to compile it using your interface.
  • The testing plan should included unit testing and integration testing
  • Submit a Software Design Report in only one pdf

Phase 2

Using your graded software design report and the provided correct interface and .class files
  • * create a Software Development Report incorporating any necessary changes from the software design report. Be sure to include detailed instructions on how to run your program, including any instructions for extra credit.
    • include statement coverage (in additional to the unit testing and integration testing) in your testing report. If you create unit test programs, for unit testing you can just refer to each section in your report (no need to list input/output, but you must describe the purpose of each group of tests.
  • create a zip folder containing only the following (and submit it)
    • only one file (as a pdf) with the completed software development report
    • all the .java files needed to run the program
    • any input files you might want to have the grader use when running the program
    • any unit testing .java files

Optional improvements

  • allow your neuron to return a double (any value ranging between 0 and 1) with the precision specified by the threshold. If you do this, this code needs be to call EnhancedNeuron.java and still implement the NeuronInterface.java. You should turn in both implementations of the interface.

Post lab

  1. Compare and contrast your solution to the posted solution.
  2. In your writeup, indicate anything that was different between the two and comment on that. (There will always be some differences. Your code might be better.)
  3. Also include at least two things that you learned from the comparison.
Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r2 - 2026-01-20 - CathyBareiss
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback