-
Notifications
You must be signed in to change notification settings - Fork 14
/
mcce.c
103 lines (85 loc) · 3.31 KB
/
mcce.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
extern "C" {
#include "lib/mcce.h"
}
#include <stdio.h>
//#include "lib/mcce.h"
//#include <mpi.h>
void welcome();
int main(int argc, char *argv[])
{
/* Welcome */
welcome();
/* add */
/* Do step 0, initialization */
printf("Step 0. Initialize enviroment\n"); fflush(stdout);
if (init()) {
printf("Help message: double check file \"run.prm\" in current directory.\n");
return USERERR;
}
else printf("Step 0 Done.\n\n");
/* Do step 1, premcce */
if (env.do_premcce) {
printf("Step 1. Test and format structral file\n"); fflush(stdout);
if (premcce()) {return USERERR;}
else printf("Step 1 Done.\n\n");
}
else printf("Not doing \"Step 1. Test and format structral file\"\n\n");
/* Do step 2. rotamers */
if (env.do_rotamers) {
printf("Step 2. Make multi side chain conformers\n"); fflush(stdout);
if (rotamers()) {
return USERERR;
}
else printf("Step 2 Done.\n\n");
}
else printf("Not doing \"Step 2. Make multi side chain conformers\"\n\n");
/* Do step 3. energies */
if (env.do_energies) {
printf("Step 3. Compute energy lookup table\n"); fflush(stdout);
if (energies()) { return USERERR;}
else printf("Step 3 Done.\n\n");
}
else printf("Not doing \"Step 3. Compute energy lookup table\"\n\n");
/* Do step 4. Monte Carlo */
if (env.do_monte) {
printf("Step 4. Monte Carlo Sampling\n"); fflush(stdout);
if (!env.monte_adv_opt) {
if (monte()) {return USERERR;}
else printf("Step 4 Done.\n\n");
}
else {
if (monte2()) { return USERERR;}
else printf("Step 4 Done.\n\n");
}
}
else printf("Not doing \"Step 4. Monte Carlo Sampling\"\n\n");
/* Add H bond analysis---Cai */
if (env.do_analysis){
printf("Step 6. Hydrogen Bond Network Analysis\n"); fflush(stdout);
if (analysis_adv()) { return USERERR;}
else printf("Step 6 Done.\n\n");
}
else printf("Not doing \"Step 6. Hydrogen Bond Network Analysis\"\n\n");
return 0;
}
void welcome()
{ printf("===========================================================\n");
printf("<<< MCCE Multi-Conformation Continuum Electrostatics >>> \n");
printf(" Marilyn Gunner's Lab at City College of New York, 2023 \n");
printf("-----------------------------------------------------------\n");
printf("Version: 2.7.1 \n");
printf("MCCE Home Page: https://gunnerlab.github.io/Stable-MCCE/quick/\n");
printf("Support: mgunner@ccny.cuny.edu \n");
printf("Developed by: Junjun Mao, Yifan Song, Marilyn Gunner \n");
printf("Reference MCCE: If you publish data calculated with MCCE, \n");
printf(" you need to cite papers suggested in MCCE \n");
printf(" Home Page. \n");
printf("===========================================================\n\n");
printf("Last Updates: \n");
printf(" 02/26/2023: vdw calculated by vdw_pw.py after step3.\n");
printf(" 06/04/2018: Removed dependency on gdbm\n");
printf(" 06/04/2018: Clear text energy table in step 3 and 4 \n");
printf("===========================================================\n\n");
fflush(stdout);
return;
}