Skip to content

Instantly share code, notes, and snippets.

View restrepo's full-sized avatar

Diego Restrepo restrepo

View GitHub Profile
@restrepo
restrepo / file.py
Last active September 29, 2015 00:33
class THDM:
'''
All parameters in the several basis with functions to get the missing ones
th=THDM()
self.general -> dict with general
'''
import numpy as np
def __init__(self):
#general
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
def test_casasibarra():
ci={'MH0':53.,'MH':125.3,'MA0':120.,'MH1':130.,'La2':0.01,'LaL':0.001,'Mtr01':91.,\
'Mtr02':92.,'Mtr03':93,'Mtrch1': 91.8,'Mtrch2': 92.8, 'Mtrch3': 93.8}
#mnu1in,Dms2,Dma2,ThetSol,ThetAtm,ThetRec=neutrino_data()
#Mnuin=np.array([mnu1in,np.sqrt(Dms2[1]+mnu1in**2),np.sqrt(Dma2[1]+mnu1in**2)])
mnu1in=1E-5
h,U,Mnuin,phases=casasibarra(ci,norotate1=True,norotate2=True,norotate3=True,bestfit=True,\
nophases=True,min_nulight=mnu1in,max_nulight=mnu1in)
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
import sys
if __name__ == '__main__':
# create the parser
parser = argparse.ArgumentParser(
description='''Calcula el valor de la descarga académica
url='http://inspirehep.net/search?ln=en&ln=en&p=find++d+>+2015-11-07+and+primarch+hep-ph'
def casasibarra(di,ranMnu=False):
"""
di.keys()-> ['MH0','MA0','Mtr01','Mtr02','Mtr03',]
"""
MH0=di['MH0'];MA0=di['MA0'];Mtr01=di['Mtr01'];Mtr02=di['Mtr02'];Mtr03=di['Mtr03']
mnu1in,Dms2,Dma2,ThetSol,ThetAtm,ThetRec=neutrino_data()
#Nupa r= min, best_fit, max
#Thesol=np.array([0.278, 0.323, 0.375])
@restrepo
restrepo / posgrado.ipynb
Last active January 29, 2016 06:40
Estudiantes de posgrado admitidos y graduados en el Instituto de Física de la UdeA desde 1995
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#include <Servo.h>
Servo myservo;
Servo myservo2;
const int sensor = 2;
const int ledr= 12;
const int ledv = 13;
int pos = 0;
void setup()
def Fme(x,xmin=0.996,xmax=1.005,xfit=1.001):
"""Fixing near to one values
xmin: close to 1 from below
xmax: close to 1 from above
xfit: optimized 1 limit
"""
x=np.asarray(x)
if x.shape:
x[np.logical_and(x>xmin,x<xmax)]=xfit
else:
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.