Open-Source Trigonometric Equation Simplifiers (preferably C-based)? [closed] - c

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I have done some searching around the internet trying to find some form of example code that will allow me to simplify trigonometric equations. In my mathematics course-work this year I am required to simplify trigonometric equations, and I intend on adapting the code to work with my TI-89 Titanium CAS, to use in replacement of the tCollect and tExpand functions (that can't seem to get the job done quite as nicely as I'd like it to).
As I can't really find all too much information on the matter I'd like to know if there is any code (preferably C-based) that will help me to simplify these kinds of equations. If not, what kind of algorithm would be best looking into to code myself?
Thanks.

A very powerful system that seems to have the functionality you need is Maxima, an open source computer algebra system. The following manpage describes trigexapand and trigreduce, which would seem to be roughly what you're looking for.
http://maxima.sourceforge.net/docs/manual/en/maxima_15.html
It's in Lisp rather than C, but consider that an adventure :)

Eigenmath is a handy little computer algebra system.
You might find something relevant in Eigenmath's source code.

The HP49/50 series calculators have a variety of trig manipulation functions that may do a better job than the TI-89. The CAS for the HP calculators is open source, but written in an obscure language. You'd be better off checking out the next CAS written by that guy: Giac/Xcas, written in C++.

Related

Generator of "mind map" from files.c [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
I started a while ago to learn the C language, and has spent several hours I search THE miracle software.
I am looking for software that import sources of software in C (files.c) and generates a "mind map" of the code with all files, functions, variables, etc ...
Do you know if it exists? It'll help me a lot to understand the architecture of complex software.
Thank you very much for all your answers.
Take a look at the "call graph". This sort of visualization should get you started.
As the comment suggests, Doxygen is a good open-source tool. Take a look at some output here. Doxygen is straight-forward to configure for call-graph generation under *nix. It's a little more complex for Windows. First, check out this SO post: how to get doxygen to produce call & caller graphs for c functions. Doxygen's HTML output provides a number of nice cross-referencing features (files, variables, structs, etc.) in addition to caller/callee graphs.
On the commercial side, Understand for C/C++ has first-rate visualization features. Google "c call graph diagram" for other commercial and open-source options.
Finally, there are some older SO posts, like this one Tools to get a pictorial function call graph of code. Take a look at it.
Look into the program ctags. It is an indexer of names and functions based on the structure of the programming language.
It is quite mature, and has integration with a number of other tools. I use it with an older (but very nice) text editor called vi, but it can be used independently from the command line.
It does not generate a graphical view of the connections. However, in my estimation there are probably too many connections in most C programs to display visually without creating a large amount of information overload.
This answer differs from Throwback's answer in some interesting ways. A call graph can mean a few things. One thing it can mean is the path a running program took through a section of code, and another is the combination of all paths a running program might take through the code, and another is the combination of all paths in the code (whether they can be reached or not).
Your needs will drive which tool you should use.

What are the open source equivalents of Apple's Accelerate Framework libraries? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
If we take a look under the umbrella of Accelerate Framework we will see several libraries:
I know that BLAS and LAPACK are open source and that the same code used otherwhere can be compiled against Accelerate.
But what about vForce, vMathLib (and other in vMisc) and vDSP? Is there any open source equivalent for those libraries?
EDIT:
Let me elaborate it a little more (only know I have knowledge enough to do so). Basically, vDSP, vFoce and vMathLib are vector oriented libraries. So, if we have a vector and want to calculate a component-wise function over it, say sin() and cos(), it is faster to use vvsincos() from Accelerate because it will pipeline the calculations of sin() and cos() for all the entries in the vector, which is faster than using a for loop over the vector.
Simply expanding those functions in Taylor-series and using trigonometric relations, we see that there are several repetitive calculations going on and the framework tries to avoid this.
This is the same for FFT under vDSP and so forth
Than, my problem is: what is the BEST open source equivalent to this? And if I develop my project under Accelerate, how can I distribute it using open source tools without needing to rewrite my code?
Stephen Canon (#stephencanon) was kind enough to answer me on twitter:
"OpenCV provides some of the vImage functionality and the GSL has some overlap with vDSP. Neither is a complete equivalent and neither is interface-compatibile, so no drop-in replacement like there is with BLAS/LAPACK."

FUSE - detailed documentation [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
trying to get my own filesystem working using fuse (filesystem in user space, linux) im really curious on where to get detailed up to date documentation of the operations used?
most time i search for other file system implementations and see what they do, but some operations seem to be not widely used like poll/ioctl or bmap.
and the documentation of the fuse api doesnt help much, cause e.g. the parameters and return values of the operations are not documented thus i have to guess how to use em
so the question is where do i get better information about how such exotic operations are supposed to be implemented?
thx
Yes, you are right, many places you can read that comment saying there is little documentation on FUSE. Perhaps that's because there is so little to document. Or perhaps the implementation is only meant for those who understand the tradeoff of userspace filesystem well enough. So perhaps you can refer to the following documentation, tutorials, slides or even sample codes for more information:
FUSE Design Document (original documentation from Sun?):
http://www.youblisher.com/p/31627-fuse/
http://wr.informatik.uni-hamburg.de/_media/research/labs/2008/2008-03-michael_kuhn-container_library_and_fuse_container_file_system-report.pdf
http://www.oug.org/files/presentations/losug-fuse.pdf
http://sar.informatik.hu-berlin.de/teaching/2013-w/2013w_osp2/lab/Lab-4-FUSE/lab-FUSE_.pdf
http://www.cs.hmc.edu/~geoff/classes/hmc.cs135.201001/homework/fuse/fuse_doc.html (tutorials)
http://www.cs.cmu.edu/~./fp/courses/15213-s07/lectures/15-filesys/index.html
http://www.cs.nmsu.edu/~pfeiffer/fuse-tutorial/
Sample code:
http://fuse.sourceforge.net/helloworld.html
And perhaps this is more research-oriented:
http://www.msrsas.org/docs/sastech_journals/archives/May2011/2.pdf
https://code.google.com/p/s3fs/wiki/FuseOverAmazon
But generally there is a lot of problems/issues (which may be solved through some complex algorithm) with implementing filesystem in userspace, which is why Linus has commented it as "toy":
https://ceph.com/dev-notes/linus-vs-fuse/
15Apr2015 update:
I just found this (and many other slides - just look at the right hand side of this webpage):
http://www.slideshare.net/adorepump/fuse-developing-fillesystems-in-userspace

Open Source or Freeware C Code Metrics tools? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I have been trying to find a tool (hopefully for MAC OS X but I don't mind migrating) -- that works -- for those dimensions but I had no luck. Maultech mention some, and so does this page but I was unable to make them work. Metre and ccount (listed on that page) seems to cover most of what I wanted. The tools also seem not up to date no anymore with makes me unsure if the outputs can still be trusted.
Is there any current C tool that can do this that is free or open source? Most of what I found is for Java or OO.
By simple metrics I mean for example calculating amount of, characters, blanks, functions, methods, amount of statements, depth of nests, etc.
By Size I mean line of code, and comments.
By Complexity I mean mccabe and halstead metric at the very least.
By Couple and Cohesion I mean interaction between function calls etc (this is a known SE principle).
I usually use Frama-c.
You may want to take a look at its metrics plugin (McCabe's cyclomatic complexity, Halstead complexity, Value analysis coverage estimate, etc)
What is Frama-C ?
Frama-C is an extensible and collaborative platform dedicated to source-code analysis of C software.

C syntax parser [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Are there any libs out there that can parse C syntax?
For example I would like to write my own code/scripts that will analyze c files given the c syntax. Number of "if" statements per function/file, lines of comments per lines of code in a function and so on.....
I have no problem writing all this custom code just wanted to make the job easier if there was already some lib that I can use to jump start instead of starting with the parser.
Thanks!
Besides the clang suggestion already made, consider pycparser and Boost.Wave.
Although they are more targeted at semantical analyses rather than syntactical ones, you might be interested in CIL and Frama-C, which is based on it (both in OCaml). Another tool (OCaml and Python bindings) of interest is Coccinelle.
Personally, I would look first for an existing tool to do what you want. This sounds like an awful lot of work and there are a lot of good free tools out there for code metrics (did you look on SourceForge?).
If you insist on going ahead with your project, you might google for Lex/Yacc grammars for C.
However, I switched from Lex/Yacc a few years ago to Antlr. I particularly like the way it allows you visually step through your parsing.
A great tool, and free. There is a complete grammar for C available too, so you can modify that to suit your needs.
Hope this helps. Good Luck
you might also consider trying a code coverage tool. although code coverage is meant to show you how much percent of the source code is executed but some of them also show how many conditional statements or loops it encountered whilst doing code coverage. One example that I can share based on my experience is windriver workbench code coverage tool

Resources