Skip to content

Instantly share code, notes, and snippets.

Michael Hoffer miho

Block or report user

Report or block miho

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@miho
miho / Adafruit_DHT_Particle.cpp
Last active Mar 26, 2019
Particle Electron DHT22 based Thermometer: Publishes on thingspeak and goes to standby if not publishing (long batter life)
View Adafruit_DHT_Particle.cpp
/* DHT library v0.0.2 works for Particle Electon v1.0.1
*
* MIT license
* written by Adafruit Industries
* modified for Spark Core by RussGrue
* */
#include "Adafruit_DHT_Particle.h"
DHT::DHT(uint8_t pin, uint8_t type, uint8_t count) {
View MeshOptimizer.groovy
package eu.mihosoft.vrl.user;
import eu.mihosoft.jcsg.ext.mesh.MeshTools;
import eu.mihosoft.jcsg.CSG;
@ComponentInfo(name="MeshOptimizer", category="Custom")
public class MeshOptimizer implements java.io.Serializable {
private static final long serialVersionUID=1L;
public CSG optimize(
@ParamInfo(name="mesh to optimize", style="default", options="") CSG mesh,
View BacteriaCreator01.groovy
package eu.mihosoft.vrl.user;
import eu.mihosoft.jcsg.Cylinder;
import eu.mihosoft.jcsg.CSG;
import eu.mihosoft.vvecmath.Transform;
import eu.mihosoft.vvecmath.Vector3d as Vec3d;
import eu.mihosoft.vvecmath.Vectors3d as Vecs;
import eu.mihosoft.jcsg.ext.path.*
@ComponentInfo(name="Bacteria Creator 01", category="Custom")
public class BacteriaCreator01 implements java.io.Serializable {
@miho
miho / FunctionPlotter.groovy
Last active Nov 1, 2018
Function Plotter Template for VRL-Studio
View FunctionPlotter.groovy
package eu.mihosoft.vrl.user;
/**
* Function Plotter
*/
@ComponentInfo(name="FunctionPlotter", category="ODE")
public class FunctionPlotter implements java.io.Serializable {
private static final long serialVersionUID=1L;
public Trajectory run(
@miho
miho / MeshOptimizer.groovy
Created Jul 10, 2018
JCSG Mesh Extension Component for VRL-Studio
View MeshOptimizer.groovy
package eu.mihosoft.vrl.user;
import eu.mihosoft.jcsg.*;
import eu.mihosoft.jcsg.ext.mesh.MeshTools;
@ComponentInfo(name="MeshOptimizer", category="Custom")
public class MeshOptimizer implements java.io.Serializable {
private static final long serialVersionUID=1L;
public CSG optimize(
CSG csg,
@miho
miho / truncocta.scad
Created Jun 13, 2018 — forked from nichtich/truncocta.scad
Truncated octahedron as 3D-Model in OpenSCAD
View truncocta.scad
/*
Truncated octahedron.
*/
module truncocta() {
// octahedron based on code by Willliam A Adams
octapoints = [
[+1, 0, 0], // + x axis
[-1, 0, 0], // - x axis
[0, +1, 0], // + y axis
View JSON.xtext
grammar org.xtext.example.mydsl.take1.MyDsl with org.eclipse.xtext.common.Terminals
generate myDsl "http://www.xtext.org/example/mydsl/take1/MyDsl"
Json: value=Val;
Obj:
'{'
pairs+=Pair (',' pairs+=Pair)*
@miho
miho / KineticSolver.groovy
Created Apr 26, 2018
KineticSolver-UG4 component for VRL by A.Vogel and M.Hoffer
View KineticSolver.groovy
/**
* Script to perform a Kinetic Problem
*
* Author: M. Hoffer, A. Vogel
*/
import eu.mihosoft.vrl.annotation.*;
import eu.mihosoft.vrl.types.*;
import edu.gcsc.vrl.ug.api.I_ApproximationSpace;
import edu.gcsc.vrl.ug.api.I_UserNumber;
import edu.gcsc.vrl.ug.api.F_Integral;
@miho
miho / KineticLinearSolverCustom.groovy
Created Apr 26, 2018
KineticLinearSolver-UG4 component for VRL by A.Vogel and M.Hoffer
View KineticLinearSolverCustom.groovy
import edu.gcsc.vrl.ug.api.*;
import eu.mihosoft.vrl.annotation.*;
import eu.mihosoft.vrl.math.Trajectory;
import eu.mihosoft.vrl.types.CanvasRequest;
import java.io.File;
import java.io.FileFilter;
/**
* Script to perform a Kinetic Problem.
@miho
miho / AdvectionDiffusion.groovy
Last active Apr 26, 2018
AdvectionDiffusion-UG4 component for VRL by A.Vogel and M.Hoffer
View AdvectionDiffusion.groovy
/**
* Script to perform an Advection-Diffusion Problem
*
* Author: M. Hoffer, A. Vogel
*/
import edu.gcsc.vrl.ug.api.I_ApproximationSpace;
import edu.gcsc.vrl.ug.api.I_UserNumber;
import edu.gcsc.vrl.ug.api.I_UserVector;
import edu.gcsc.vrl.ug.api.*;
You can’t perform that action at this time.