Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
Frap Theory
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hubatsch
Frap Theory
Commits
823ab3a0
Commit
823ab3a0
authored
5 years ago
by
Lars Hubatsch
Browse files
Options
Downloads
Patches
Plain Diff
Works also for precision=2.
parent
9cf18a53
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
prob_laplace.m
+11
-10
11 additions, 10 deletions
prob_laplace.m
with
11 additions
and
10 deletions
prob_laplace.m
+
11
−
10
View file @
823ab3a0
...
...
@@ -98,12 +98,12 @@ b = @(chi, nu) nu^(1/3)*sqrt(chi/(chi-2));
e
=
@
(
chi
)
sqrt
(
3
/
8
*
(
chi
-
2
));
t
=
[
0
,
0.05
,
0.1
];
T1
=
Ternary_model
(
0
,
'Gauss'
,
[
-
5
,
b
(
chi
,
nu
),
0.5
,
e
(
chi
),
...
0.16
,
0.2
,
10
,
a
],
t
,
3
);
x0
=
T1
.
x
(
find
(
T1
.
x
>
a
,
1
):
end
);
x0
=
[
x0
(
1
:
20
:
8000
),
x0
(
8001
:
2
:
end
)];
0.16
,
0.2
,
10
,
a
],
t
,
2
);
%
x0 = T1.x(find(T1.x>a, 1):end);
%
x0 = [x0(1:20:8000), x0(8001:2:end)];
x0
=
x0
(
x0
<
7.1
);
% x0 = x0(1:10:end);
%
x0 =
0
.0:0.001:0
.
1;
x0
=
5
.0
:
0.001
:
6.
01
;
%%
T
=
{};
tic
...
...
@@ -111,11 +111,11 @@ parfor i = 1:length(x0)
b
=
@
(
chi
,
nu
)
nu
^
(
1
/
3
)
*
sqrt
(
chi
/(
chi
-
2
));
e
=
@
(
chi
)
sqrt
(
3
/
8
*
(
chi
-
2
));
T
{
i
}
=
Ternary_model
(
0
,
'Gauss'
,
[
-
a
,
b
(
chi
,
nu
),
0.5
,
e
(
chi
),
...
0.16
,
0.2
,
10
,
x0
(
i
)],
t
,
3
);
0.16
,
0.2
,
10
,
x0
(
i
)],
t
,
2
);
T
{
i
}
.
solve_tern_frap
();
end
toc
save
prob_laplace_X_7_7
save
prob_laplace_X_7_7
_short
%%
ls
=
0.0005
:
0.005
:
1
;
p
=
nan
(
1
,
length
(
ls
));
...
...
@@ -124,7 +124,8 @@ p(i) = int_prob(ls(i), T, x0);
end
%% Do we need to look at the left side as well?
figure
;
hold
on
;
plot
(
ls
,
p
);
plot
(
ls
,
N
*
p
);
% plot(lx, xt);
% plot(ls, q/50000);
%%
int_prob
(
0.01
,
T
,
x0
+
a
)
...
...
@@ -136,11 +137,11 @@ for i = 1:2:length(T)
end
%% Normalization factor
tic
N
=
normalization
(
T
,
x0
+
a
);
N
=
normalization
(
T
,
x0
);
toc
%% Write to file
csvwrite
(
'jump_length.csv'
,
ls
)
csvwrite
(
'prob.csv'
,
q
);
csvwrite
(
'jump_length
_7_7_3
.csv'
,
ls
)
csvwrite
(
'prob
_7_7_3
.csv'
,
p
);
%% distribution for x0 can be taken from phi_tot (steady state)
function
p
=
int_prob
(
l
,
T
,
x0
)
delta_x0
=
diff
(
x0
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment