Comments (4)
Wait a minute, @garden-of-delete . Please look at src/tests/clkTests.cpp lines 718-728. These seem to be for q=3.
Is the task to check that these match literature?
from recombo_public.
Unfortunately, it does not appear that I have access to "Monte Carlo Study of Polymer Systems by Multiple Markov Chain Method" by Enzo Orlandini. Was there another which might have contained computed examples?
from recombo_public.
Okay. I have Schmirler's thesis. I will compute by hand probabilities for two z-values and two q-values using equations 4.7 on page 52 and write a test that checks against those hand computed probabilities.
https://central.bac-lac.gc.ca/.item?id=TC-SSU-201209670&op=pdf&app=Library&oclc_number=1032987533
from recombo_public.
We have confirmed that the bfacf probability for P(-2) being computed in the probmap for q > 1. The test here:
bool testPrecomputedBfacf3Probs(){
clkCigar square;
clkConformationAsList square1(square);
testClkConformationBfacf3 knot(square1);
//select a z with q=1
double z = .2000, q = 1;
//precompute probabilities
knot.init_Q(z, q);
//compare precomputed probabilities with directly computed probabilities
for (int n = 4; n < MAX_PRECOMPUTE_LENGTH; n++){
ASSERT(knot.probMap[n].p_plus2 == (pow((n + 2), (q - 1))*(z * z)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z));
ASSERT(knot.probMap[n].p_minus2 == pow(n, (q - 1)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z));
ASSERT(knot.probMap[n].p_0 == .5*((pow((n + 2), (q - 1))*(z * z)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z) +
pow(n, (q - 1)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z)));
}
//select a different z with q=3
z = .1812; q = 3;
//precompute
knot.init_Q(z, q);
//compare
for (int n = 4; n < MAX_PRECOMPUTE_LENGTH; n++){
ASSERT(knot.probMap[n].p_plus2 == (pow((n + 2), (q - 1))*(z * z)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z));
ASSERT(knot.probMap[n].p_minus2 == pow(n, (q - 1)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z));
ASSERT(knot.probMap[n].p_0 == .5*((pow((n + 2), (q - 1))*(z * z)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z) +
pow(n, (q - 1)) / (pow(n, (q - 1)) + 3.0*pow((n + 2), q - 1) * z * z)));
}
return true;
}
failed to catch the issue because the expression it is comparing the probmap to is also wrong.
Steps to resolve this issue:
- Fix the broken test
- Find and fix the expression that is miscomputing these probabilities in the probMap
- Verify the test passes
from recombo_public.
Related Issues (12)
- Tests do not build HOT 1
- License HOT 2
- [MMC] Recombo mode issue HOT 5
- Old Makefiles HOT 3
- testParallelRecombination HOT 4
- What are the bugs in clkConformationBfacf3::impl::searchForRecomboSitesOneComp(int minarclength, int maxarclength)? HOT 2
- test repro running mmc HOT 5
- make test HOT 2
- homfly not building with clang HOT 4
- Project does not build with g++ HOT 2
- [mmc] arclength criteria specification
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from recombo_public.