Skip to content

Instantly share code, notes, and snippets.

View GregVernon's full-sized avatar

Gregory Vernon GregVernon

View GitHub Profile
import numpy
import sys
from matplotlib import pyplot as plt
sys.path.append( r"C:\Program Files\Coreform Cubit 2023.11\bin")
import cubit
def main( angles ):
fea_results, coarse_results = do_study( angles )
plot_results( angles, fea_results, coarse_results )
@GregVernon
GregVernon / word_table.xml
Last active January 10, 2021 18:41
XML Markup for a simple Word Table - Rendering: https://imgur.com/Icxdstk
<w:tbl>
<w:tblPr>
<w:tblStyle w:val="GridTable5Dark-Accent5"/>
<w:tblW w:w="0" w:type="auto"/>
<w:tblLayout w:type="fixed"/>
<w:tblLook w:val="0420" w:firstRow="1" w:lastRow="0" w:firstColumn="0" w:lastColumn="0" w:noHBand="0" w:noVBand="1"/>
</w:tblPr>
<w:tblGrid>
<w:gridCol w:w="1151"/>
<w:gridCol w:w="1152"/>
classdef quaternion
%quaternion Summary of this class goes here
% Detailed explanation goes here
properties
coefficients
bases
expression
MultTable
end
@GregVernon
GregVernon / finiteDifference.jl
Created March 25, 2019 02:57
Finite Difference Coefficient Generation
order = 4
stencil = [-3 -2 -1 0 1]
S = zeros(Int64,order+1,length(stencil))
for i = 1:length(stencil)
for j = 0:order
S[j+1,i] = stencil[i] ^ j
end
end
import Base.Threads
import LinearAlgebra
import StaticArrays
import BenchmarkTools
function NestedIteration_MatrixVector(M,V,R)
N1 = size(M,1)
nMatrix = size(M,3)
nVector = size(V,2)
for i = 1:nMatrix # Iterate through the matrices