This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "fvCFD.H" | |
using namespace fv; | |
int main(int argc, char *argv[]) | |
{ | |
# include "setRootCase.H" | |
# include "createTime.H" | |
# include "createMesh.H" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/tcsh | |
setenv CASE /glade/scratch/jashaw/supercell/15 | |
setenv EXTRACT_SURFACE $HOME/work/tempestmodel/util/ExtractSurface/ExtractSurface | |
ncrcat --overwrite $CASE/outU7.0000-*.nc $CASE/outU7.all.nc | |
bsub -K -q tutorial -W "0:05" -n 1 -P SCIS0006 mpirun.lsf $EXTRACT_SURFACE --in $CASE/outU7.all.nc --out $CASE/outU7.all.5km.nc --var 'W,Rho,RhoQr' --z 5000 | |
ncl plot_supercell_5km_xsec.ncl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\makeatletter | |
\AtBeginDocument{ | |
\hypersetup{ | |
pdftitle = {\@title}, | |
pdfauthor = {\@author} | |
} | |
} | |
\makeatother |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
set -e | |
rm -f plot*.png plot.gif | |
for i in $(seq 0 119); | |
do | |
./surface-fit-visualisation.py 60 $((30 + $i * 3)) $(printf "%03g" $i) | gnuplot5 | |
done | |
for i in $(seq 0 30); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.sun.jersey.api.core.DefaultResourceConfig; | |
import com.sun.jersey.core.spi.component.ComponentContext; | |
import com.sun.jersey.spi.inject.Injectable; | |
import com.sun.jersey.spi.inject.PerRequestTypeInjectableProvider; | |
import com.sun.jersey.test.framework.JerseyTest; | |
import com.sun.jersey.test.framework.LowLevelAppDescriptor; | |
import com.sun.jersey.test.framework.spi.container.TestContainerException; | |
import org.junit.Test; | |
import javax.ws.rs.GET; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import static org.hamcrest.MatcherAssert.assertThat; | |
import static org.hamcrest.Matchers.allOf; | |
import static org.hamcrest.Matchers.equalTo; | |
import static org.hamcrest.Matchers.hasItem; | |
import static org.hamcrest.Matchers.hasProperty; | |
import org.junit.Test; | |
import java.util.Arrays; | |
import java.util.Iterator; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BerlinClock { | |
public static String[] print(Time time) { | |
char seconds = (char) (89 - 10 * (time.second & 1)); | |
char our = (char) (79 + 3 * (time.hour & 1)); | |
/* | |
000 00000000 00000000 00000000 00000000 | |
001 00000000 00000000 00000000 10000000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from numpy.linalg import pinv | |
from numpy import diag | |
from numpy import transpose | |
from numpy import dot | |
import numpy as np | |
# a 3x3 stencil with centroids between (-1.5,1) and (0.5,1) | |
# to interp onto face at (0,0) | |
# upwind cell first, then downwind cell, then top row L-R, bottom row L-R, then left-most cell in middle row |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* = harmonic | |
( ) = optional | |
T = tap | |
A = artificial harmonic | |
--9-9-----------9-7*--9--------------9-11-13----------- | |
---------11-11----9*-----9-9---11-12----------14------- | |
-------0---------(7)-----------------------------13-14- | |
------------------9*----------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RunWith(SpringJUnit4ClassRunner.class) | |
@ContextConfiguration(classes=BeanTest.Config.class) | |
public class BeanTest { | |
@Test | |
public void test() {} | |
@Configuration | |
public static class Config { | |
@Bean public Object bean1() { | |
System.out.println(bean2()); |