-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain_OuterLoop.m
executable file
·119 lines (94 loc) · 2.78 KB
/
main_OuterLoop.m
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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
%%
% SPDX-FileCopyrightText: 2023 Matthew Millard <[email protected]>
%
% SPDX-License-Identifier: MIT
%
% If you use this code in your work please cite the pre-print of this paper
% or the most recent peer-reviewed version of this paper:
%
% Matthew Millard, David W. Franklin, Walter Herzog.
% A three filament mechanistic model of musculotendon force and impedance.
% bioRxiv 2023.03.27.534347; doi: https://doi.org/10.1101/2023.03.27.534347
%
%%
%%
% This function only calls 5 other functions, some of which have lengthy
% run times
%
% 36 min: main_CreateModels_OuterLoop;
% 226 min: main_KirschBoskovRymer1994_OuterLoop;
% 52 min: main_HerzogLeonard2002_OuterLoop;
% 6 min: main_LeonardJoumaaHerzog2010_OuterLoop;
% 26 min: main_ClassicForceLengthVelocityExperiments_OuterLoop;
% 345 min: Total (5 hours and 45 minutes)
%
% *Intel i7-3630QM @ 2.40 GHz, Ubuntu 22
% 8 GB ram, SSD harddrive
%
% All of the extra code that you see beyond these 5 lines is to
% clear the memory between these (sometimes large) main functions, and
% to measure and store timing information.
%%
clc;
close all;
clear all;
timeStart = tic;
% main_CreateModels_OuterLoop;
secondsElapsed = toc(timeStart);
rootDir = getRootProjectDirectory();
cd(rootDir);
fid=fopen('timing_main_OuterLoop.txt','w');
fprintf(fid,'main_CreateModels_OuterLoop, %1.1fmin\n',...
round(secondsElapsed/60));
fclose(fid);
clc;
close all;
clear all;
timeStart = tic;
main_KirschBoskovRymer1994_OuterLoop;
secondsElapsed = toc(timeStart);
rootDir = getRootProjectDirectory();
cd(rootDir);
fid=fopen('timing_main_OuterLoop.txt','a');
fprintf(fid,'main_KirschBoskovRymer1994_OuterLoop, %1.1fmin\n',...
round(secondsElapsed/60));
fclose(fid);
clc;
close all;
clear all;
timeStart = tic;
main_HerzogLeonard2002_OuterLoop;
secondsElapsed = toc(timeStart);
rootDir = getRootProjectDirectory();
cd(rootDir);
fid=fopen('timing_main_OuterLoop.txt','a');
fprintf(fid,'main_HerzogLeonard2002_OuterLoop, %1.1fmin\n',...
round(secondsElapsed/60));
fclose(fid);
clc;
close all;
clear all;
timeStart = tic;
main_LeonardJoumaaHerzog2010_OuterLoop;
secondsElapsed = toc(timeStart);
rootDir = getRootProjectDirectory();
cd(rootDir);
fid=fopen('timing_main_OuterLoop.txt','a');
fprintf(fid,'main_LeonardJoumaaHerzog2010_OuterLoop, %1.1fmin\n',...
round(secondsElapsed/60));
fclose(fid);
clc;
close all;
clear all;
timeStart = tic;
main_ClassicForceLengthVelocityExperiments_OuterLoop;
secondsElapsed = toc(timeStart);
rootDir = getRootProjectDirectory();
cd(rootDir);
fid=fopen('timing_main_OuterLoop.txt','a');
fprintf(fid,'main_ClassicForceLengthVelocityExperiments_OuterLoop, %1.1fmin\n',...
round(secondsElapsed/60));
fclose(fid);
clc;
close all;
clear all;