Skip to content

Instantly share code, notes, and snippets.

void gaussElim(int n, int m, double** A,double* x) {
int k, i, j,s=0;
//double x;
for (k = 0; k <n-1; k++) {
for (i = k + 1; i < n; i++) {
for (j = k+1; j < n; j++) {
2.000000 -1.000000 0.000000 0.000000 0.000000 1.000000
0.000000 1.500000 -1.000000 0.000000 0.000000 3.000000
0.000000 0.000000 1.333333 -1.000000 0.000000 7.000000
0.000000 0.000000 0.000000 1.250000 -1.000000 11.500000
0.000000 0.000000 0.000000 0.000000 1.200000 11.200000
2.000000 -1.000000 0.000000 0.000000 0.000000 1.000000
-1.000000 1.500000 -1.000000 0.000000 0.000000 3.000000
0.000000 -1.000000 1.333333 -1.000000 0.000000 7.000000
0.000000 0.000000 -1.000000 1.250000 -1.000000 11.500000
0.000000 0.000000 0.000000 -1.000000 1.200000 11.200000
U =
2.0000 -1.0000 0 0 0
0 1.5000 -1.0000 0 0
0 0 1.3333 -1.0000 0
0 0 0 1.2500 -1.0000
0 0 0 0 1.2000
package de.devsurf.html.tail;
import java.io.IOException;
import java.util.Date;
import java.util.Set;
import java.util.concurrent.CopyOnWriteArraySet;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
@jeb2239
jeb2239 / 0_reuse_code.js
Created October 3, 2015 15:50
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
module Hello
val factorial: x:int{x>=0} -> Tot int (*factorial is a totalfunction over non negative ints*)
val length: list 'a -> Tot nat
let rec length l = match l with
| [] -> 0
| _ :: tl -> 1 + length tl
@jeb2239
jeb2239 / ThinkLight
Created August 29, 2016 01:03 — forked from vzaliva/ThinkLight
This script controll keyboard backlight on IBM ThinkPad X-series
#!/bin/bash
# Vadim Zaliva [email protected]
# based on https://gist.github.com/hadess/6847281
if [[ $EUID -ne 0 ]]; then
echo "This script must be run as root" 1>&2
exit 1
fi
import logging
import logging.handlers
smtp_handler = logging.handlers.SMTPHandler(mailhost=("smtp.example.com", 25),
fromaddr="[email protected]",
toaddrs="[email protected]",
subject=u"AppName error!")
logger = logging.getLogger()
@jeb2239
jeb2239 / gmail.py
Last active September 12, 2016 00:47
import logging
import logging.handlers
class TlsSMTPHandler(logging.handlers.SMTPHandler):
def emit(self, record):
"""
Emit a record.
Format the record and send it to the specified addressees.
"""