Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
argupta
openfpm_numerics
Commits
71a958cd
Commit
71a958cd
authored
Jun 10, 2017
by
incardon
Browse files
Adding missing files
parent
bf83b484
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/interpolation/mp4_kernel.hpp
0 → 100644
View file @
71a958cd
/*
* mp4_kernel.hpp
*
* Created on: May 5, 2017
* Author: i-bird
*/
#ifndef OPENFPM_NUMERICS_SRC_INTERPOLATION_MP4_KERNEL_HPP_
#define OPENFPM_NUMERICS_SRC_INTERPOLATION_MP4_KERNEL_HPP_
#include <iostream>
template
<
typename
st
>
class
mp4_kernel
{
public:
static
const
int
np
=
4
;
static
inline
st
value
(
st
x
,
size_t
i
)
{
if
(
i
==
0
)
return
st
(
2.0
)
+
(
st
(
-
4.0
)
+
(
st
(
2.5
)
-
st
(
0.5
)
*-
x
)
*-
x
)
*-
x
;
else
if
(
i
==
1
)
return
st
(
1.0
)
+
(
st
(
-
2.5
)
+
st
(
1.5
)
*-
x
)
*
x
*
x
;
else
if
(
i
==
2
)
return
st
(
1.0
)
+
(
st
(
-
2.5
)
+
st
(
1.5
)
*
x
)
*
x
*
x
;
else
if
(
i
==
3
)
return
st
(
2.0
)
+
(
st
(
-
4.0
)
+
(
st
(
2.5
)
-
st
(
0.5
)
*
x
)
*
x
)
*
x
;
return
0.0
;
}
};
#endif
/* OPENFPM_NUMERICS_SRC_INTERPOLATION_MP4_KERNEL_HPP_ */
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment