Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Iker Martín Álvarez
Malleable_CG
Commits
3c757cbb
Commit
3c757cbb
authored
Oct 17, 2023
by
iker_martin
Browse files
Added own mymkl files. Needed for compilation.
parent
2f4cf4c9
Changes
2
Show whitespace changes
Inline
Side-by-side
Main/mymkl.c
0 → 100644
View file @
3c757cbb
#include <stdio.h>
#include <stdlib.h>
#include "mymkl.h"
/**********************************************/
void
rcopy
(
int
*
n
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
)
{
int
i
,
dim
=
*
n
,
ix
=
*
incx
,
iy
=
*
incy
;
double
*
px
=
x
,
*
py
=
y
;
for
(
i
=
0
;
i
<
dim
;
i
++
)
{
*
py
=
*
px
;
px
+=
ix
;
py
+=
iy
;
}
}
void
rscal
(
int
*
n
,
double
*
alpha
,
double
*
x
,
int
*
incx
)
{
int
i
,
dim
=
*
n
,
ix
=
*
incx
;
double
*
px
=
x
,
a
=
*
alpha
;
for
(
i
=
0
;
i
<
dim
;
i
++
)
{
*
px
*=
a
;
px
+=
ix
;
}
}
void
raxpy
(
int
*
n
,
double
*
alpha
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
)
{
int
i
,
dim
=
*
n
,
ix
=
*
incx
,
iy
=
*
incy
;
double
*
px
=
x
,
*
py
=
y
,
a
=
*
alpha
;
for
(
i
=
0
;
i
<
dim
;
i
++
)
{
*
py
+=
*
px
*
a
;
px
+=
ix
;
py
+=
iy
;
}
}
double
rdot
(
int
*
n
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
)
{
int
i
,
dim
=
*
n
,
ix
=
*
incx
,
iy
=
*
incy
;
double
aux
=
0
.
0
,
*
px
=
x
,
*
py
=
y
;
for
(
i
=
0
;
i
<
dim
;
i
++
)
{
aux
+=
*
py
*
*
px
;
px
+=
ix
;
py
+=
iy
;
}
return
aux
;
}
/**********************************************/
Main/mymkl.h
0 → 100644
View file @
3c757cbb
#ifndef mymkl
#define mymkl 1
void
rcopy
(
int
*
n
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
);
void
rscal
(
int
*
n
,
double
*
alpha
,
double
*
x
,
int
*
incx
);
void
raxpy
(
int
*
n
,
double
*
alpha
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
);
double
rdot
(
int
*
n
,
double
*
x
,
int
*
incx
,
double
*
y
,
int
*
incy
);
#endif
Write
Preview
Supports
Markdown
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