UCL / UCL/rsd-engineeringcourse

Energy classroom exercise

Open
#85 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

2018-19
Dominant language
Python
Stars
133
Forks
111
PR merge metrics
No merged PRs in 30d

Description

  1. likelyhood should be likelihood

  2. The text says "Given a vector n of positive integers, and of arbitrary length" <-- what do these integers represent? Number of particles at each position (vector index)? (we have to look at the code to see what he means)

  3. The starting point is given as:
    def energy(density, coeff=1.0):
    But I don't think coefficient is used anywhere. It isn't defined properly either. It made me look ahead to the solution to see what it was used for (it wasn't).

  4. Not sure what the point of def test_derivative(): is. I understand d(n^2-1)/dn = 2n but why are we doing this at all?

  5. Test coverage. When I ran it I got:

eduroam-int-dhcp-97-231-100:diffusion matthewgillman$ py.test --cov
================================================= test session starts =================================================
platform darwin -- Python 3.6.5, pytest-3.5.1, py-1.5.3, pluggy-0.6.0
rootdir: /Users/matthewgillman/Desktop/MPHYG001/rsd-engineeringcourse/diffusion, inifile:
plugins: remotedata-0.2.1, openfiles-0.3.0, doctestplus-0.1.3, cov-2.5.1, arraydiff-0.2
collected 6 items                                                                                                     

test_model.py ......                                                                                            [100%]

---------- coverage: platform darwin, python 3.6.5-final-0 -----------
Name            Stmts   Miss  Cover
-----------------------------------
__init__.py         0      0   100%
model.py           10      0   100%
test_model.py      32      0   100%
-----------------------------------
TOTAL              42      0   100%


============================================== 6 passed in 0.03 seconds ===============================================

I didn't get all the extra output in the notes.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Review the Energy classroom exercise text alongside model.py and test_model.py, which are named in the coverage output. Check the spelling, definitions, unused coefficient, derivative-test purpose, and coverage instructions; done means the exercise is unambiguous and its notes match the documented test workflow.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation, testing-qa
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.