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
package main | |
import ( | |
"fmt" | |
"os" | |
"bufio" | |
"strings" | |
"strconv" | |
"math" | |
"regexp" |
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
d, err := os.Create("nodos.txt") | |
writer := bufio.NewWriter(d) | |
defer func() { | |
if err := writer.Flush(); err!=nil { | |
fmt.Println(err) | |
enterContinue("Se encontro un error en escritura! Verifique integridad de nodos.txt!") | |
} | |
err = d.Sync() | |
check(err) | |
err = d.Close() |
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
function [] = latex_wordcloud(filename) | |
%Crea un wordcloud de las funciones de un archivo latex | |
%Ejemplo: latex_wordcloud('latextext.txt') | |
% latex_wordcloud('mi_TP_de_fisica_4.tex') | |
%Version R2017b y adelante | |
%Patricio Whittingslow 2018 Creative Commons 4.0 | |
fileID=fopen(filename); | |
doubleskip=false; | |
unpermitted={'\','{',"}",'^',' ','%','_',')','(','$','&','=',',','.','[',']','<','>','?','/',"'"}; | |
if fileID==-1 |
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
@ECHO OFF | |
ECHO. | |
ECHO Start building... | |
ECHO. | |
:: Comment: -ldflags reduces the binary file size by omitting symbol tables and debug information. Useful when deploying. | |
:: All caps on keywords not necessary. | |
SET GOOS=linux | |
SET GOARCH=amd64 | |
go build -ldflags="-s -w" -i -o "main_linux" main.go |
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
// IR Setup | |
#include <IRremote.h> | |
const int RECV_PIN = 7; | |
IRrecv irrecv(RECV_PIN); | |
decode_results results; | |
// Rest of setup | |
const int doorPin = 12; // Analog input pin that the potentiometer is attached to | |
//const int resetPin = 4; % Legacy Button reset | |
const int alarmPin = 8; |
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
%% Find minimum amplitud | |
mini=min(min(M)); | |
index=find(M==mini); | |
i = ceil(index/Nb); | |
index=find(M'==mini); | |
j = ceil(index/Nh); |
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
plot3(X,Y,Z) %Plot your awesome plot | |
set(gcf,'renderer','Painters') % 1) Change the renderer of the figure before you draw your figure or before you export. You can use the following command>> | |
% Change the renderer used by the PRINT command. By default it uses the same renderer that the figure uses, so you would have to type the following command to over-ride this: | |
print -depsc -tiff -r300 -painters <filename>.eps % modify <filename> to your hearts desire | |
% modular filename way: | |
print('-depsc','-tiff','-r300', '-painters',[filename,'.eps']) | |
%% Obtained from: https://www.mathworks.com/matlabcentral/answers/92521-why-does-matlab-not-export-eps-files-properly |
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
go get -d ./... |
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
function bandplot2D3D(elementos,nodos,variable,graphArg) | |
% BANDPLOT2D3D Graficador de variables. CC-BY-NC-SA Patricio Whittingslow | |
% 2019. | |
% BANDPLOT2D3D(elementos,nodos,variable,graphArg) | |
% | |
% Típica numeración de los nodos de los elementos: | |
% 4---7---3 | |
% | | | |
% 8 9 6 |
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
% Requires amsymb and amsmath | |
\usepackage{amsymb} | |
\makeatletter | |
\newcommand*{\myfnsymbolsingle}[1]{% | |
\ensuremath{% | |
\ifcase#1% 0 | |
\or % 1 | |
*% | |
\or % 2 | |
\dagger |
OlderNewer