domingo, 28 de agosto de 2011

Plotar dois graficos juntos maple

readlib(readdata);
datalist := readdata("C:\\sample.dat", float, 2);
p1 := plot(datalist);
datalist2 := readdata("C:\\sample2.dat", float, 2);
p2 := plot(datalist2);
display({p1, p2});


Como plotar com o maple , plot , arquivo , dados , entrada

mole mole ...

seguinte :

todos tem que ser entradas matematicas , não de texto :



readlib(readdata);
datalist := readdata("C:\\sample.dat", float, 2);
plot(datalist);

pronto !!!

se quiser em escala log :

logplot(datalist);

mole mole fácil fácil :d

Marcadores: , , , , , , ,

terça-feira, 23 de agosto de 2011

Contar linhas de um arquivo de texto ( txt )grande em windows

fonte : http://brett.batie.com/scripting/count-number-of-lines-in-a-file-using-dos/
Count number of lines in a file using DOS
Every once in a while I get on a computer and I need to count the number of lines in a file. My first instinct is to open my text editor (editplus) and hit ctrl+end to get to the bottom of the document. Then I can view the status bar which will tell me the line number. This works fine when I am on my computer but not when I am on another computer that does not have editplus installed.

My next option might be to open this file in notepad and do the exact same thing. This will work fine if the file is not to large. The problem is I often deal with very large files. I need a quicker way to produce the same results.

This is where DOS comes into play. I can use the following command and let DOS quickly tell me the number of lines in the file.

1
findstr /R /N "^" file.txt
This command will output every line with a line number in front of it but will still take a long time given a very large file. The solution to this is to take this command one step further.


Use este comando :
findstr /R /N "^" file.txt | find /C ":"
Now the output will only be the number of lines that are contained in the file.Again, this command could be taken a step further to tell you how many lines are in the file that contain a certain string.

1findstr /R /N "^.*certainString.*$" file.txt | find /c ":"
I'm sure there are many other great uses for find and findstr. If you have found one please post comment.

segunda-feira, 22 de agosto de 2011

listar todos os arquivos de um diretorio no windows recursivamente

Exemplo : para listar todos os txt's recursivamente :

dir /b /s *.txt

para listar todos os jpg

dir /b /s *.jpg


e para salvar em um txt a saida ...

dir /b /s *.jpg > saida.txt

eh isso a dica rápida de hoje hehe !