-
Notifications
You must be signed in to change notification settings - Fork 19
/
Matlab_like.cuh
42 lines (32 loc) · 974 Bytes
/
Matlab_like.cuh
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
#ifndef MATLAB_LIKE_CUH
#define MATLAB_LIKE_CUH
/************/
/* LINSPACE */
/************/
template <class T> T * d_linspace(const T, const T, const unsigned int);
template <class T> T * h_linspace(const T, const T, const unsigned int);
/*********/
/* ZEROS */
/*********/
template <class T> T * h_zeros(const int M, const int N);
/************/
/* MESHGRID */
/************/
#include <thrust/pair.h>
template <class T>
thrust::pair<T *, T *> d_meshgrid(const T *, const unsigned int, const T *, const unsigned int);
template <class T>
thrust::pair<T *, T *> h_meshgrid(const T *, const unsigned int, const T *, const unsigned int);
/*********/
/* COLON */
/*********/
template <class T>
T * d_colon(const T, const T, const T);
template <class T>
T * h_colon(const T, const T, const T);
/*****************************/
/* GENERATE SYMMETRIC POINTS */
/*****************************/
template<class T>
T * generateSymmetricPoints(const T step, const T b);
#endif