View MathBot.java
import java.util.Date; | |
import java.text.SimpleDateFormat; | |
import java.lang.reflect.InvocationTargetException; | |
import java.lang.reflect.Method; | |
import java.util.List; | |
import java.util.regex.*; | |
import java.util.*; | |
import thinktank.twitter.*; | |
import org.json.*; |
View libspatialite-2.3.1.ebuild
# Copyright 1999-2009 Gentoo Foundation | |
# Distributed under the terms of the GNU General Public License v2 | |
# $Header$ | |
inherit autotools eutils versionator | |
KEYWORDS="~amd64 ~x86" | |
DESCRIPTION="SpatiaLite extension enables SQLite to support spatial data in a way conformant to OpenGis specifications." | |
HOMEPAGE="http://www.gaia-gis.it/spatialite" |
View sqlite.ebuild
IUSE="debug doc load-extension soundex tcl +threadsafe" | |
src_configure() { | |
# Enable column metadata, bug #266651 | |
append-cppflags -DSQLITE_ENABLE_COLUMN_METADATA | |
# not available via configure and requested in bug #143794 | |
use soundex && append-cppflags -DSQLITE_SOUNDEX | |
# Support R-trees, bug #257646 |
View spatialite.rb
#!/usr/bin/env ruby | |
require 'rubygems' | |
require 'sqlite3' | |
db = SQLite3::Database.new( "test-2.3.sqlite" ) | |
db.enable_load_extension( 1 ) | |
db.load_extension( "libspatialite.so" ) | |
db.enable_load_extension( 0 ) |
View scalarProd.tm
:Begin: | |
:Function: scalarProd | |
:Pattern: ScalarProd[ a_List, b_List ] | |
:Arguments: { a, b } | |
:ArgumentTypes: { Manual } | |
:ReturnType: Manual | |
:End: |
View scalarProd.c
#include "scalarProd_kernel.cu" | |
void scalarProd(void) | |
{ | |
float *h_A, *h_B, *h_C_GPU; | |
float *d_A, *d_B, *d_C; | |
char **heads_A, **heads_B; | |
int *dims_A, *dims_B; | |
int rank_A, rank_B; |
View scalarProd.c
#include <stdio.h> | |
#include <cutil_inline.h> | |
#include <mathlink.h> | |
/////////////////////////////////////////////////////////////////////////////// | |
// Main program | |
/////////////////////////////////////////////////////////////////////////////// | |
int main(int argc, char **argv) | |
{ | |
// use command-line specified CUDA device, otherwise use device with highest Gflops/s |
View gist:180974
In[1]:= Install["scalarProd"] | |
Out[1]= LinkObject[./scalarProd,8,7] | |
In[2]:= ScalarProd[{2.1,3.2},{4.3,5.4}] | |
Out[2]= 26.31 | |
In[3]:= UnInstall[%1] | |
Out[3]= UnInstall[LinkObject[./scalarProd,8,7]] |
View FindM
# Try to find MathLink from Wolfram Mathematica package | |
# | |
# See http://www.wolfram.com/solutions/mathlink/ | |
# | |
# Once run this will define: | |
# | |
# MathLink_FOUND | |
# MathLink_INCLUDE_DIR | |
# MathLink_LIBRARIES | |
# MathLink_MPREP_BINARY |
View gdal.rb
require 'formula' | |
class Gdal <Formula | |
url 'http://download.osgeo.org/gdal/gdal-1.7.2.tar.gz' | |
homepage 'http://www.gdal.org/' | |
md5 '05351f8cb61761ae579667e24a297fe6' | |
def options | |
[ | |
['--with-pg', "Include PostgreSQL support."], |
OlderNewer