Skip to content

Instantly share code, notes, and snippets.

\documentclass[10pt]{article}
\usepackage[a4paper]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[spanish]{babel}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{graphicx}
\usepackage{caption}
@tanoxyz
tanoxyz / utime.h
Created February 5, 2022 18:00
High precision (nanoseconds) time for windows and linux
#ifndef UTIME_INCLUDED
#define UTIME_INCLUDED
#include <stdint.h>
void
UT_Init(void);
int64_t
@tanoxyz
tanoxyz / matfile.h
Created February 4, 2022 18:37
Save matrices using matlab's file format from C
/* --------------------------------------------------------------------------------------
*
* Example/library to save matrices to disk using matlab's file format and being able to
* load them from matlab.
*
* Only stores matrices of reals and double precision, but with minor changes could work
* with single precision or complex numbers.
*
* This was made following the matfile format documentation
#ifndef _APP_H_
#define _APP_H_
#include <stdint.h>
#include <stdbool.h>
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
# This is based on http://schellcode.github.io/webassembly-without-emscripten demos
clang --target=wasm32 -o a.wasm -nostdlib main.c
# Serve the index.html with a http server