Skip to content

Instantly share code, notes, and snippets.

View linjorejoy's full-sized avatar
🏠
Working from home

Linjo Rejoy linjorejoy

🏠
Working from home
View GitHub Profile
@linjorejoy
linjorejoy / level_1_aerodynamics.json
Last active August 12, 2022 15:44
Level 1 Information
[
{
"drag":21162.87234873467
},
{
"drag":85412.61213504327
},
{
"drag":193675.91162581768
},
@linjorejoy
linjorejoy / inlet_motion_11_0.c
Created June 3, 2022 11:51
The User Defined Function (UDF) Code used to model the alternating velocity of air flow in the vortex generator created by a sinusoidally oscillating diaphragm.
#include "udf.h"
DEFINE_PROFILE(unsteady_velocity,thread,position) {
face_t f;
real t=CURRENT_TIME;
begin_f_loop(f,thread) {
F_PROFILE(f,thread,position)=6*sin(30*t);
} end_f_loop(f,thread)
# Copy from here
import math
def divisors(num):
divisors = []
for i in range(1, math.floor(math.sqrt(num)) + 1):
if num % i == 0:
divisors.append(i)
if i != num/i: