Skip to content

Commit 995d992

Browse files
committed
init github
1 parent 383c538 commit 995d992

File tree

6 files changed

+130
-26
lines changed

6 files changed

+130
-26
lines changed

.idea/compiler.xml

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/gradle.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/workspace.xml

Lines changed: 58 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

LICENSE.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Free for non-commercial use. All rights reserved. Daniel Debert 2018. Please contact the owner for the license.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
package com.brainlet;
2+
3+
import com.brainlet.mbti.MBTI;
4+
import org.junit.Test;
5+
6+
public class MBTITests {
7+
8+
@Test
9+
public void test() {
10+
final MBTI[] values = MBTI.values();
11+
12+
13+
}
14+
}
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
package com.brainlet;
2+
3+
import com.brainlet.plutchik.PlutchikWheel;
4+
import org.junit.Test;
5+
6+
import java.util.List;
7+
8+
public class PlutchikWheelTests {
9+
10+
@Test
11+
public void wheel() {
12+
PlutchikWheel mood = new PlutchikWheel();
13+
14+
StringBuilder sb = new StringBuilder();
15+
16+
int iterations = 10;
17+
boolean print = true;
18+
19+
long startTime = System.currentTimeMillis();
20+
/*
21+
for(int i=0; i<iterations;i++) {
22+
mood.dopamine = (float) Math.random();
23+
mood.serotonine = (float) Math.random();
24+
mood.oxytocin = (float) Math.random();
25+
mood.norepinephrine = (float) Math.random();
26+
27+
PlutchikMood mainMood = mood.getMainMood();
28+
final List<PlutchikWheel.MoodCalculation> allMoods = mood.getAllMoods();
29+
30+
if(print) {
31+
allMoods.sort((a,b)->(a.moodStrength>b.moodStrength) ? -1 : 1);
32+
sb
33+
.append("(serotonine:").append(mood.serotonine)
34+
.append(", dopamine:").append(mood.dopamine)
35+
.append(", norepinephrine:").append(mood.norepinephrine)
36+
.append(", oxytocin:").append(mood.oxytocin)
37+
.append(") Main mood: ").append(mainMood).append('\n');
38+
allMoods.forEach((m) -> sb.append(m.currentMood).append(" ").append(m.moodStrength).append('\n'));
39+
sb.append('\n');
40+
}
41+
}
42+
*/
43+
sb.append("\n\n").append(iterations).append(" iterations took: ").append(System.currentTimeMillis()-startTime).append("ms");
44+
45+
System.out.println(sb.toString());
46+
}
47+
}

0 commit comments

Comments
 (0)