Skip to content

Marcos_Kata_Magnet_Particules#138

Open
marcos-x86 wants to merge 5 commits intodevelopfrom
marcos_lara_magnet_particules
Open

Marcos_Kata_Magnet_Particules#138
marcos-x86 wants to merge 5 commits intodevelopfrom
marcos_lara_magnet_particules

Conversation

@marcos-x86
Copy link
Contributor

Full description image with equations: https://s26.postimg.org/bcoukewll/Marcos_Magnet_particules.jpg

Professor Chambouliard hast just discovered a new type of magnet material. He put particles of this material in a box made of small boxes arranged in K rows and N columns as a kind of 2D matrix K x N where K and N are postive integers. He thinks that his calculations show that the force exerted by the particle in the small box (k, n) is:

[v(k, n) = \frac{1}{k(n+1)^{2k}}]

The total force exerted by the first row with k = 1 is:

[u(1, N) = \sum_{n=1}^{n=N}v(1, n) = \frac{1}{1.2^2} + \frac{1}{1.3^2}+...+\frac{1}{1.(N+1)^2}]

We can go on with k = 2 and then k = 3 etc ... and consider:

[S(K, N) = \sum_{k=1}^{k=K}u(k, N) = \sum_{k=1}^{k=K}(\sum_{n=1}^{n=N}v(k, n)) \rightarrow (doubles(maxk, maxn))]

#Task: To help Professor Chambouliard can we calculate the function doubles that will take as parameter maxk and maxn such that doubles(maxk, maxn) = S(maxk, maxn)? Experiences seems to show that this could be something around 0.7 when maxk and maxn are big enough.

#Examples:

double(1, 3) => 0.4236111111111111
double(1, 10) => 0.5580321939764581
double(10, 100) => 0.6832948559787737

@codecov-io
Copy link

codecov-io commented Sep 4, 2017

Codecov Report

Merging #138 into develop will increase coverage by 0.04%.
The diff coverage is 100%.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop     #138      +/-   ##
=============================================
+ Coverage      87.84%   87.89%   +0.04%     
- Complexity       456      459       +3     
=============================================
  Files            103      104       +1     
  Lines            987      991       +4     
  Branches         161      161              
=============================================
+ Hits             867      871       +4     
  Misses           106      106              
  Partials          14       14
Impacted Files Coverage Δ Complexity Δ
.../java/org/fundacionjala/coding/marcos/Magnets.java 100% <100%> (ø) 3 <3> (?)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ba1f59d...64ed292. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants